
Decaying levels remotely?
Moderator: Moderator
Decaying levels remotely?
This question came up on the Dumb questions thread and I thought I would address it here. The issue is decaying NPCs/items, specifically artifacts, from levels. I believe that the current code only decays when you ENTER the level after a period of time, and if an artifact is created on a level that you never return to the artifact is effectively removed from the game. Persistent levels are added to zone.memory_levels and persistent zones are saved directly to the save file. It looks like a weak table of uids to be decayed when entering a level could actually be handled within the Game turn, allowing say unique NPCs/objects to be decayed when they are outside of the level. The idea needs to be fleshed out a bit more, pass the DG test and get coded of course. Initial thoughts down, though. 

<DarkGod> lets say it's intended
Re: Decaying levels remotely?
Why not do this on entering any level, instead of on turn? If it can be handled just prior to new level generation, that's when it'd need to happen, and less code to run each turn.
Re: Decaying levels remotely?
Or even entering the world map would be frequent enough.