Gamestudio Links
Zorro Links
Newest Posts
zorro license, IB connection
by miwok. 12/06/23 16:32
Newbie Questions
by fairtrader. 12/06/23 11:29
Zorro Trader GPT
by TipmyPip. 12/04/23 11:34
Square root rule
by Smallz. 12/02/23 09:15
RTest not found error
by TipmyPip. 12/01/23 21:43
neural function for Python to [Train]
by TipmyPip. 12/01/23 14:47
Xor Memory Problem.
by TipmyPip. 11/28/23 14:23
Training with command line parameters
by TipmyPip. 11/26/23 08:42
AUM Magazine
Latest Screens
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Who's Online Now
6 registered members (miwok, AndrewAMD, TipmyPip, 3run, Quad, 1 invisible), 645 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
fairtrader, hus, Vurtis, Harry5, KelvinC
19019 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Panel Y scale #345219
10/24/10 11:36
10/24/10 11:36
Joined: May 2009
Posts: 5,367
Caucasus
3run Online OP
Senior Expert
3run  Online OP
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
How do I change panels Y according to skill (my.health)?
I know how to do that in X coordinates:
Code:
panel.scale_x = maxv(0.01,my.health/100);

But how do I make the same with panel in Y coordinates? So it will decrease downwards..
The way I've tried it, is decreases upwards:
Code:
panel.scale_y = maxv(0.01,my.health/100);


How do I make it?


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: Panel Y scale [Re: 3run] #345222
10/24/10 11:46
10/24/10 11:46
Joined: Jul 2008
Posts: 170
Germany, near Mainz
Nicotin Offline
Member
Nicotin  Offline
Member

Joined: Jul 2008
Posts: 170
Germany, near Mainz
"decrease downward" would be increase.
So How about

Code:
panel.scale_y = minv(Max,my.health/100);



or

Code:
panel.scale_y = minv(Max,Max_health - (my.health/100));





Re: Panel Y scale [Re: Nicotin] #345224
10/24/10 11:47
10/24/10 11:47
Joined: May 2009
Posts: 5,367
Caucasus
3run Online OP
Senior Expert
3run  Online OP
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
what is MAX?


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: Panel Y scale [Re: 3run] #345225
10/24/10 11:48
10/24/10 11:48
Joined: Jul 2008
Posts: 170
Germany, near Mainz
Nicotin Offline
Member
Nicotin  Offline
Member

Joined: Jul 2008
Posts: 170
Germany, near Mainz
The maximum value of how much your panel may increase



Re: Panel Y scale [Re: Nicotin] #345242
10/24/10 13:03
10/24/10 13:03
Joined: May 2009
Posts: 5,367
Caucasus
3run Online OP
Senior Expert
3run  Online OP
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
I've tried this one:
Code:
panel.scale_y = minv(Max,my.health/100);


not working, panel is increasing downwards, as well as its size is increasing too. Didn't try the last one. I'll test it now.


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: Panel Y scale [Re: 3run] #346131
11/01/10 16:35
11/01/10 16:35
Joined: May 2009
Posts: 5,367
Caucasus
3run Online OP
Senior Expert
3run  Online OP
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
Could some one help?


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: Panel Y scale [Re: 3run] #346132
11/01/10 16:40
11/01/10 16:40
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
What's the problem?


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: Panel Y scale [Re: Superku] #346156
11/01/10 20:39
11/01/10 20:39
Joined: May 2009
Posts: 5,367
Caucasus
3run Online OP
Senior Expert
3run  Online OP
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
I've made two panels:
* red - health
* green - stamina

They are placed upwards, so they must decrease downwards, like on the picture:

I can make them increase-decrease in X coordinates, but how do I make the same in Y coordinates?


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: Panel Y scale [Re: 3run] #346157
11/01/10 20:48
11/01/10 20:48
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
When you have a formula XXX that gives you values from 0 to 1, just do the following to invert it:

scale_y = 1-XXX;


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: Panel Y scale [Re: Superku] #346158
11/01/10 20:55
11/01/10 20:55
Joined: May 2009
Posts: 5,367
Caucasus
3run Online OP
Senior Expert
3run  Online OP
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
What formula should I use? minv(0.01,stamina/100); ??
Should it looks like this then:
panel.scale_y = 1 - minv(0.01,stamina/100);???


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Page 1 of 2 1 2

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