Environment Apparel Framework (环境服装框架)
允许服装在特定的天气下动态切换和增加额外贴图(例如下雨时戴上兜帽,并撑起雨伞)。这部分采用事件驱动,无需Tick检测。
此外,本模组额外增加了三种条件下对服装的动态切换和增加额外贴图:
亮度,污染度:在Pawn移动到不同格子时自动更新,不使用主动的Tick检测,而是通过Pawn的PositionChanged事件触发更新。
温度:混合了房间/区域结构变化时的事件驱动以及Pawn的PositionChanged事件触发更新,性能消耗更友好。
这是一个框架类模组,适合任何希望实现基于环境条件动态切换服装的模组开发者引用。
模组开发者可以方便的,仅在xml中使用模组的两个modExtensions,就可以来实现在特定天气/亮度/污染度/温度条件下动态切换和增加额外贴图的功能,具体使用方法请参考Def下的Apparel_Test.xml。
代码:ZuoYao
封面:骸鸾
特别注意:
-本模组完全由本人制作,没有任何其他我未提及的作者的协助,严禁未经授权的转载和用于AI训练。
-尤其注意,请勿在未经本人授权的情况下将本模组的代码内置进任何其他模组中。这是一个极其轻量的框架类模组,完全可以写个mayrequire不是吗。
-本模组的代码不开源,如果您希望进行二次创作,需要获得我的明确授权。
-当然,我很欢迎互相交流进步,这只是一个提醒,我不想之前的事情再次发生了。如果有兴趣,请务必和我联系。
Allows apparel to dynamically switch and add extra textures under specific weather conditions (for example, putting on a hood and opening an umbrella when it rains). This feature is completely event-driven and requires absolutely no active Tick checking.
Furthermore, this mod introduces three additional environmental conditions for dynamic apparel texture switching and layering:
Light Level and Pollution: Automatically updates when a Pawn moves to a different cell. Instead of relying on active Tick checking, it is triggered by the Pawn's position change events.
Temperature: Utilizes a hybrid approach combining event-driven updates (triggered by room/region structural changes) and position change events, making it extremely performance-friendly.
This is a framework mod designed for any mod developer looking to implement dynamic apparel switching based on environmental conditions.
Modders can easily achieve dynamic texture switching and extra layering under specific weather, light, pollution, or temperature conditions by simply utilizing the two modExtensions provided by this mod in their XML files. For detailed usage and examples, please refer to Apparel_Test.xml located in the Defs folder.