hi!
in order to poke integers to a DLL i compiled with FreeBasic, i need to know how to store bytes in the bank.
the first step is: if you type >Bank=CreateBank()< in bb. does the variable bank contain the memory pointer?
the next step would be to poke integers offsetted to that position. in what direction they go will be easy to find out. but how do i do this anyway? some ideas?
(if anyone knows something about FreeBasic, it would be
brilliant!)
thanks for thinking about it :)
bye!
edit:
bb code:
in order to poke integers to a DLL i compiled with FreeBasic, i need to know how to store bytes in the bank.
the first step is: if you type >Bank=CreateBank()< in bb. does the variable bank contain the memory pointer?
the next step would be to poke integers offsetted to that position. in what direction they go will be easy to find out. but how do i do this anyway? some ideas?
(if anyone knows something about FreeBasic, it would be
brilliant!)
thanks for thinking about it :)
bye!
edit:
bb code:
Graphics 640, 480, 32, 2 SetBuffer BackBuffer() bank = CreateBank(32) banktest(bank) For i = 0 To 31 Write i + " = " Print PeekByte(bank, i) Next WaitKey() EndfreeBasic code:
' fbc -dll mydll.bas declare function banktest lib "BankTestDLL" alias "banktest" (byval bank as integer) as integer function banktest(byval bank as integer) as integer export poke byte, bank + 8, 123 function = 1 end function