• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Spell] Golem summoning problem

Status
Not open for further replies.
Level 12
Joined
Jun 15, 2016
Messages
472
I'm trying to create a custom polymorph spell that turns an allied unit to a granite golem. Problem is that the unit keeps it's old stats and can't attack. I've tried it with both polymorph and hax, and changing the buff to something else (storm earth & fire). so far nothing works.
 
Because the "Unit" data field in those spells refer to the unit models that the polymorphed/hexed target will assume.
Polymorph/Hex changes the target's model to a critter's model, slows its movement speed, and makes it unable to attack or cast spells.
You will need to create a triggered spell that hides the targeted ally, then creates a granite golem in his place, then when the golem expires, unhides the ally at the golem's position and resumes the allied unit's orders.
 
Level 12
Joined
Jun 15, 2016
Messages
472
Because the "Unit" data field in those spells refer to the unit models that the polymorphed/hexed target will assume.
Polymorph/Hex changes the target's model to a critter's model, slows its movement speed, and makes it unable to attack or cast spells.
You will need to create a triggered spell that hides the targeted ally, then creates a granite golem in his place, then when the golem expires, unhides the ally at the golem's position and resumes the allied unit's orders.

I was hoping to do that without triggers, but it works now after a fashion. Thanks.
 
Level 8
Joined
Jan 28, 2016
Messages
486
There may be a slight chance of a workaround for this but it depends on who these "allies" are. If they're the same unit as each other (i.e: you and your allies are all Footman), then you can use the Bearform Trick to pull off a fake hex. It requires some triggering and a bit of work in the Object Editor but it's possible. Again though, it depends on your units and your map.
 
Level 12
Joined
Jun 15, 2016
Messages
472
There may be a slight chance of a workaround for this but it depends on who these "allies" are. If they're the same unit as each other (i.e: you and your allies are all Footman), then you can use the Bearform Trick to pull off a fake hex. It requires some triggering and a bit of work in the Object Editor but it's possible. Again though, it depends on your units and your map.

That's not the case. The idea is for a hero ability which transforms a [player unit] to a golem, and in case there are no units to select you can cast it on said hero and summon golems around him. That doesn't seem to work with choice, so I think I'll just trigger the whole thing to pick a random unit in range and change it, that way the whole choice and button clicking can be avoided.

Anyway, after looking at the W3C link from the bearform trick I see that chaos might be a good way to change the unit type, so thanks :)
 
Level 8
Joined
Jan 28, 2016
Messages
486
That's not the case. The idea is for a hero ability which transforms a [player unit] to a golem, and in case there are no units to select you can cast it on said hero and summon golems around him. That doesn't seem to work with choice, so I think I'll just trigger the whole thing to pick a random unit in range and change it, that way the whole choice and button clicking can be avoided.

Anyway, after looking at the W3C link from the bearform trick I see that chaos might be a good way to change the unit type, so thanks :)

Ahh fair enough. I tried to do a similar thing for another guy with a similar problem but it didn't work out in the end. If you're interested, here's the link: Help with a Biomancer?. It's a bit of a read so if you're short on time or whatever, you'd be best to check out my last post; it sums it up nicely.

I'd avoid using the Chaos ability though because of the bugs that it can cause (see below, link: Abilities - Guide). If you're insistent on using Chaos, there's the The Warcraft III Ability Guide by PitzerMike.

World Editor Tutorials said:
Known Issues

Morphing a unit adds it's current armor, damage, health, mana, provided by all items that the unit has, and also auras, and stats (Strength, Agility, Intelligence).
 
Level 12
Joined
Jun 15, 2016
Messages
472
Prehaps this should be opened in a new thread, but what the hack.
I've completely re-wrote the ability: the new one kills all surrounding player units as sacrifice and powers up the golem accordingly. there is just one glitch I can't solve no matter what.
To power up the golem I used some item based ability for dmg, armor and HP, so that for every set amount of HP secrificed these abilities will increase in level, and they all work except for the HP bonus one.
I've tried deleting and re-forming it, I tried using the ability from different items, and nothing seems to work. Any ideas?

(I can post the test map if it helps)
 
It's because of a bug in the HP bonus ability.
A special bug allows you to to adjust the max mana and life of a unit without a permanent ability on that unit. Simply make a custom AIlf (Life Bonus) or AImb (Mana Bonus) ability and give it more than one level. Now set the bonus for level one to zero and the level two to the exact opposit you want to achieve. That would be -200 if you want to add 200. Now use UnitAddAbility and SetUnitAbilityLevel to add the ability at level two to your target. There's a bug in those abilities that prevents the bonus from being applied correctly. Then immediately remove the ability again using UnitRemoveAbility. This time it will try to undo the -200 bonus (which hadn't been applied due to a bug) and add 200 to the unit. That's it, you've changed the life/mana without having to keep any abilities on the unit.
 
Status
Not open for further replies.
Top