HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Convert Unit Type

04-09-2006, 09:44 PM#1
knutz
I've got a spell that creates units, but I want to convert their unit type to UNIT_TYPE_SUMMONED as I'm making a control-magic AoE spell to balance it.

I found a native function ConvertUnitType() which takes an integer and returns a unittype, but don't know how it works.

Is it possible to change the unit type and to attribute the summoning to a particular hero?
04-09-2006, 10:03 PM#2
TaintedReality
ConvertUnitType() doesn't change a unit's unit type, it gives you a unittype variable from an integer. All the unittype constants are really just integers in disguise ^^.
04-09-2006, 10:06 PM#3
shadow1500
Is that what your looking for?
Collapse JASS:
call UnitAddType(<unit>,UNIT_TYPE_SUMMONED)
04-09-2006, 10:47 PM#4
knutz
Quote:
Originally Posted by shadow1500
Is that what your looking for?
Collapse JASS:
call UnitAddType(<unit>,UNIT_TYPE_SUMMONED)

Yes! Thanks heaps :-)

Post 2:

Quote:
Originally Posted by shadow1500
Is that what your looking for?
Collapse JASS:
call UnitAddType(<unit>,UNIT_TYPE_SUMMONED)
Question: is there anyway to assign the summoner? (i.e. which hero?)

Edited by Blade.dk. Reason: Double post.
04-10-2006, 02:45 AM#5
Vuen
Use a game cache.