OFPEC Forum

Editors Depot - Mission Editing and Scripting => Arma2 - Editing/Scripting General => Topic started by: Undeceived on 07 Sep 2011, 16:40:14

Title: How to delete all units of a side (Solved)
Post by: Undeceived on 07 Sep 2011, 16:40:14
Ok, this might be a very noobish question, but hey - I think that I still am one! :weeping: And you won't believe me that I didn't find anything about this after 1 hour of searching in the whole net. :)


How can I delete all units of e.g. the side east that are running around in my mission?

Be there thanks to you!
Title: Re: How to delete all units of a side
Post by: Ext3rmin4tor on 07 Sep 2011, 17:24:24
Code: [Select]
{if (side _x == east) then {deleteVehicle _x};} forEach allUnits

Put it in a trigger activated by a proper condition when you want the units to be deleted.
Title: Re: How to delete all units of a side
Post by: Undeceived on 10 Sep 2011, 14:02:06
Hey, thanks, Ext3rmin4tor! :)

Sorry for the late answer, I'll try it out soon!


Edit some weeks later:

Btw, that worked like a charm! :) Thanks a lot!