• 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.

[JASS] Could this be shorter?

Status
Not open for further replies.
Level 14
Joined
Nov 18, 2007
Messages
1,084
I'm just wondering if this part
JASS:
if ( ( GetUnitTypeId(dummy) == 'h000' ) ) then
    call RemoveUnit( dummy )
elseif ( ( GetUnitTypeId(dummy) == 'h001' ) ) then
    call RemoveUnit( dummy )
elseif ( ( GetUnitTypeId(dummy) == 'h002' ) ) then
    call RemoveUnit( dummy )
endif
could be shorter.

dummy is a local unit that's declared before this.
 
Status
Not open for further replies.
Top