Script: Crimeaware

From Ultima Online: The Second Age
Revision as of 07:35, 5 October 2018 by Grimoric (talk | contribs) (Created page with " <span style="color:#0000FF">trigger</span> creation { <span style="color:#FF0000;font-weight:bold">callback</span>(this, 0x0A, 0xC9); <span style="color:#...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
trigger creation
{
  callback(this, 0x0A, 0xC9);
  return (0x01);
}
trigger callback(0xC9)
{
  int npcAwareness = getObjVar(this, "npcAwareness");
  if (npcAwareness > 0x6E)
  {
    setObjVar(this, "npcAwareness", npcAwareness - 0x0A);
    callback(this, 0x0A, 0xC9);
  }
  else
  {
    removeObjVar(this, "npcAwareness");
    detachScript(this, "crimeaware");
  }
  return (0x01);
}