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.

Newcomers DBPro Corner / Works in Classic, but not in Pro

Author
Message
Aikidoka
15
Years of Service
User Offline
Joined: 14th May 2009
Location: Australia
Posted: 14th May 2009 17:54
I have a problem with this short piece of code in DBpro that works in classic they way I want, but not at all the way I want in DBpro...

The code is just suppose to grab an image from a bitmap relating to where my mouse is and where I drag the mouse.

In Classic a box will appear while I hold the mouse...perfect
Dbpro is different however...any insight would be great.

Attachments

Login to view attachments
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 14th May 2009 18:57
In Classic, Mousex() and Mousey() retain their values.

In Pro, they reset to zero as soon as you read them after each SYNC. So you need to put them into a variable, and use that instead.

BMacZero
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: E:/ NA / USA
Posted: 16th May 2009 17:34
Quote: "In Classic, Mousex() and Mousey() retain their values.

In Pro, they reset to zero as soon as you read them after each SYNC. So you need to put them into a variable, and use that instead."


I don't think they do? Maybe you're refering to Mousemovex() and Mousemovey()?



Aikidoka
15
Years of Service
User Offline
Joined: 14th May 2009
Location: Australia
Posted: 18th May 2009 08:39
I've managed to sort my problem out.
I ran some tests with mousex() and mousey(). They do retain their values.

my problem lied elsewhere...I think it was the fact that DBPro needs to be in bitmap 0 to draw sprites to screen. I also had some issue with the sizing of the sprite which I managed to resolve.

I will post the code if you're curious as to how I fixed it.

Login to post a reply

Server time is: 2024-11-24 06:46:59
Your offset time is: 2024-11-24 06:46:59