#1 - Interpreter, UI and Scenes
Today was the first day of Brainstuck development. There had been a bit of code written as preparation for the project, but today functionality was added.
The first thing to be implemented was a Brainfuck interpreter, but not all characters has been added yet. The following characters are supported:
+ - < > [ ]
This means that Brainfuck code such as:
Will output the correct result (which is 9 in the example above). The following characters have not yet been implemented though:
Implementing them will require a bit more consideration as an output system and input system has to be developed.
Some basic UI got implemented. This is currently what the menu looks like:
What you're seeing is 9 buttons that each link to level 1-9. Currently only the first button works since there's only one level, but each button works when I finish the level creation system.
Currently there are some layout problems with centering the nine buttons depending on the window size.
The text also has to be centered, but this is low priority at the moment.
Some basic level UI was also made:
It's kinda scuffed at the moment, but the basic UI is there. The Brainfuck cells are shown at the top (and they change depending on the actual value). Then there's a textbox below which almost works, currently it only allows for the following characters to be entered:
+ - < , .
The following characters still need to be supported:
> [ ]
This however requires some more work since all of those three characters have something in common, they all require you to hold down SHIFT or ALT. Currently there are some problems / complications with getting direct characters with the DOME game engine. This has been discussed a bit on the DOME Discord and there has been opened GitHub issues for it, so it shouldn't be a limitation for too long.
Below the textbox a START and STOP button can be seen. The buttons have to be centered and actually have be functional. This should only take 10 minutes to add though.
Another thing to add is a STEP button, that allows you to click to go through a character per click, so that it doesn't just run the interpreter really fast to the end.
There are definitely some things to add, but this was very good progress.
The Brainstuck development was streamed live on Twitch: https://www.twitch.tv/benstigsen
Leave a comment
Log in with itch.io to leave a comment.