04-12-2011, 10:34 PM
Code:
10 BORDER 4
20 CLS
30 PRINT AT 1,9;INK 3;"Hello World from Assi";
40 END
Hi,
The above code gives green paper with a magenta in ink in the text
message when run the second time from the BASIC loader.
Paper/Border rerun bug
|
04-12-2011, 10:34 PM
Code: 10 BORDER 4 Hi, The above code gives green paper with a magenta in ink in the text message when run the second time from the BASIC loader.
04-13-2011, 07:20 AM
That's to be expected (at the moment). The code in charge of initializing the heap is within the heap free space (to save some precious bytes), thus destroyed upon first execution. A compiler flag will be added to specify "rerunable code" or not. Usually games don't return to BASIC once started. :wink: So, this will go to the TODO list (it's rather easy to implement, will try to do it this week, but I'm currently working on FOR loops).
04-13-2011, 12:36 PM
It is sometimes nessesary to return to BASIC for loading levels (from a disc system like +D).
------------------------------------------------------------
http://lcd-one.da.ru redirector is dead Visit my http://members.inode.at/838331/index.html home page!
04-13-2011, 12:50 PM
Quote:Usually games don't return to BASIC once started. :wink: So, this will go to the TODO list (it's rather easy to implement, will try to do it this week, but I'm currently working on FOR loops). Thanks. It would make it easier to mix BASIC and compiled code were the slow code could be written in pure ZX BASIC like instuctions and such and the game itself is compiled. In that scenario if one is redefining the keys in uncompiled BASIC how easy would it be to pass the information to the compiled code? Or even if one would do away with uncompiled BASIC altogether and just compile the program in two parts, one in low memory and one in high memory, how to pass info between the two apart from POKEing and PEEKing? Both parts are then rerunable.
04-14-2011, 11:10 AM
Not a very good idea because independend compiled codes won't share their librarys and so there will be some double code, occypying some extra KB, and two Heap spaces.
------------------------------------------------------------
http://lcd-one.da.ru redirector is dead Visit my http://members.inode.at/838331/index.html home page!
04-14-2011, 02:02 PM
LCD Wrote:Not a very good idea because independend compiled codes won't share their librarys and so there will be some double code, occypying some extra KB, and two Heap spaces.That is why memory management would be good and perhaps a linker. Memory Management <!-- l --><a class="postlink-local" href="http://www.boriel.com/forum/wishlist/memory-management-t621.html#p2245">wishlist/memory-management-t621.html#p2245</a><!-- l --> |
« Next Oldest | Next Newest »
|