Modme Forums
Menu:

Lag when turning on the power

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:

Client: Registering configstring index 499 with data ZOMBIE_PERK_JUGGERNAUT2500
Client: Registering configstring index 3241 with data y´kÉ={
Client: Registering configstring index 500 with data ZOMBIE_PERK_FASTRELOAD3000
Client: Registering configstring index 3241 with data yçT
Client: Registering configstring index 501 with data ZOMBIE_PERK_DOUBLETAP2000
Client: Registering configstring index 3241 with data yõÑð¹
Client: Registering configstring index 502 with data ZOMBIE_PERK_ADDITIONALPRIMARYWEAPON4000
Client: Registering configstring index 3241 with data 
Client: Registering configstring index 503 with data ZOMBIE_PERK_DEADSHOT1500
Client: Registering configstring index 3241 with data y¼iÓ
Client: Registering configstring index 504 with data ZOMBIE_PERK_MARATHON2000
Client: Registering configstring index 3241 with data y7Àµï
Client: Registering configstring index 505 with data ZOMBIE_PERK_WIDOWSWINE4000
Client: Registering configstring index 3241 with data y@Ž!=}
Client: Registering configstring index 506 with data ZOMBIE_PERK_PACKAPUNCH5000
Client: Registering configstring index 3241 with data y1 ƒ

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


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: 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


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

Clever work around. Thanks for sharing!