Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
2 registered members (TipmyPip, 1 invisible), 18,758 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
a little problem with panels and windows #321059
04/26/10 20:16
04/26/10 20:16
Joined: Apr 2010
Posts: 56
Badrizmo Offline OP
Junior Member
Badrizmo  Offline OP
Junior Member

Joined: Apr 2010
Posts: 56
Dears,

I'm very new to 3dgamesudio and I was trying to make an altimeter. I used the below code

///////////////////////////////////////////////////////////////////////////////////////
#include <acknex.h>
#include <default.c>



BMAP* altimeter_png = "altimeter.png"; // w=122px h=355px
int altimeter_varx = 0;
int altimeter_vary = 0;
PANEL *altimeter =
{
layer = 2;
window(20,20,122,100,altimeter_png,altimeter_varx,altimeter_vary);
flags = VISIBLE;
}

function main()
{
video_mode = 6;
screen_color.blue = 150;

while(1)
{
altimeter_vary++;
wait(10);
}
}
///////////////////////////////////////////////////////////////////////////////////////

but unfortunately the window is not sliding on the altimeter image.
Please help me as I don't have any idea why it is not working.

Re: a little problem with panels and windows [Re: Badrizmo] #321061
04/26/10 20:22
04/26/10 20:22
Joined: Mar 2005
Posts: 564
/www/europe/ germany/index.php
TSG_Torsten Offline

User
TSG_Torsten  Offline

User

Joined: Mar 2005
Posts: 564
/www/europe/ germany/index.php
It shouldn't be the problem, but may don't declare "int" but "var", i don't know if the engine makes differences when working with window(). The rest of the code seams to be ok, I can't see any mistake by looking at it.

Regards
TSGames

Re: a little problem with panels and windows [Re: Badrizmo] #321062
04/26/10 20:24
04/26/10 20:24
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
Just an educated guess, but try changing
int altimeter_varx = 0;
int altimeter_vary = 0;
to be
var altimeter_varx = 0;
var altimeter_vary = 0;

It MAY be that "window" requires "var" types rather than integers...


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: a little problem with panels and windows [Re: EvilSOB] #321307
04/28/10 05:54
04/28/10 05:54
Joined: Apr 2010
Posts: 56
Badrizmo Offline OP
Junior Member
Badrizmo  Offline OP
Junior Member

Joined: Apr 2010
Posts: 56
Thanks a lot, changing int to var Solved the problem


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | 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