HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Making unit walkable

01-19-2008, 09:38 PM#1
Centreri
I have a hero death system in my game, in which the dying hero revives in certain animation. I need the hero to become unwalkable while dead and walkable again when revived. How is this done?
01-20-2008, 03:47 AM#2
Gorman
unwalkable is easy, just give it perma invisiblity, that will make it unwalkable to all unit who are un-allied. but if you need something more, just use the Chaos ability to morph the unit into another unit that is the same, but is flying, so all units will walk underneath it.

Then wen its rez time, give it another chaos ability to morph it back again.

Heres some GUI for u, to morph it back just make another chaos ability, and change the Event.
Hidden information:
Trigger:
Make dead un-pathable
Collapse Events
Unit - A unit Dies
Collapse Conditions
Collapse And - All (Conditions) are true
Collapse Conditions
((Triggering unit) is A Hero) Equal to True
((Owner of (Triggering unit)) controller) Equal to User
Collapse Actions
Hero - Instantly revive (Triggering unit) at (Position of (Triggering unit)), Hide revival graphics
Set Exp = (Hero experience of (Triggering unit))
Set Skills[1] = (Level of [First skill of hero] for (Triggering unit))
Set Skills[2] = (Level of [Second skill of hero] for (Triggering unit))
Set Skills[3] = (Level of [Third skill of hero] for (Triggering unit))
Set Skills[4] = (Level of [Fourth skill of hero] for (Triggering unit))
Collapse Set Skills[5] = (Level of [ Fifth skill of hero] for (Triggering unit))
Hero - Instantly revive (Triggering unit) at (Position of (Triggering unit)), Hide revival graphics
Collapse Unit - Add Morph (no path) to (Triggering unit)
Collapse For each (Integer A) from 0 to Skills[1], do (Actions)
Collapse Loop - Actions
Hero - Learn skill for (Triggering unit): [First skill of hero]
Collapse For each (Integer A) from 0 to Skills[2], do (Actions)
Collapse Loop - Actions
Hero - Learn skill for (Triggering unit): [Second skill of hero]
Collapse For each (Integer A) from 0 to Skills[3], do (Actions)
Collapse Loop - Actions
Hero - Learn skill for (Triggering unit): [Thrid skill of hero]
Collapse For each (Integer A) from 0 to Skills[4], do (Actions)
Collapse Loop - Actions
Hero - Learn skill for (Triggering unit): [Fourth skill of hero]
Collapse For each (Integer A) from 0 to Skills[5], do (Actions)
Collapse Loop - Actions
Hero - Learn skill for (Triggering unit): [Fifth skill of hero]


u may want to at an item bit the same as the ability bit...
01-20-2008, 03:24 PM#3
Centreri
Interesting.. so my only options are to either burrow the unit or make it fly? No other method?

This'll be a bit problematic, as I want certain animations to be perfectly visible - a blood mage lying on his back because he died, or in the case of units that dissipate when dead, they'll just stand there all ethereal-like. Making them flying will raise their height, somewhat taking away from the supposed realism of the system.

Anyone know a simpler method? Maybe an ability that automatically removes collision just against this unit, or a trigger that can do this?
01-20-2008, 05:13 PM#4
Alevice
set speed = 0? I don't recall if you can do that, but you may want to try.
01-20-2008, 05:33 PM#5
Szythe
add the ability Ghost (Visible) to make it so units can walk on top of it. Then remove it again when you want to make it so units can no longer walk on it.
01-20-2008, 07:14 PM#6
xombie
Though if you Pause the unit it will disable the Ghost (Visible) ability so make sure you have another way of doing that.
01-21-2008, 01:15 AM#7
Gorman
cant u just set the height value for flying units to 0?, like in most tds
01-21-2008, 01:16 AM#8
Centreri
Oh, so that's why it didn't work before. I pause the unit to prevent anything from happening to it. I got that ghost thing suggestion before.

So.. any method to either avoid using the pause to prevent the owner to control the unit or to make it work on a paused unit or another method..

Can't believe this is so hard :(.
01-21-2008, 01:27 AM#9
xombie
You could give the ownership of that unit to Neutral Passive, without changing the team-color.
01-21-2008, 01:53 AM#10
The Elite
just gvie it the ability Locust, that way it cant be hit, selected etc
01-21-2008, 03:10 AM#11
Centreri
Xombies advice is almost what I need, but resurrection spells base themselves on the hero status stored in a variable and the player number. I'd have to rework a lot of spells to let this happen. Well, if I can't find anything else, it'll have to happen.

I need the unit to be selectable for resurrection spells to work, so that isn't really an option. Some of the resurrection and necromancy spells use AoE indicators, but some require you to select the corpse.