Difference between revisions of "Script Function: Q4BV"

From Ultima Online: The Second Age
Jump to: navigation, search
(Created page with " <span style="color:#0000FF">function</span> <span style="color:#0000FF">int</span> Q4BV(<span style="color:#0000FF">obj</span> this, <span style="color:#0000FF">string</span...")
 
 
Line 20: Line 20:
 
     }
 
     }
 
     [[Engine Function:_setObjVar|<span style="color:#FF0000;font-weight:bold">setObjVar</span>]](this, <span style="color:#800000">"petGuard"</span>, 0x01);
 
     [[Engine Function:_setObjVar|<span style="color:#FF0000;font-weight:bold">setObjVar</span>]](this, <span style="color:#800000">"petGuard"</span>, 0x01);
     <span style="color:#0000FF">if</span> (![[isPet|<span style="color:#2B91AF">isPet</span>]](this))
+
     <span style="color:#0000FF">if</span> (![[Script_Function:_isPet|<span style="color:#2B91AF">isPet</span>]](this))
 
     {
 
     {
 
       [[Engine Function:_bark|<span style="color:#FF0000;font-weight:bold">bark</span>]](this, <span style="color:#800000">"Tell me what to guard."</span>);
 
       [[Engine Function:_bark|<span style="color:#FF0000;font-weight:bold">bark</span>]](this, <span style="color:#800000">"Tell me what to guard."</span>);

Latest revision as of 01:51, 21 October 2018

 function int Q4BV(obj this, string Q698, obj speaker, int Q4V9)
 {
   if (Q698 != "guard")
   {
     return (0x00);
   }
   if (0x00)
   {
     bark(this, "Got order to guard.");
   }
   if (Q4V9)
   {
     if (Q4SC() > 0x00)
     {
       copyControllerInfo(this, speaker);
       Q4UH(speaker, this);
       Q4LJ(this);
       return (0x01);
     }
   }
   setObjVar(this, "petGuard", 0x01);
   if (!isPet(this))
   {
     bark(this, "Tell me what to guard.");
   }
   else
   {
     systemMessage(speaker, "Click on the object, person, or place to guard.");
   }
   targetLoc(speaker, this);
   return (0x01);
 }