Script Function: Cleanup

From Ultima Online: The Second Age
Jump to: navigation, search
 function void cleanup()
 {
   removeObjVar(this, "lastCriminal");
   removeObjVar(this, "lastVictim");
   removeObjVar(this, "crimeSeverity");
   removeObjVar(this, "crimeLocation");
   detachScript(this, "witness");
   return ();
 }
 function void cleanup()
 {
   if (isContainer(this))
   {
     list Q4E4;
     getContents(Q4E4, this);
     while(numInList(Q4E4))
     {
       list args;
       message(Q4E4[0x00], "cleanup", args);
       removeItem(Q4E4, 0x00);
     }
   }
   removeObjVar(this, "vendedOwner");
   removeObjVar(this, "vendedPrice");
   removeObjVar(this, "description");
   detachScript(this, "vended");
   return ();
 }
 function void cleanup()
 {
   if (hasObjVar(this, "pole"))
   {
     removeObjVar(this, "pole");
   }
   if (hasObjVar(this, "targetType"))
   {
     removeObjVar(this, "targetType");
   }
   if (hasObjVar(this, "there"))
   {
     removeObjVar(this, "there");
   }
   if (hasObjVar(this, "splash"))
   {
     removeObjVar(this, "splash");
   }
   if (hasObjVar(this, "rightHand"))
   {
     removeObjVar(this, "rightHand");
   }
   if (hasObjVar(this, "leftHand"))
   {
     removeObjVar(this, "leftHand");
   }
   if (hasObjVar(this, "staff"))
   {
     removeObjVar(this, "staff");
   }
   if (hasObjVar(this, "equipped"))
   {
     removeObjVar(this, "equipped");
   }
   else
   {
     Q5NI();
   }
   if (hasObjVar(this, "poleID"))
   {
     removeObjVar(this, "poleID");
   }
   detachScript(this, "userisfishing");
   return ();
 }
 function void cleanup()
 {
   clearList(Q5FB);
   if (hasScript(this, "useristracking"))
   {
     shortCallback(this, 0x01, 0x51);
   }
   return ();
 }
 function void cleanup()
 {
   systemMessage(this, "Guards can no longer be called on you.");
   removeObjVar(this, "crimeWitnessList");
   removeObjVar(this, "crimeSeverity");
   detachScript(this, "punishable");
   return ();
 }
 function void cleanup(obj this)
 {
   removeObjVar(this, "guildName");
   removeObjVar(this, "guildAbbreviation");
   removeObjVar(this, "myGuildTitle");
   removeObjVar(this, "guildstoneId");
   removeObjVar(this, "displayGuildAbbr");
   detachScript(this, "guilded");
   return ();
 }
 function void cleanup()
 {
   removeObjVar(this, "usedon");
   removeObjVar(this, "arrayIndex");
   removeObjVar(this, "user");
   removeObjVar(this, "actionCount");
   return ();
 }
 function void cleanup()
 {
   clearList(Q5NZ);
   Q62D = NULL();
   if (hasObjVar(this, "inUse"))
   {
     removeObjVar(this, "inUse");
   }
   return ();
 }