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 / Text Draw Bug?

Author
Message
Charles Thompson
16
Years of Service
User Offline
Joined: 30th Jul 2008
Location:
Posted: 30th Jul 2008 09:09
Given my limited understanding what happens below should be that whenever they left click their mouse the x and y position should be updated. However, when run x and y always default back to 0. However, when you debug it and put a breakpoint on the sprintf for when the left mouse button has been clicked it works as expected. Any theories? Am I missing something obvious? Thanks in advance.


Charles Thompson
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 30th Jul 2008 17:27
Are you sure the dbMouseMoveX () function is behaving as you expect? If you're looking for the position of the mouse try dbMouseX() and dbMouseY().

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
Charles Thompson
16
Years of Service
User Offline
Joined: 30th Jul 2008
Location:
Posted: 30th Jul 2008 18:27
You're absolutely right. I misread the documentation that comes included. Which BTW doesn't seem to be entirely up to date. For example, it shows one function as dbCls when it's really dbCLS. Is there a place to find more up to date documentation? Thanks.

Charles Thompson
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 30th Jul 2008 18:38
What you see is what you get. The documentation appears to have been edited from the Dark Basic documentation and some oversights occurred. Since C/C++ is case sensitive this kind of error was more apparent.

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
Charles Thompson
16
Years of Service
User Offline
Joined: 30th Jul 2008
Location:
Posted: 30th Jul 2008 18:42
Doh. A shame. The framework seems really simple but I can't tell you how much easier great documentation makes life. They might should consider making it online and allowing user edits. I doubt they will but I can hope,right?

Charles Thompson
Mahoney
16
Years of Service
User Offline
Joined: 14th Apr 2008
Location: The Interwebs
Posted: 30th Jul 2008 18:44
Actually, dbCLS and dbCls are two different commands. They are unique. But, you are right about the documentation. It needs an update.

Windows Vista Home Premium Intel Pentium Dual-Core 1.6 Ghz 1GB DDR2 RAM GeForce 8600GT Twin Turbo
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 30th Jul 2008 18:46
Quote: "They might should consider making it online and allowing user edits."


There's another thread in this forum regarding a Wiki project (unofficial) for that purpose. Sorry I don't have the link handy at the moment.

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
Mahoney
16
Years of Service
User Offline
Joined: 14th Apr 2008
Location: The Interwebs
Posted: 30th Jul 2008 18:47
I do!

http://darkgdk.wikia.com/wiki/DarkGDK_Programming_Wiki

Windows Vista Home Premium Intel Pentium Dual-Core 1.6 Ghz 1GB DDR2 RAM GeForce 8600GT Twin Turbo
Charles Thompson
16
Years of Service
User Offline
Joined: 30th Jul 2008
Location:
Posted: 30th Jul 2008 18:48
Thanks for your help Lilith. I'll let you know if my minesweeper clone gets made thanks to this.

Charles Thompson
Charles Thompson
16
Years of Service
User Offline
Joined: 30th Jul 2008
Location:
Posted: 30th Jul 2008 18:52
Wow, you guys are really going to need to hurry up and make some more pages. Quarter of the manual isn't done. I'll look into contributing later tonight.

Charles Thompson

Login to post a reply

Server time is: 2024-09-30 03:18:32
Your offset time is: 2024-09-30 03:18:32