Difference between revisions of "Script: Statue two"

From Ultima Online: The Second Age
Jump to: navigation, search
(Created page with " <span style="color:#0000FF">trigger</span> use { <span style="color:#0000FF">int</span> Q4FS = <span style="color:#FF0000;font-weight:bold">getX</span>(getLoca...")
 
 
Line 12: Line 12:
 
     [[Engine Function:_bark|<span style="color:#FF0000;font-weight:bold">bark</span>]](this, <span style="color:#800000">"SOUND EFFECT"</span>);
 
     [[Engine Function:_bark|<span style="color:#FF0000;font-weight:bold">bark</span>]](this, <span style="color:#800000">"SOUND EFFECT"</span>);
 
     [[Engine Function:_callback|<span style="color:#FF0000;font-weight:bold">callback</span>]](this, 0x05, 0x01);
 
     [[Engine Function:_callback|<span style="color:#FF0000;font-weight:bold">callback</span>]](this, 0x05, 0x01);
     <span style="color:#0000FF">int</span> Q64U = [[teleport|<span style="color:#FF0000;font-weight:bold">teleport</span>]](this, Q5C0);
+
     <span style="color:#0000FF">int</span> Q64U = [[Engine Function:_teleport|<span style="color:#FF0000;font-weight:bold">teleport</span>]](this, Q5C0);
 
     [[[[Engine Function:_message|<span style="color:#FF0000;font-weight:bold">message</span>]]ToRange|<span style="color:#FF0000;font-weight:bold">[[Engine Function:_message|<span style="color:#FF0000;font-weight:bold">message</span>]]ToRange</span>]](Q4N2, 0x02, <span style="color:#800000">"unlocked"</span>, Q5DQ);
 
     [[[[Engine Function:_message|<span style="color:#FF0000;font-weight:bold">message</span>]]ToRange|<span style="color:#FF0000;font-weight:bold">[[Engine Function:_message|<span style="color:#FF0000;font-weight:bold">message</span>]]ToRange</span>]](Q4N2, 0x02, <span style="color:#800000">"unlocked"</span>, Q5DQ);
 
     [[Engine Function:_setObjVar|<span style="color:#FF0000;font-weight:bold">setObjVar</span>]](this, <span style="color:#800000">"working"</span>, 0x01);
 
     [[Engine Function:_setObjVar|<span style="color:#FF0000;font-weight:bold">setObjVar</span>]](this, <span style="color:#800000">"working"</span>, 0x01);
Line 32: Line 32:
 
     [[Engine Function:_removeObjVar|<span style="color:#FF0000;font-weight:bold">removeObjVar</span>]](this, <span style="color:#800000">"working"</span>);
 
     [[Engine Function:_removeObjVar|<span style="color:#FF0000;font-weight:bold">removeObjVar</span>]](this, <span style="color:#800000">"working"</span>);
 
   }
 
   }
   <span style="color:#0000FF">int</span> Q64U = [[teleport|<span style="color:#FF0000;font-weight:bold">teleport</span>]](this, Q5C0);
+
   <span style="color:#0000FF">int</span> Q64U = [[Engine Function:_teleport|<span style="color:#FF0000;font-weight:bold">teleport</span>]](this, Q5C0);
 
   <span style="color:#0000FF">return</span> (0x01);
 
   <span style="color:#0000FF">return</span> (0x01);
 
  }
 
  }

Latest revision as of 08:14, 19 October 2018

trigger use
{
  int Q4FS = getX(getLocation(this));
  int Q4FT = getY(getLocation(this));
  int Q4FU = getZ(getLocation(this));
  int Q5CG = Q4FU + 0x01;
  loc Q5C0 = Q4FS, Q4FT, Q5CG;
  loc Q4N2 = 0x14AF, 0x0244, 0x00;
  list Q5DQ;
  if (!hasObjVar(this, "working"))
  {
    bark(this, "SOUND EFFECT");
    callback(this, 0x05, 0x01);
    int Q64U = teleport(this, Q5C0);
    [[messageToRange|messageToRange]](Q4N2, 0x02, "unlocked", Q5DQ);
    setObjVar(this, "working", 0x01);
  }
  return (0x01);
}
trigger callback(0x01)
{
  int Q4FS = getX(getLocation(this));
  int Q4FT = getY(getLocation(this));
  int Q4FU = getZ(getLocation(this));
  int Q5CG = Q4FU - 0x01;
  loc Q5C0 = Q4FS, Q4FT, Q5CG;
  bark(this, "SOUND EFFECT");
  bark(this, "returning");
  if (hasObjVar(this, "working"))
  {
    removeObjVar(this, "working");
  }
  int Q64U = teleport(this, Q5C0);
  return (0x01);
}