Script Function: Q5S8

From Ultima Online: The Second Age
Revision as of 22:00, 11 October 2018 by Grimoric (talk | contribs) (Created page with " <span style="color:#0000FF">function</span> <span style="color:#0000FF">int</span> Q5S8(<span style="color:#0000FF">obj</span> Q4XN, <span style="color:#0000FF">loc</span> p...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
 function int Q5S8(obj Q4XN, loc place, int Q4ID, int num)
 {
   int Q5NC;
   loc Q4G3 = place;
   setZ(Q4G3, getZ(Q4G3) + 0x0F);
   for(int Q4EJ = 0x00; Q4EJ < num; Q4EJ++)
   {
     if (canSeeLoc(Q4XN, Q4G3))
     {
       obj multi = Q4SA(Q4G3);
       if ((multi == NULL()) && (dropCheck(Q4G3, Q4XN, getHeight(Q4XN))))
       {
         if (Q4EJ == 0x00)
         {
           int Q4IA = getZ(Q4G3) - getZ(place);
           if (Q4IA < 0x00)
           {
             Q4IA = Q4IA * (0x00 - 0x01);
           }
           if (Q4IA <= 0x03)
           {
             return (0x00);
           }
         }
         return (teleport(Q4XN, Q4G3));
       }
     }
     moveDir(Q4G3, Q4ID);
   }
   return (0x00);
 }