Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Int gives out random number? makes no sense :s

Author
Message
Freedom Fighters
14
Years of Service
User Offline
Joined: 2nd Nov 2009
Location:
Posted: 14th Feb 2010 12:00
ok. i just got it that when i look at my 'int' variables are giving random out puts when converted to char. so im a bit confused on why thou.

this is my source for my settings



'AATEXT' is used for drawing text. see thread for more details.

any ideas on what to do?

what can i do to write my own function for converting int to char*?

Problem Solution That Never Fails: "Build A Bridge And Get Over It"
Aldur
16
Years of Service
User Offline
Joined: 8th Oct 2007
Location: Melbourne, Australia
Posted: 14th Feb 2010 13:00 Edited at: 14th Feb 2010 15:38
I would suggest staying away from using dbStr().
Use sprintf_s() instead.

There is a thread concerning the best way to do what you are needing, have a read through this: http://forum.thegamecreators.com/?m=forum_view&t=165216&b=22

EDIT:
I just wrote up a class similar to yours and used the sprintf_s function which printed the appropriate values to my .ini file.

If there are anymore problems with it, let me know and i'll post back with the class that I quickly wrote.

Login to post a reply

Server time is: 2024-10-02 01:34:15
Your offset time is: 2024-10-02 01:34:15