Home   Help Search Login Register  

Author Topic: Simple Editing Question  (Read 455 times)

0 Members and 1 Guest are viewing this topic.

AoALedHeaD

  • Guest
Simple Editing Question
« on: 22 Feb 2003, 09:10:58 »
Can anyone help me with a trigger or script
I need a script to get rid of all the dead bodies, some people have said they can cause screen lag?

I have seen few other posts in here related to this but the forum administrator deleted it. I tried a couple of the other scripts on this topic and cant seem to get it to work.

Is it possible to do this? Without much of a headache.
Please Help
« Last Edit: 22 Feb 2003, 10:36:27 by AoALedHeaD »

Knut Erik

  • Guest
Re:Simple Editing Question
« Reply #1 on: 22 Feb 2003, 14:42:36 »
There is one solution i think...
Create a script like this. When the unit is dead (i dont know the script for this but i'm sure someone others do.), exec "dead.sqs" for exsample.

In the dead.sqs file u have this.

(name of dead unit) setpos getpos objectname
Explanation:
When a unit is dead it will automaticly move to another posision. For exsample in the middle of the sea. Just create a object there like a helipad or something. Call the helipad what ever u want but put the name in instead of the objectname.

Hope this can help a little...   ;)

Offline XCess

  • Former Staff
  • ****
Re:Simple Editing Question
« Reply #2 on: 22 Feb 2003, 18:47:36 »
add this to the int field of units:
   ? !(this alive) : exec"delete.sqs";

Make a script called 'delete.sqs' with this:

_unit = _this select 0

deleteVehicle _unit
exit


I think this will work, but the deletVehicle thing might be the wrong command, if it is check the comRef for one like it.
Also, you'll have to add the exec line to every unit you create to make them disappear when dead.

If you want them to disappear after they have been dead for a while add a wait above the deleteVehicle line e.g.:
~3

Demoniac

  • Guest
Re:Simple Editing Question
« Reply #3 on: 24 Feb 2003, 18:33:57 »
How about:
Code: [Select]
_unit = _this

@!alive _unit
~10
deleteVehicle _unit
exit
It waits until _unit is dead, then it waits another 10 seconds (otherwise the body won't even fall) and then it deletes the body. To execute, put this in the unit's init field: this exec "dead.sqs" (dead.sqs is the name of the script)