Game Modding | Call of Duty: Black Ops 3 | General Discussion
ModmeBot:
Thread By: tom5300
Hello,
I am having a strange issue where when I turn on the power on any map I am creating, there is lag (large fps drop for about 2-5 seconds).
I thought it was an issue with some custom scripts, so I did a clean install on another computer.
After the clean install, I made a new default zm mod level, compiled, light, and linked it. And still had the lag when flipping the power switch.
I have checked the console log and I am thinking it is an issue with setting the perk hint strings.
Here is the console entries from when the lag was happening:
I would get a wave of lag every time a configstring entry was written to the file.
If anyone has any ideas on how to fix this, please let me know!
Thanks
ModmeBot:
Reply By: modric
pretty sure this is on all custom maps good luck figuring it out
ModmeBot:
Reply By: Harry Bo21
that part of the log is not to do with anything
thats not when the power was turned on - thats from _during the load screen_
so thats happened before you even have control
the lag is caused by a huge amount of pointer functions being called in close succession from an array of variables and with network waits
its also not all "custom" maps - its "all maps" - including stock
ModmeBot:
Reply By: tom5300
Harry Bo21
that part of the log is not to do with anything thats not when the power was turned on - thats from _during the load screen_so thats happened before you even have control the lag is caused by a huge amount of pointer functions being called in close succession from an array of variables and with network waitsits also not all "custom" maps - its "all maps" - including stock
ModmeBot:
Reply By: HitmanVere
tom5300
That part of the log actually is from when I am turning on the power. I used the program SnakeTail to live view log entries as they are written to the log file. When I flip the power switch, those are the lines are written to the log file each time, along with the lag. I thought it may be a coincidence, but after looping through a trigger array where I SetHintString("different text each iteration") on multiple trigs, I get the lag as well. I've seen that this lag is not limited to just turning on the power, but setting any hint strings that are not yet loaded into memory/recently registered.
ModmeBot:
Reply By: tom5300
HitmanVere
tom5300 That part of the log actually is from when I am turning on the power. I used the program SnakeTail to live view log entries as they are written to the log file. When I flip the power switch, those are the lines are written to the log file each time, along with the lag. I thought it may be a coincidence, but after looping through a trigger array where I SetHintString("different text each iteration") on multiple trigs, I get the lag as well. I've seen that this lag is not limited to just turning on the power, but setting any hint strings that are not yet loaded into memory/recently registered. Spawn a trigger at map start, set all the perk hintstrings onto that and delete trigger afterwards, that way most of the registers happen when blackscreen is up so you won't even notice it happening. I posted a script in my Twitter, you can find it from there, covers what you need to fix the major lag Tested and confirmed to work by multiple people