Purgemob
purgemob - syntax: purgemob(CH,options)
Purgemob allows a program to purge various combinations of mobs in the room/area/game.
If the first argument is a CH type variable, it is purged and all other options besides LP_SEEALL are ignored.
If the first argument is a mob key, the first instance of the mob found in scope will be purged. If LP_ALLMOBS is set, all instances of that mob found in scope will be purged. The default scope is the current room. If LP_WORLD is set with LP_ALLMOBS, all instances of that mob in the game will be purged. If LP_ZONEONLY is set, all instances in the current area will be purged.
If the first argument is "all", all mobs in the room except the mob the prog is running on will be purged.
If the first argument is a name, the first mob found in the room with that name is purged. ALLMOBS does not work with a name - you have to use a mob key.
A summary of the options available with purgemobs
LP_SEEALL No visibility checks, if the mob exists and is not flagged NOPURGE, it will be purged. LP_ROOMONLY Only purge mobs in the current room. LP_ZONEONLY Only purge mobs in the current area. LP_WORLD Purge mobs globally - used with LP_ALLMOBS. Usually requires LP_SEEALL to catch everything. LP_NOERR Do not report an error if a target is not found. LP_ALLMOBS When uses with an object key, purges all instances of that mob in scope.
Notes:
Purgemob will not purge a mob that is flagged as 'nopurge'.
If a mob purges itself, any attempts to use a function that requires the 'self' actor will fail with an 'already extracted' error.
--- Purge all instances of tol-25 in the room. purgemob("tol-25",LP_SEEALL+LP_ALLMOBS) --- Purge first "owl" found in the room. purgemob("owl"); --- Purge self purgemob(self)