Gamestudio Links
Zorro Links
Newest Posts
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Data from CSV not parsed correctly
by EternallyCurious. 04/20/24 21:39
M1 Oversampling
by 11honza11. 04/20/24 20:57
Scripts not found
by juergen_wue. 04/20/24 18:51
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
folder management functions
by VoroneTZ. 04/17/24 06:52
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
0 registered members (), 470 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Recharge powers #494
02/28/01 02:42
02/28/01 02:42

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



I want to have this effect..
When I press a key it allows the player to use a certain ability. Now I want the power to only last for a certain amount of time which is based on a meter panel that the player can see. When your meter reaches zero you will not be able to use that power until the meter recharges. Also if you press the key again before your meter reaches zero then your power will begin to recharge from where you stopped using it. I can make it work so far just by using a WAIT command. But I can always use it. I want to limit the use of it. How can I link it to a meter? GS out.

Re: Recharge powers #495
02/28/01 05:22
02/28/01 05:22

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



Try this:

var power = 0;

while (power < 100)
{
//do your stuff;
power += TIME;
....
}


Re: Recharge powers #496
02/28/01 06:17
02/28/01 06:17

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



OK I see what your saying but how can I make the meter panel respond when I press the key that activates the power. Press key, activates power,then the meter starts to decrease. When meter reaches zero,the power cannot be used. Player must wait until the meter recharges to at least 15%. Please help.
GS out.

Re: Recharge powers #497
02/28/01 06:38
02/28/01 06:38

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



Nevermind about the last post I got the meter to decrease. Now how do I tell the meter once it reaches a certain point to slowly recharge? GS out.

Re: Recharge powers #498
03/01/01 04:25
03/01/01 04:25

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



Anyone!?!?! ..... Please help!!!!! GS out.

Re: Recharge powers #499
03/01/01 04:29
03/01/01 04:29

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



Simply extend the script a little , something like this:

var power = 0;
var pwrdown = 0;

while (power < 100)&& (pwrdown == 0)
{
//do your stuff;
power += TIME;
....
}else
{
//do your stuff;
pwrdown=1;
power -= time*0.25;
}

Hope it helps

Trash

------------------
program (pro'-gram) A magic spell cast over a computer allowing it to turn input into error messages.


Re: Recharge powers #500
03/02/01 06:30
03/02/01 06:30

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



help!!!!

[This message has been edited by Gamesaint7 (edited 02 March 2001).]


Re: Recharge powers #501
03/02/01 07:54
03/02/01 07:54

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



Ok I fixed the problem!!!!! I have seen the light baby!! Now I have this ability on a limited basis. I have also implemented a power up so you can keep on rockin you cant recharge anymore. Of course those will be hard to come by. I love this programming stuff!!!!!!!!!!! GS out.


Moderated by  HeelX, Spirit 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1