salty Posted July 28 Share Posted July 28 Hi all, I am an absolute beginner in batari basic, and I really only have a very modest goal so far: Making the program sum two numbers and show them in the score. But unfortunately, this does not seem to work as expected. The program compiles, but the score is always shown as 47, no matter how I choose _Num1 and _Num2. Any ideas why? Thanks already for any hints you can give me! set smartbranching on dim _Num1 = a dim _Num2 = b dim _Flip = c dim _Sum = d _Num1 = 5 _Num2 = 12 _Flip = 0 _Sum = 0 scorecolor = $BE COLUBK = $00 score = 0 mainloop if _Flip = 0 then _Sum = _Num1 + _Num2 score = _Sum _Flip = 1 drawscreen goto mainloop Quote Link to comment Share on other sites More sharing options...
KevKelley Posted July 29 Share Posted July 29 Can a score equal a variable? I thought it would have to be an actual number because the score is made up of multiple things (_sc1, _sc2, _sc3) Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted July 29 Share Posted July 29 You might want to read this section: https://www.randomterrain.com/atari-2600-memories-batari-basic-commands.html#bcd 3 Quote Link to comment Share on other sites More sharing options...
salty Posted August 1 Author Share Posted August 1 Ah, thank you, that helped! 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.