Staredit Network

Staredit Network -> UMS Assistance -> [SOLVED]Maximum Energy
Report, edit, etc...Posted by Oo.HydrA.oO on 2006-07-18 at 14:00:19
A Dark archon's energy is 200/200, Correct? You can change the "200" / 200 by settting the energy %, but you can't change the maximum amount (200/ "200").

I would like the maximum amount of energy to be 10 / 200. Hence the question, how do I make it so the Dark ARchon's energy regenerates untill it reaches 11 / 200 than automatically sets back to 10 /200?


For example, Mind control costs 10 energy. I mind control a unit than my energy regenerates until it reaches 11, than automatically sets back to ten and continues to do so until I use my energy again. Than I can mind control again bringing my energy to 0, than it regenerates until it reaches 11 and sets back to 10 again, etc... etc...

helpsmilie.gif
Thanks.
Report, edit, etc...Posted by Kenoli on 2006-07-18 at 14:06:58
You'd have to use EUDs to detect a unit's energy.
Report, edit, etc...Posted by Mp)Trance on 2006-07-20 at 13:32:11
I assume your trying to make a mana level up system, kind of like the HP level up system? (Hp Heals to 20% at lvl1, and heals to 30% at lvl2, ect)?
Report, edit, etc...Posted by iHaveNoRegrets on 2006-07-20 at 14:55:23
Use death counters to count at the same speed as the energy recharge rate. When it MCs or kills a unit with feedback, have some way to detect that it used energy and subtract in the death counters accordingly. Once the death triggers reach a certain number, make it stop counting and set the unit's energy back accordingly constantly.

Thats all I can really think of, it wont work if you use Maelstrom though, sorry.
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-07-20 at 15:01:43
Is this only going to be for mind control? If so, that makes it a lot easier, since mind control can be detected (as it involves gaining a new unit). All you have to do is have a timing system manage the whole recharge process...first set energy to 1, then 2, then 3 and so on until you get to 10 energy, then hold it there. Just have it subtract counters in your timing system of choice equivalent to 10 energy whenever it detects that the spell is cast. You could easily vary the maximum energy with that system.

If you want to use other spells, though, you're back to EUDs for detection, or looking for a different system altogether, like rotating in a new spellcasting unit for the player after the desired recharge time is complete.
Next Page (1)