Re: Built in function tried to access memory outside heap or screen
I was able to solve the first problem, which was the one that was throwing off the error in the title. I was making a trivial mistake (as I always do...). Instead of loading the whole directory, I was only loading the Main.vm. After this, square game functions properly in the vm emulator.
However, translating it into lower level and loading it into the cpu emulator still does not function properly and creates that strange pattern, and eventually the error.
I wish there was more robust testing for the chapter 7 and 8, because the experience has been very frusturating, even after passing all the tests given by the course and contributors, vm translator still seems buggy. Hopefully, it will be fixed in the second edition.
I will now start focusing on my project 9, and maybe go back to the problem later.