What's the purpose of this code?

I was bored, so I started checking the code of random free plugins from the library and found a plugin called “No lag script”.


And, I checked the code and saw this

--Made 100% by matteman2
mx = game.Debris
mx2 = game.Debris.MaxItems
if (mx.MaxItems > 9999999999) then
	mx.MaxItems = mx2*.9999999999

And I’m actually a bit confused, wasn’t Debris a service? And, changing It’s max items would actually reduce the lag?

According to the DevWiki, it seems like there is a property of the Debris service (well, more like there was) that set the max number of debris items. I’m guessing that the point of the plugin was to lower the maxitem count to remove them.

1 Like

MaxItems is deprecated and no longer works.

1 Like