- Thread starter
- Admin
- #51
On a listenserver, monster spawns will always lag horribly... On a DS, less so, but still not purty. Some of that is debug spam (under the old system, even with Developer set to 0, all those messages still get parsed), but most of it is just our monsters having a hell of a lot of overhead.
Every monster is parsing around 4830 lines of script on spawn, in addition to its own top script (usually another 100 or so lines). I suppose I should go through and strip out all the events we're no longer using - might help some, but not much.
If monsters were entirely code side, it'd help some, but they wouldn't be nearly as dynamic as we need them to be now, and they'd be a *lot* harder to make on the fly (in addition to each having individual, potentially fatal, bugs). Would save on all the array parsing, but that's about it, in the end, and that bit's not real hard on a modern CPU. I *think* we stripped out a lot of the old Half-Life overhead in this patch, but it seems to have messed with monster navigation a bit. Probably not helping much on load time so much as time spent thinking once in the world though.
Still, it's not quite as bad as the old days, when you'd often be locked so long, on a large monster spawn, that you'd timeout. The spawn staggering we added back in the day helps quite a bit, even if it leads to potential complications for the mappers (as they can no longer be certain that all their monsters will appear in the same frame).
Every monster is parsing around 4830 lines of script on spawn, in addition to its own top script (usually another 100 or so lines). I suppose I should go through and strip out all the events we're no longer using - might help some, but not much.
If monsters were entirely code side, it'd help some, but they wouldn't be nearly as dynamic as we need them to be now, and they'd be a *lot* harder to make on the fly (in addition to each having individual, potentially fatal, bugs). Would save on all the array parsing, but that's about it, in the end, and that bit's not real hard on a modern CPU. I *think* we stripped out a lot of the old Half-Life overhead in this patch, but it seems to have messed with monster navigation a bit. Probably not helping much on load time so much as time spent thinking once in the world though.
Still, it's not quite as bad as the old days, when you'd often be locked so long, on a large monster spawn, that you'd timeout. The spawn staggering we added back in the day helps quite a bit, even if it leads to potential complications for the mappers (as they can no longer be certain that all their monsters will appear in the same frame).