Very nice Nathaniel, how did you do the glow, did you have to pixel plot everything manually?
If you change the characters to A to Z it doesn't look too different. But maybe we do get laughed at for the nonsense words.
Coding along with the Coding Train again. Today it was the Matrix rain episode. Couldn't get glowy text to work. Seems GFILL and GPUTCHR don't draw anything if alpha isn't 255. Mangled the stream concept too, it is just a function that generates symbols in my version. I think it still looks pretty good.
I would try generating the world into an array then copying things into the bg pages as needed. Then you only have to generate things once. Even without a memory buffer you should be able to fit several screen fulls of data into the bg pages. Then you can use bgofs to scroll around.
So, if you reseed the random number generator with a given seed you should get the same random numbers out each time (assuming nothing else in the game uses them before you get to them). That does mean you have to keep track of a seed per re-creatable area. I wouldn't try it with small of slices.
SmileBasic isn't too memory poor it should be able to generate pretty big worlds.
It sounds like you are building the map based on a random number generator. Right? I am assuming SmileBasic is using something like a Merssenine twister for it's random number generator. In something like that, the next random number is based on the last one generated. You can however seed the random number generator with any starting value you like with randomize.
Thanks!! That was a big help! It looks like my problem was a side distance y that I mistyped as side distance x. Copy paste strikes again.
Now I have a question, is it me, or is the display mirrored?
This is what I think it should look like.
It is nothing fancy, very basic. Here is a shot of me trying to debug things. Seems at a certain point it just doesn't see walls anymore. Must be something with stepping from block edge to block edge.
I tried adapting some raycasting code I found at lodev•org/cgtutor/raycasting•html Unfortunately I have some bugs, the view falls apart when looking from certain angles. Not sure what I did wrong.
If you have python 3.6.1 or better and the ability to install software running the following from the command prompt should get you pygame.
python -m pip install pygame --user
Works for other libraries too. Have fun.
Or you could just look at the spooky maze code. The author kindly made a raycating library to help you make your own 3D-ish games. Doom actually uses something else called a BSP tree. Not sure if you can do that in SmileBasic with no pointers, but it allows for non-grid geometry. However it wasn't really 3D either, but Quake was.
If you can find it, chapter 6 of 1994's Tricks of the Game Programming Gurus by LaMothe, Ratcliff, Seminatore, and Tyler covers it extensively in DOS C code.