Announcing Basic Language With Graphics (Beta)
amasad (3355)

Hey everyone!

I've been working on a classic BASIC language inspired by Microsoft Atari Basic. It comes with a 50x50 display by default and makes it really easy to draw things and make games. The language is still in Beta and I'll be improving it over the coming weeks. For now here is the documentation and a sample snake game that I found on the internet and modified to make it work here. Please let me know what you think.

If you're curious you can find the source code for the interpreter here ( Feel free to fix bugs and send patches.

[update] Docs moved here:

[update 2] Changelog:

  • You can now use variables with multiple letters
  • LET is optional. You can define variables like so 10 X = 1
  • TEXT lets you draw text on the screen (refer to docs)
  • Display is now automatically focused after the program is run
  • GETCHAR handles long-presses better

[update 3] Changelog:

  • You can now create multidimensional arrays ARRAY a, 2
  • You can now draw an entire grid with one call DRAW
  • Refer back to docs
You are viewing a single comment. View All
CodingCactus (4178)

Really cool, I feel like your example for the ATAN is wrong (typo), it says:


Should it say?:


Also, I'm confused about the ASC one, if you write:

10 PRINT "s"

It gives out 115. Why doesn't it just print: s ?

Also, it says in the lowercase section


will print "basic", is this a typo? should it be LOWERCASE("BASIC")?

Anyway, this looks really cool Well done!

sugarfi (626)

@CodingCactus the reason 10 PRINT "s" prints out 115 is because that is the ASCII code for s.

CodingCactus (4178)

@sugarfi so why does 10 PRINT "hello" print hello and 10 PRINT "s" print 115
surely they are the same thing?

sugarfi (626)

@CodingCactus not really. hello is more than one character, so it doesn't have one single ASCII value. s, on the other hand, has one value and so that is printed.

CodingCactus (4178)

@sugarfi It was just a typo, it was supposed to be 10 PRINT ASC("s")

sugarfi (626)

@CodingCactus ok. just out of curiosity, how do you know it was a typo? Is the source for this implementation available somewhere?

CodingCactus (4178)

@sugarfi look at the ASC section now, it has been changed

xxpertHacker (855)

@CodingCactus Does it support Unicode? Can I assign a variable a number with a decimal point?

xxpertHacker (855)

@amasad Does ASC() work with Unicode characters?

amasad (3355)

@StudentFires yes. I guess that makes the name kind of silly but it relies on JavaScript strings.

xxpertHacker (855)

@amasad Okay. Good luck with the language!

amasad (3355)

@StudentFires thanks. Are you going to try it?