Hospitality icon indicating copy to clipboard operation
Hospitality copied to clipboard

Hospitality: TPS Drop and thoughts on potential optimization

Open skyarkhangel opened this issue 4 years ago • 3 comments

Problem place: https://github.com/OrionFive/Hospitality/blob/6edae90b7985ced8ba04ef8cb3994462108c67f0/Source/Source/JoyGiver_BuyStuff.cs#L43 Some players forgot to select a trading zone and used the home zone. The number of things, especially when playing with mods, is very high in the late-game and this jobgiver could lead to significant tps drop. Its necessary to think about optimizing the method and might be good idea to add a notification to the player about the trading area, if it equals home area or too big.

skyarkhangel avatar Nov 12 '21 16:11 skyarkhangel

If they just forget to set a shopping area (I assume that's what you mean) then shopping is off.

OrionFive avatar Nov 12 '21 17:11 OrionFive

Players may unknowingly set the home zone. I have a save game in which the home zone is set as a trade zone and every time a guest accesses this class lead to a stutters.

skyarkhangel avatar Nov 12 '21 17:11 skyarkhangel

Maybe the issue can be improved with some caching.

OrionFive avatar Nov 12 '21 21:11 OrionFive