Page 1 of 1

Hero health? [Solved]

Posted: Fri Apr 16, 2010 1:04 pm
by skelltor
How would i make heros not lose health or gain health by killing units also how would i make units get health by killing units. I would think it would be in the lua but idk.

Re: hero health?

Posted: Fri Apr 16, 2010 1:33 pm
by Teancum
99% sure the hero bar is hard-coded. If you want the hero to not lose "hero health", make them a selectable unit and set minimum to 0, max to 1.

Re: hero health?

Posted: Fri Apr 16, 2010 2:23 pm
by skelltor
Oh ok thx

Re: Hero health? [Solved]

Posted: Tue Apr 20, 2010 10:41 pm
by myers73
you could also write some code so that they arent added to the team until the player gets a certain number of points.

Re: hero health?

Posted: Wed Apr 21, 2010 2:56 pm
by skelltor
Teancum wrote:99% sure the hero bar is hard-coded. If you want the hero to not lose "hero health", make them a selectable unit and set minimum to 0, max to 1.
how would i make it if i want to be a hero and there is already that hero in the game that that hero will die so i can be the hero?

Re: Hero health? [Solved]

Posted: Wed Apr 21, 2010 2:58 pm
by Teancum
You can't.

Re: Hero health? [Solved]

Posted: Wed Apr 21, 2010 3:03 pm
by skelltor
Oh ok the reson i asked was that i thought it was in skys dark space map pack.

Re: Hero health? [Solved]

Posted: Wed Apr 21, 2010 3:07 pm
by Teancum
Maybe - I don't know how you would kill someone else off and make sure that you get the hero. The hero unlock system is all hard coded.

Re: Hero health? [Solved]

Posted: Wed Apr 21, 2010 7:46 pm
by Fiodis
I thought I had some early success using Fake Console commands to give the hero unending life (through some health regen?) a long, long while ago. It may have just been wishful thinking, though, as I tried the same thing recently and had it pseudofail.

Re: Hero health? [Solved]

Posted: Thu Apr 22, 2010 1:58 am
by lucasfart
Archer01's hero support script is what you're thinking about skelltor. It allows the ai to use the hero, but when the player spawns as it, the ai hero is killed....

Re: Hero health? [Solved]

Posted: Thu Apr 22, 2010 5:26 pm
by skelltor
yah thanks i did not know if sky edited the script or not.

Re: Hero health? [Solved]

Posted: Fri Apr 23, 2010 1:06 am
by Teancum
Ah, I misunderstood. I thought you meant kill a human to take over.

Re: Hero health? [Solved]

Posted: Fri Apr 23, 2010 5:28 am
by RevanSithLord
Teancum wrote:Ah, I misunderstood. I thought you meant kill a human to take over.
Lol. That would be pretty mean, though.

I had a hard time understanding the dude myself, actually. I was about to try and help out with what limited knowledge I have, but since the topic is solved, my post is essentially useless. :(