Gamestudio Links
Zorro Links
Newest Posts
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (degenerate_762, AbrahamR, AndrewAMD, ozgur), 667 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Can't get pan_setdigits to work #330539
06/28/10 09:04
06/28/10 09:04
Joined: Jan 2010
Posts: 40
Adelaide, Australia
Sub_Game Offline OP
Newbie
Sub_Game  Offline OP
Newbie

Joined: Jan 2010
Posts: 40
Adelaide, Australia

I'm having some trouble with making my HUD. This code executes and then crashes due to the pan_setdigits line.

Where am I going wrong with pan_setdigits?

Code:
wpn_pnl = pan_create(NULL,0);
pan_setdigits(wpn_pnl,0,300,200,2,"Arial#40",1,sys_seconds);
set(wpn_pnl,SHOW);



Last edited by Sub_Game; 06/28/10 09:06.

A7 Commercial
First person submarine combat simulator project
http://alexanderforeman.webs.com/fightersubgame.htm
Re: Can't get pan_setdigits to work [Re: Sub_Game] #330540
06/28/10 09:15
06/28/10 09:15
Joined: Jan 2004
Posts: 3,023
The Netherlands
Helghast Offline
Expert
Helghast  Offline
Expert

Joined: Jan 2004
Posts: 3,023
The Netherlands
does it work when you do it like the manual does:

Quote:

PANEL* my_panel = pan_create(NULL,0);
pan_setdigits(my_panel,0,300,200,"%2.f",font_create("Arial#100"),1,sys_seconds);
set(my_panel,SHOW);


regards,


Formerly known as dennis_fantasy
Portfolio - http://www.designorhea.com/
Project - http://randomchance.cherrygames.org/
Re: Can't get pan_setdigits to work [Re: Helghast] #330544
06/28/10 10:46
06/28/10 10:46
Joined: Jan 2010
Posts: 40
Adelaide, Australia
Sub_Game Offline OP
Newbie
Sub_Game  Offline OP
Newbie

Joined: Jan 2010
Posts: 40
Adelaide, Australia
Code:
wpn_pnl = pan_create(NULL,0);
pan_setdigits(wpn_pnl,0,300,200,"%2.f",font_create("Arial#100"),1,sys_seconds);
set(wpn_pnl,SHOW);


This works! Thank you.


A7 Commercial
First person submarine combat simulator project
http://alexanderforeman.webs.com/fightersubgame.htm

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

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