I created this thread to discuss this topic, as the original by Jasuk70 is too old to post in.
For reference, this is Jasuk70's original post:
http://forum.thegamecreators.com/?m=forum_view&t=68687&b=1And this is IanM's utility post, which is also a necessary part of this discussion:
http://forum.thegamecreators.com/?m=forum_view&b=18&t=85209&p=0The Issue==========
I have this code working to an extent. I have used Jason's framework, and changed the application to my own.
Next, I changed the enhancements File Map commands and replaced them with IanM's Memory Bank equivalents, as suggested by Wolf. This does indeed bring the whole thing to life, and the heartbeat works. The mouse coordinates are passed and messages can be exchanged.
The problem is that I now have a black DB Pro screen, rather than my application. As you can see in the image below, I had a visible screen, until I replaced the Memory Bank commands...
I have tracked this down to the following line of code in Jason's ProcessMessage() function:
aMessage=bank String$(cMAPSEND,0, 1024)This retrieves the message from the memory bank in order to respond. I think it is probably the bank size that causes the problems.
In the VB app, it is 2048 bytes. I have tried this value, and also 1024 to prevent it running over. The data itself is about 10 bytes long, but could be
any length. With the original File Map commands, no size was required so I have nothing to relate it to.
Other similar commands work, such as the heartbeat. But here, I know the length is exactly 4 bytes. Hence my reasoning that the length is the issue.
Any profound thoughts on the matter?