• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

'saving' units

Status
Not open for further replies.
Level 9
Joined
Dec 21, 2006
Messages
490
hi

create an int variable for example "counter"
create an unit variable with array (i.e. Units[])
create an buff variable with array(i.e. behavior[])
create a w/e var with array

save all your possible buffs into the array variable
for example buff[1] = slow
then everytime you save a unit

save the unit to units[counter]
set the first custom value of the unit to counter
then save the buff to the 2nd custom value(always the array int of the buff)

etc , you can save everything on the unit like this
just make a list which costum value saves which ability
else you will lose the overview

hope you got everything
 
Status
Not open for further replies.
Top