I have been using PB2.0 with VB3 to make a role playing game creation
engine. And I am greatly impressed with the results I have with
the two language. Over the past week I have been trying to port
my code to PB6.0 and VB5 to take the application to 32bit.
On the PB side a few commands have been left out for the upgrade namely:
GetStrAlloc and RlsStrAlloc.. Several people have posted some alternatives
ways of allocating memory but this initially bothered me.
But here is the real issue..
When using Vb3 in conjuction with PB2.0, I was able to pass a pointer
to a variable or an array once and have the PB .DLL application
hold its value through the entire execution of the code. Allowing
the PB application to update/manipulate global variables "in sync" with
VB3. I was very impressed at how well it worked with my game application.
I have tried to convert the code to VB5/PB6 and I am unable to get
the same results. It appears that Vb5 moves variables around while
the program is running. Global variables/arrays must constantly
be re-passed to PB .DLL's throughout the execution of the code. Else
PB will attempt to update a variable that "isn't there anymore" Also
causing PB to write in arbitrary areas of memory.. (BAD)
I discovered this when I passed a Variable UDT to PB and began printing
the pointer location values to a disk file. I noticed that the
variable location (*pointer) began to change/move as the code continued to run.
This concerned me, and I was wondering if anyone was experiencing
the same problems or could shed some light on making this conversion
go smoother.
If this is the case, I may remain a 16bit developer.. 32bit is too unstable
for my tastes..
Tyrone Lee
------------------
Explorations v3.0 RPG Development System
http://www.explore-rpg.com
engine. And I am greatly impressed with the results I have with
the two language. Over the past week I have been trying to port
my code to PB6.0 and VB5 to take the application to 32bit.
On the PB side a few commands have been left out for the upgrade namely:
GetStrAlloc and RlsStrAlloc.. Several people have posted some alternatives
ways of allocating memory but this initially bothered me.
But here is the real issue..
When using Vb3 in conjuction with PB2.0, I was able to pass a pointer
to a variable or an array once and have the PB .DLL application
hold its value through the entire execution of the code. Allowing
the PB application to update/manipulate global variables "in sync" with
VB3. I was very impressed at how well it worked with my game application.
I have tried to convert the code to VB5/PB6 and I am unable to get
the same results. It appears that Vb5 moves variables around while
the program is running. Global variables/arrays must constantly
be re-passed to PB .DLL's throughout the execution of the code. Else
PB will attempt to update a variable that "isn't there anymore" Also
causing PB to write in arbitrary areas of memory.. (BAD)
I discovered this when I passed a Variable UDT to PB and began printing
the pointer location values to a disk file. I noticed that the
variable location (*pointer) began to change/move as the code continued to run.
This concerned me, and I was wondering if anyone was experiencing
the same problems or could shed some light on making this conversion
go smoother.
If this is the case, I may remain a 16bit developer.. 32bit is too unstable
for my tastes..
Tyrone Lee
------------------
Explorations v3.0 RPG Development System
http://www.explore-rpg.com
Comment