Subtracting Units Hp over time

God Illuvatar

Member!
Joined
Aug 31, 2003
Messages
408
Reaction score
0
Location
Ottawa, Ontario, Canada
Website
Visit site
Saw this on blizzforums, and I just wanted to say something. IM at school,so i cant try it out. But using sc trigger might be able to make u 100 triggers, whereby u just order it to make it so that u subtract 1 hp from 100-1. Then once that is done, u can just use switches.

ie. player brings unit to location
set switch blue.

then u just have switch blue set subtract it.
 

hydrakon

Member!
Joined
Jan 24, 2004
Messages
21
Reaction score
0
Website
clankon.cjb.net
Kind of hard to understand what you just said, but I think you mean, by using 100 triggers, you can subtract one percent of health for every trigger. By the time you reach zero, you die! Where would this be useful?

*Thinks...*

In an RPG say your going through a poison gas chamber. Every second you lose some health. Is that what you're thinking of? If not there's some quick idea you could use.
 

Icedragon

BattleForums Addict
Joined
Aug 2, 2002
Messages
836
Reaction score
0
Location
The Swiming Pools
Yes thats what he is talking about. i dont think you would need 100 triggers IF you can just say if switch is on then unit losses hp If switch is off then units Hp stays the same
 

hydrakon

Member!
Joined
Jan 24, 2004
Messages
21
Reaction score
0
Website
clankon.cjb.net
There's no trigger that subtracts 1% HP and then can be preserved (slap me if I'm wrong). In my mind, I see it as a long four hours of clicking.
 

hydrakon

Member!
Joined
Jan 24, 2004
Messages
21
Reaction score
0
Website
clankon.cjb.net
Hell ya! I wish Blizzard could have put that in their original StarEdit. Map making life would be so different.
 

God Illuvatar

Member!
Joined
Aug 31, 2003
Messages
408
Reaction score
0
Location
Ottawa, Ontario, Canada
Website
Visit site
Well couldnt u do it so that, since ur losing 1 hp every second. just do this

switch blue is set. (and unit has started to lose hp.

WAIT 1 Second, set to 98 then next trig

SWitch is set
Wait 2 sseconds, set to 97.

Do u guys understand? i think it couild be done that way :)then just preserve.It would take awhile but if u want it in ur map, u gotta do it.
 

Bolt Head

Member!
Joined
May 20, 2003
Messages
1,194
Reaction score
0
Website
www.shadowfortress.net
You can't do that Illuvatar because if the zergling is damaged by something else the trigger will end up healing the unit. You have to have a way to detect there health in order to do that.
 

Bolt Head

Member!
Joined
May 20, 2003
Messages
1,194
Reaction score
0
Website
www.shadowfortress.net
I don't think blizzard ever claimed that. . .

Illuvatar: The closest i belive you can come to it is teliporting the unit to a test place and having computer units with known damage shoot the unit at a controlled rate. Then when the unit dies the time it takes for the comp to kill the unit reflects how much life the unit had and from that you can calculate a amount to add or subtract to the health of a new unit. Of course this slightly rounded and takes a long time. (I have done this before)
 

New threads

Top