Difference between revisions of "Script Function: Q4JH"

From Ultima Online: The Second Age
Jump to: navigation, search
(Created page with " <span style="color:#0000FF">function</span> <span style="color:#0000FF">void</span> Q4JH(<span style="color:#0000FF">obj</span> user, <span style="color:#0000FF">obj</span>...")
 
 
Line 39: Line 39:
 
         <span style="color:#0000FF">if</span> ((Q5TS != 0x0B) && (Q5TS != 0x10))
 
         <span style="color:#0000FF">if</span> ((Q5TS != 0x0B) && (Q5TS != 0x10))
 
         {
 
         {
           Q51J = [[teleport|<span style="color:#FF0000;font-weight:bold">teleport</span>]](Q4FF, Q4EC);
+
           Q51J = [[Engine Function:_teleport|<span style="color:#FF0000;font-weight:bold">teleport</span>]](Q4FF, Q4EC);
 
         }
 
         }
 
       }
 
       }

Latest revision as of 07:47, 19 October 2018

 function void Q4JH(obj user, obj usedon)
 {
   list Q514;
   loc Q4EC;
   string name;
   int Q51J;
   obj Q48M;
   obj Q495;
   Q4EC = getLocation(usedon);
   name = getObjVar(usedon, "nameVar");
   int Q4Q1;
   switch (getObjType(usedon))
   {
   case 0x2006
     if (!getCompileFlag(0x01))
     {
       if (getNotorietyLevel(user) >= (0x00 - 0x02))
       {
         addNotoriety(user, 0x00 - 0x0A);
       }
     }
     else
     {
       if (canBeFreelyAggressedBy(usedon, user))
       {
         changeKarma(user, 0x00 - 0x1B58);
       }
       else
       {
         changeKarma(user, 0x00 - 0x07D0);
       }
       receiveUnhealthyActionFrom(usedon, user);
     }
     getContents(Q514, usedon);
     for(int x = 0x00; x < numInList(Q514); x++)
     {
       obj Q4FF = Q514[x];
       int Q5TS = getEquipSlot(Q4FF);
       if ((Q5TS != 0x0B) && (Q5TS != 0x10))
       {
         Q51J = teleport(Q4FF, Q4EC);
       }
     }
     Q495 = Q4EN(Q4EC);
     Q48M = Q4EO(Q4EC, 0x1DA0, "head", name);
     copyObjVar(Q48M, usedon, "controller");
     deleteObject(usedon);
     Q48M = Q4EO(Q4EC, 0x1DA1, "left arm", name);
     Q48M = Q4EO(Q4EC, 0x1DA2, "right arm", name);
     Q48M = Q4EO(Q4EC, 0x1DA3, "left leg", name);
     Q48M = Q4EO(Q4EC, 0x1DA4, "right leg", name);
     Q48M = Q4EO(Q4EC, 0x1D9F, "torso", name);
     break;
   case 0x1DA0
     deleteObject(usedon);
     Q495 = Q4EN(Q4EC);
     Q48M = Q4EO(Q4EC, 0x1CF0, "brain", name);
     Q48M = Q4EO(Q4EC, 0x1AE2, "skull", name);
     break;
   case 0x1D9F
     deleteObject(usedon);
     Q495 = Q4EN(Q4EC);
     Q48M = Q4EO(Q4EC, 0x1B17, "ribcage", name);
     Q48M = Q4EO(Q4EC, 0x1CEE, "liver", name);
     Q48M = Q4EO(Q4EC, 0x1CED, "heart", name);
     Q48M = Q4EO(Q4EC, 0x1CEC, "entrails", name);
     break;
   case 0x1DA4
   case 0x1DA3
     deleteObject(usedon);
     Q495 = Q4EN(Q4EC);
     Q48M = Q4EO(Q4EC, 0x1B11, "femur", name);
     break;
   case 0x1DA1
   case 0x1DA2
     deleteObject(usedon);
     Q495 = Q4EN(Q4EC);
     Q48M = Q4EO(Q4EC, 0x1B12, "armbone", name);
     break;
   }
   return ();
 }