9

microStudio now supports 4 programming languages: microScript, Python, JavaScrip...

 2 years ago
source link: https://microstudio.dev/community/news/microstudio-now-supports-4-programming-languages-microscript-python-javascript-and-lua/254/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

microStudio now supports 4 programming languages: microScript, Python, JavaScript and Lua!

This is quite the big update: you can now choose from 4 programming languages for your microStudio project: microScript, Python, JavaScript or Lua! All this still from your web browser. With any of these 4 languages, you have access to all the microStudio goodness: live edit your code, live help and screen positioning hints, use the new graphics libs for 2D or 3D, use the optional libs like Matter.js and Cannon.js, export your project to HTML5, Windows, Mac, Linux, Android in one click.

You can thus create your next 3D game in Python with Babylon.js. Or make another one in Lua, relying on Matter.js and Pixi.js. How awesome is that?

Why Python?

In many countries, high school students have to learn Python. Letting them stick to Python with microStudio will help them practise the language they will be tested on, rather than having to switch from one language to the other.

Why JavaScript?

Some users may be concerned with performance for their game. I have good news for them regarding microScript (read below), but if you are making a procedurally generated world in real time with thousands of collision checks or whatever, you may want to rely on the core language of your engine and avoid adding another language layer on top of it. In microStudio, the core language is JavaScript and JavaScript in the browser is insanely fast.

Why Lua?

I have heard people asking why they would have to learn a different / simplified Lua when they already know Lua. Offering Lua will maybe make microStudio more attractive to these users.

What about microScript?

microScript remains the best language to work in microStudio, here is why:

  • microScript is simpler, yet complete and very forgiving to beginners. microScript won't call you names because you forgot to define a variable.
  • No runtime errors: microScript cannot break at runtime. This is a huge advantage: it means you can really work on your program while it is running, making changes live without the risk of breaking the flow constantly and having to restart the game every time.
  • With today's release comes hot updates of classes, meaning that you can work on a class definition and instantly see the result applied to all the object instances derived from your class in the running game. This is making coding in microStudio even more interactive.
  • I made a lot of research and thinking on microScript v2. This new version will not only bring a few more features, some more flexibility and a clarified specification. I have started working on a new type of interpreter, based on an intermediate representation and a stack machine. This interpreter is showing great performance, to the point I will have to evaluate if a transpiler is still needed. It is also more flexible in many ways, allowing to get rid of the "timeout" limitation, to interrupt and resume execution at any time (think "breakpoints"). It is also the best working base you can imagine for a future implementation of microScript in C / C++, for native exports.

I would like to add that today's update (as well as recent updates with 2D/3D engines and physics engines) wouldn't be possible without the hard work of fantastic people making all the following open-source libs:

And of course also:


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK