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,731 guests, and 7 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
Including standard C libraries...? #308856
02/05/10 14:06
02/05/10 14:06
Joined: Oct 2007
Posts: 306
Austria
A
Alan Offline OP
Senior Member
Alan  Offline OP
Senior Member
A

Joined: Oct 2007
Posts: 306
Austria
Hi there,

I would like to know if - and if so how - it is possible to include the standard C-libraries into a lite-C-project. For example, for the purpose of testing and de-bugging algorythms it would be very nice to have the standard console output a "normal" non-visual C program has. When writing such a program, you normally include the "stdio.h" library which allows to use "printf(char* input)" and "scanf(char* formatstring, adress)" to write stuff into the console window and also read keyboard inputs (printf works differently in Lite-C, it displays a message window which is not quite what I want here). Would it be possible to include it in Lite-C too, somehow?

Greets,


Alan

Re: Including standard C libraries...? [Re: Alan] #308859
02/05/10 14:12
02/05/10 14:12
Joined: Feb 2009
Posts: 3,207
Germany, Magdeburg
Rei_Ayanami Offline
Expert
Rei_Ayanami  Offline
Expert

Joined: Feb 2009
Posts: 3,207
Germany, Magdeburg
well, i don't think it will work since printf is used in gs, so i don't think...

Re: Including standard C libraries...? [Re: Rei_Ayanami] #308865
02/05/10 14:34
02/05/10 14:34
Joined: Oct 2007
Posts: 5,211
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,211
İstanbul, Turkey
you can work in semi-console mode if you video_mode = 0;
then printf prints on the white startup screen


3333333333
Re: Including standard C libraries...? [Re: Quad] #308868
02/05/10 14:53
02/05/10 14:53
Joined: Oct 2007
Posts: 306
Austria
A
Alan Offline OP
Senior Member
Alan  Offline OP
Senior Member
A

Joined: Oct 2007
Posts: 306
Austria
Hi,

unfortunately, neither video_mode = 0; nor printing anything outside the message box works for me... When I set video_mode to 0, a small window with black background shows up. Using the "printf()" command still causes a message window to pop up though...

Greets,

Alan

Re: Including standard C libraries...? [Re: Alan] #308879
02/05/10 15:49
02/05/10 15:49
Joined: Dec 2008
Posts: 271
Saturnus Offline
Member
Saturnus  Offline
Member

Joined: Dec 2008
Posts: 271
If I'm not mistaken, not video_mode, but video_screen has to be set to zero.
Can't test this right now, though.

Edit:
Alan, you might be interested in this , too:
http://www.opserver.de/ubb7/ubbthreads.php?ubb=showflat&Number=288005#Post288005

Last edited by Saturnus; 02/05/10 15:53.
Re: Including standard C libraries...? [Re: Saturnus] #308882
02/05/10 15:54
02/05/10 15:54
Joined: Oct 2007
Posts: 5,211
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,211
İstanbul, Turkey
ah, sorry. yeah it was video_screen


3333333333

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