Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Arcade Game Written in VFP
Message
From
17/07/2001 19:12:49
Gerry Schmitz
GHS Automation Inc.
Calgary, Alberta, Canada
 
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00531577
Message ID:
00531800
Views:
14
>My question to all you API gurus out there is if you might know a way to use API calls (maybe BITBLT) to move an object instead of just repositioning the left and top properties of it as I am doing now. If I could speed up the moving of the actual main sprite character perhaps using API calls then it could run on a slower system.

You might want to first consider adding your "move" routine to a FLL and utilize the VFP API. Depending on how much code is involved in "moving" a particular object, an FLL routine "might" be more efficient than straight VFP code.

You can probably get a boost using Windows API calls, but you have to appreciate that VFP won't "know" what you may have painted via the Windows API. Once you've finished painting, VFP will overwrite your changes as soon as you "unlock" the form/Screen.

You can use the Windows API to, say, move an object from A to B, but you will need to tell VFP to "erase" at A and (re)write at B, after you have done your moving "between A and B" via the Windows API (between screen/form locks).
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform