Script: Sha boulder two

From Ultima Online: The Second Age
Revision as of 14:15, 5 October 2018 by Grimoric (talk | contribs) (Created page with " <span style="color:#0000FF">inherits</span> globals; <span style="color:#0000FF">member</span> <span style="color:#0000FF">int</span> Q59J; <span style="color:#0000FF...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
inherits globals;
member int Q59J;
trigger creation
{
  setType(this, 0x11B6);
  Q59J = 0x01;
  callback(this, 0x01, 0x24);
  return (0x00);
}
trigger callback(0x24)
{
  loc Q59R = getLocation(this);
  int Q5A4 = getX(Q59R);
  int Q5A5 = getY(Q59R);
  int Q5A6 = getZ(Q59R);
  int Q5CE;
  loc toLocation;
  if ((Q59J == 0x01) && (Q5A4 < 0x1597))
  {
    Q5CE = Q5A4 + 0x01;
  }
  if (Q5A4 == 0x1597)
  {
    Q59J = 0x00;
  }
  if ((Q59J == 0x00) && (Q5A4 > 0x1592))
  {
    Q5CE = Q5A4 - 0x01;
  }
  if (Q5A4 == 0x1592)
  {
    Q59J = 0x01;
  }
  toLocation = Q5CE, Q5A5, Q5A6;
  int Q4Q2 = teleport(this, toLocation);
  callback(this, 0x01, 0x24);
  return (0x00);
}