边缘世界 RimWorld

边缘世界 RimWorld

Animals Logic
crow1 2021 年 1 月 14 日 上午 11:12
High performance impact of GenHostility_IsPredatorHostileTo_Patch
Hi. Thank you for creating and maintaining this mod.

I'm seeing a high performance impact of GenHostility_IsPredatorHostileTo_Patch:Prefix (on a big colony, 60 colonists + 300 animals). This happens even when predator detection is disabled (unsurprisingly, as the flag is not checked in the Prefix patch).

Unfortunately I also have problems converting your project from Mono to VS, so can't really check it, but could you maybe consider disabling creating of __state in the Prefix, if the functionality is disabled?
< >
正在显示第 1 - 7 条,共 7 条留言
ignis  [开发者] 2021 年 1 月 14 日 上午 11:48 
Prefix patch only stores sized for future compare. It adds some overhead, but it shouls be neglectable amount. I haven't added check because it should be comparable in impact to the function itself.

Project is actually built in VC, bt the way.

You can try current version from github - I've added check to prefix there
https://github.com/quicksilverfox/RimworldMods
crow1 2021 年 1 月 22 日 上午 8:15 
Hello again. While I was eventually able to recompile the mod on my side, I do struggle to get a reproducible scenario for my report. The mentioned method is sometimes close to 1ms execution time average and I have seen some spikes, but unfortunatelly I cannot create a scenario for decent analysis. Seems also no other players reported such problems, so must be something on my side. Thanks for reply and sorry for bother.

https://ibb.co/VWGJ2P0
crow1 2021 年 2 月 18 日 下午 12:56 
Hello again. While I did not work further on providing more reproducible scenario for high performance impact of IsPredatorHostile patch, it still does from time to time jump in execution time for me. I have also discussed this on the known Rimworld mod performance discord, and the members also observed that phenomena in the past. I also got replies that they commented the patch out in their local copies of the mod and I have done it myself as well. So, while it is no longer a pressing issue for me, and I will continue to use your mod for its other great functionalities, perhaps it is something to keep at the back of the head.
Angel 2021 年 3 月 5 日 下午 2:24 
引用自 crow1
Hello again. While I did not work further on providing more reproducible scenario for high performance impact of IsPredatorHostile patch, it still does from time to time jump in execution time for me. I have also discussed this on the known Rimworld mod performance discord, and the members also observed that phenomena in the past. I also got replies that they commented the patch out in their local copies of the mod and I have done it myself as well. So, while it is no longer a pressing issue for me, and I will continue to use your mod for its other great functionalities, perhaps it is something to keep at the back of the head.

Is the overhead added by the hostile animals significant and all the time, or does it only run when you are being attacked? I don't really want to disable this feature because it allows turrets to protect my pawns. but if it's a big deal I shall.
ignis  [开发者] 2021 年 3 月 6 日 下午 1:51 
It is not confirmed. I don't have problems with it and I don't see how it could even be a problem.
Madman666 2021 年 3 月 10 日 上午 1:51 
引用自 bearhiderug
could this be pactehd for mod too? curiou bc i have spent two day combing everything for performance, and this mod is a top dog for choices of mods, simply bc my kid and i both do alot of animal husbadry lol

You re welcome to join https://discord.gg/TY3Fdqqb We have a version without IsHostile patch. Of course that prevents that mod feature from working (disabling it in options for some reason doesn't eliminate its performance impact), but the rest of the mod is still intact and does its thing.
Madman666 2021 年 3 月 10 日 上午 2:03 
Yeah a simple replace in the local mod folder. Unpack it and its ready. Probably would be best to reset mod settings before use. The link, if you re not afraid of archives https://dropmefiles.com/uneQc
< >
正在显示第 1 - 7 条,共 7 条留言
每页显示数: 1530 50