Gamestudio Links
Zorro Links
Newest Posts
Executing Trades on Next Bar Open
by vicknick. 06/13/24 08:51
Zorro Beta 2.61: PyTorch
by jcl. 06/10/24 14:42
New FXCM FIX Plugin
by flink. 06/04/24 07:30
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
0 registered members (), 1,250 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19059 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Horizontal Slider - starting position? #7291
10/24/01 04:50
10/24/01 04:50

A
Anonymous OP
Unregistered
Anonymous OP
Unregistered
A



I'm trying to make a horizontal slider that controls the movement of one of my characters. It will control the zoom-in, zoom-out feature of the camera position.

My problem is trying to get the initial position of the slider to be in the center of the variable spread, so if I move it to the left, the variable is negative, and if I move to the right, the variable is positive. The only problem is the bmap in the hslider function always starts at the extreme left. Is there a way to make it start in the center of the variable spread, so the number can decrease or increase, not just increase?


Re: Horizontal Slider - starting position? #7292
10/24/01 05:34
10/24/01 05:34
Joined: May 2001
Posts: 1,261
Outarville, France
al1 Offline
Expert
al1  Offline
Expert

Joined: May 2001
Posts: 1,261
Outarville, France
look at this :


hslider = 11,90,100,cursor_map,1,3,var_slide;

If i start with var var_slide = 1; the cursor start at left

If i start with var var_slide = 2; the cursor start at middle

If i start with var var_slide = 3; the cursor start at right

You can't use negative value but you can write :
val_zoom = var_slide -2;




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