Full Version : an idea
xmlspawner >>Scripting Support >>an idea


<< Prev | Next >>

ambak- 01-29-2006
today an idea just appeared in my mind smile.gif
i think of a small system that auto deletes the items that dropped on the ground about a period of time later.this is i think for reducing the lag . can it be done?

ArteGordon- 01-29-2006
that is how automatic item decay already works. The only difference is that for efficiency, the deletions of dropped items only take place during world saves.

ambak- 01-29-2006
whats the default decay?how can i reduce it?

ArteGordon- 01-29-2006
this script will let you change the default decay time. For permanent change set the following in that script to whatever you want

CODE

  Item.DefaultDecayTime = TimeSpan.FromMinutes(15);

ambak- 01-29-2006
this script is very good smile.gif
for examle if i make the decat 5 minutes.the items that dropped on the ground is going to deleted in 5 minutes am right?
is this contains corpses or golds after the champions?

ArteGordon- 01-29-2006

If you set the defaultdecaytime to 5 minutes, then things will decay after 5 mins on the ground, but they will only be actually removed during server saves. If you save every hour, then it could be up to an hour before they actually get removed.

corpse decay is handled separately.

ambak- 01-29-2006
hmm corpse issue is bad now sad.gif
i think the best way is to add a cleaner thingy on the areas that people usualy drop items.

ArteGordon- 01-29-2006
corpse decay is controlled by this variable in Corpse.cs

CODE

 private static TimeSpan m_DefaultDecayTime = TimeSpan.FromMinutes( 5.0 );

DrussRob- 02-07-2006
You could also just set a spawner to spawn about 200,000 janitors within a 200,000 tile range on each facet...

tongue.gif

(sry, im under the influence hehe)

ArteGordon- 02-07-2006
hehe