I've noticed some lag recently. DM Eaze sometimes pauses the game to allow parts of the engine to catch up (database access and whatnot). Another thing, since the loadtime and lag seems more pronounced in the Keep, perhaps remove some citizens. I mean, I love the kids playing tag, but all those OnHeartbeat things create lag (unless something's changed since I was fiddling with worlds).
Side note: I still have a lag-measuring script laying around. It's kinda primitive, you switch it on in game and it tells you about the lag, but it could easily be converted to be more useful if needed.
Lag remedy
- Cornflower
- Duke
- Posts: 654
- Joined: Sat May 26, 2018 10:53 am
- Location: Sweden
Lag remedy
Who wills, can
Who tries, does
Who loves, lives
(Ann McCaffrey)
Who tries, does
Who loves, lives
(Ann McCaffrey)
Re: Lag remedy
I have profiling with NWNX, it has been a while since I ran it though. IIRC, the worst offender is the event driven perception scripts, not the heartbeat ones.
- Cornflower
- Duke
- Posts: 654
- Joined: Sat May 26, 2018 10:53 am
- Location: Sweden
Re: Lag remedy
I'm sure you're way more up to date than me. When I ran my world split on two servers, the OnHeartbeat was the Devil.
Who wills, can
Who tries, does
Who loves, lives
(Ann McCaffrey)
Who tries, does
Who loves, lives
(Ann McCaffrey)
Re: Lag remedy
Most of my custom heartbeats use local variables and no loops, unless I have no other choice, in that case I cache or delay execution.
Cornflower wrote: ↑Tue Dec 04, 2018 3:19 pmI'm sure you're way more up to date than me. When I ran my world split on two servers, the OnHeartbeat was the Devil.