KillObject

From Soldat Community Wiki
Revision as of 10:06, 15 August 2012 by Freeman (talk | contribs) (Created page with "===From the Scripting Manual=== ''procedure KillObject(ObjID: integer): integer;'' '''Parameter Info:''' ObjID (Integer): ID of the object to be destroyed (Created with ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

From the Scripting Manual

procedure KillObject(ObjID: integer): integer;

Parameter Info:
 ObjID (Integer): ID of the object to be destroyed (Created with SpawnObject)

Description:
 This function will delete an object created with the SpawnObject function

Examples

var
  i: integer;
begin
  i := SpawnObject(GetPlayerStat(1,'x'),GetPlayerStat(1,'y'),5);
  sleep(5000);
  KillObject(i);
  // This will spawn a Spas 12 above player 1, wait 5 seconds and destroy it if it exists.
end;


External Links