Script: Des1 ankh tele 1

From Ultima Online: The Second Age
Revision as of 07:37, 19 October 2018 by Grimoric (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
inherits globals;
trigger use
{
  loc toLocation = 0x1530, 0x023A, 0x41;
  if (!hasObjVar(this, "working"))
  {
    setObjVar(this, "working", 0x01);
    setType(this, 0x1091);
    callback(this, 0x03, 0x24);
    doLocAnimation(getLocation(user), 0x373A, 0x01, 0x18, 0x00, 0x00);
    doLocAnimation(toLocation, 0x373A, 0x01, 0x18, 0x00, 0x00);
    if (!teleport(user, toLocation))
    {
      return (0x01);
    }
  }
  return (0x00);
}
trigger callback(0x24)
{
  if (hasObjVar(this, "working"))
  {
    removeObjVar(this, "working");
    setType(this, 0x1092);
  }
  return (0x00);
}