Difference between revisions of "Script: Dec4 face sw two"

From Ultima Online: The Second Age
Jump to: navigation, search
(Created page with " <span style="color:#0000FF">inherits</span> globals; <span style="color:#0000FF">trigger</span> use { <span style="color:#0000FF">loc</span> trapLocation = 0x14B9,...")
 
 
Line 9: Line 9:
 
     [[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);
 
     [[Engine Function:_doLocAnimation|<span style="color:#FF0000;font-weight:bold">doLocAnimation</span>]](trapLocation, 0x10F6, 0x02, 0x08, 0x00, 0x00);
 
     [[Engine Function:_doLocAnimation|<span style="color:#FF0000;font-weight:bold">doLocAnimation</span>]](trapLocation, 0x10F6, 0x02, 0x08, 0x00, 0x00);
     [[Engine Function:_loseHP|<span style="color:#FF0000;font-weight:bold">loseHP</span>]](user, [[dice|<span style="color:#FF0000;font-weight:bold">dice</span>]](0x04, 0x05));
+
     [[Engine Function:_loseHP|<span style="color:#FF0000;font-weight:bold">loseHP</span>]](user, [[Engine Function:_dice|<span style="color:#FF0000;font-weight:bold">dice</span>]](0x04, 0x05));
 
     [[Engine Function:_setType|<span style="color:#FF0000;font-weight:bold">setType</span>]](this, 0x1090);
 
     [[Engine Function:_setType|<span style="color:#FF0000;font-weight:bold">setType</span>]](this, 0x1090);
 
     [[Engine Function:_callback|<span style="color:#FF0000;font-weight:bold">callback</span>]](this, 0x02, 0x24);
 
     [[Engine Function:_callback|<span style="color:#FF0000;font-weight:bold">callback</span>]](this, 0x02, 0x24);

Latest revision as of 21:29, 18 October 2018

inherits globals;
trigger use
{
  loc trapLocation = 0x14B9, 0x02A2, (0x00 - 0x14);
  list Q5DQ;
  if (!hasObjVar(this, "working"))
  {
    setObjVar(this, "working", 0x01);
    doLocAnimation(trapLocation, 0x10F6, 0x02, 0x08, 0x00, 0x00);
    loseHP(user, dice(0x04, 0x05));
    setType(this, 0x1090);
    callback(this, 0x02, 0x24);
  }
  return (0x00);
}
trigger callback(0x24)
{
  if (hasObjVar(this, "working"))
  {
    removeObjVar(this, "working");
  }
  if (getObjType(this) == 0x1090)
  {
    setType(this, 0x108F);
  }
  return (0x00);
}