So, I've ran into a bit of an issue here with unit respawn. I know the easiest way to make a respawn system is to recreate the unit at the location of death, but I want a trigger that allows the unit to be created at the original location. I've created an array and even with all my knowledge of warcraft 3 trigger editing, I have found that there is no unit key that I can access for the array (or I haven't found it yet, but you know, that unique value given to all units?), which is a big problem for me. Is there a way to access this key/value?
Also, regarding memory leaks, I always knew they were a problem in WC3, but do we still need to worry about them as far as unit groups and locations?
Now about the unit respawn... Really all I need to know is how to get the unique ID that was assigned to the unit so I can base my triggers off of that.
Do you mean the key that's used for selecting pre-placed units in the editor?
As far as I know you can't access this for units created after map initialization. However, you can assign a variable to newly created units. Maybe you'd be better off going that route. If you want to save a particular unit's attribute in a variable you could use a record.
Alright, sorry for the late reply, but I was talking about pre-placed units. I seem to have solved this from my lack of observance for the usage of a unit's "Custom Value" which is so deeply improved since WC3. Thank you all for the help :P
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
So, I've ran into a bit of an issue here with unit respawn. I know the easiest way to make a respawn system is to recreate the unit at the location of death, but I want a trigger that allows the unit to be created at the original location. I've created an array and even with all my knowledge of warcraft 3 trigger editing, I have found that there is no unit key that I can access for the array (or I haven't found it yet, but you know, that unique value given to all units?), which is a big problem for me. Is there a way to access this key/value?
Also, regarding memory leaks, I always knew they were a problem in WC3, but do we still need to worry about them as far as unit groups and locations?
Thanks for all help given :3
afaik there's no more memory leaks, at least not easy to cause ones.
@TheAlmaity: Go
Alright thanks :P
Now about the unit respawn... Really all I need to know is how to get the unique ID that was assigned to the unit so I can base my triggers off of that.
@Tyman2007: Go
Do you mean the key that's used for selecting pre-placed units in the editor?
As far as I know you can't access this for units created after map initialization. However, you can assign a variable to newly created units. Maybe you'd be better off going that route. If you want to save a particular unit's attribute in a variable you could use a record.
@BasharTeg: Go
Alright, sorry for the late reply, but I was talking about pre-placed units. I seem to have solved this from my lack of observance for the usage of a unit's "Custom Value" which is so deeply improved since WC3. Thank you all for the help :P