ID:1839320
 
(See the best response by Lige.)
Problem description:
For the past month, I've been adjusting the foundation of my project. I've been focusing on implementing changes on when and how gravity, items and A.I are all handled in order to achieve a lag free experience.

Today, I found a way to apply gravity to my items so that they fall alike mobs, after they were fully functional and I was experiencing no lag, I did a few minor tweaks to a few variables(stacking and whether or not an item is meant to be picked up).

After my additional tweaks, I took a break for a few hours and came back to my project to break some new ground. Unfortunately, I've yet to do anything worthwhile and instead have been disabling and enabling things I assume could cause cpu lag. My CPU lag is currently feeling higher than it's ever been without generating my randomized map. I'd like to look at the Memory log or whatever it's called on Dream Daemon but that's blanked out... ..Does anyone know how to enable this or have any other ideas on how to trace memory or cpu lag?

Additional Notes:
- I've disabled all the procs governing Item gravity, they aren't the cause
- My game seems to take awhile to run after compile
- The game is experiencing CPU lag even before the player logs in(on the character select screen)
- It looks like two windows are opening up initially until I click dream seeker
- I've tried running the project through dream seeker and the web client
Best response
Flame Guardian wrote:
Does anyone know how to enable this or have any other ideas on how to trace memory or cpu lag?

I do not, unfortunately. With that said, I recommend you read up on this thread, it may be of use to you.
I read through all of Ter13's snippets, some of which a little too many times to try and grasp the concepts in order to apply them my own work. That snippet among the rest are helpful, just not in this scenario. I wish to track down and fix or remove whatever extra terrestrial found a home somewhere in my haypile of code, not read through a well written science fiction novel.

Bad analogies or... whatever that was aside, I'm looking to try and trace an underlying problem because I've run out of ideas on what is causing this lag.

Edit: Thank you though for providing a valuable resource for those looking to cut down on lag.
I turned on debug mode, compiled the game again, ran a World Memory Stats test and this is what I found:
server mem usage:
Prototypes:
obj: 84968 (628)
mob: 88088 (195)
proc: 583628 (738)
str: 163082 (4632)
appearance: 262082 (495)
id array: 590992 (1550)
map: 60365624 (300,100,17)
objects:
mobs: 136216 (260)
objs: 383064 (2233)
datums: 18272 (515)
lists: 64760 (1075)

I'm assuming my maps or a particular map... ..Is the problem?
Problem solved; Thank you Memory Stats.