Jump to content

Javascript as a secondary programming language


Recommended Posts

  • 3 weeks later...

Some benchmark:

Javascript ( with some debug informations ), two times slower than c++

spacer.png

 

Lua ( requires debughook to do not get terminated due infinity loop protection )

8r7ecu9.png

 

Js is faster in this case because "add" function was called simillar each time, calling same function with different arguments ( mostly different types )  may cause performance to degradate ( Jitted functions get deoptimized )

  • Like 2
Link to comment
On 11/02/2021 at 19:30, Haxardous said:

afaik v8 (MTA JS implementation that CrosRoad95 working on) isn't working as Slipe (NanoBob's C# "translator")

- Slipe: C# (csharp.lua) > Lua > C++

- V8: JS > C++

 

That is true, the current Slipe (which we call "Slipe Lua") translates the C# code to Lua before running it. But this still gives you plenty of benefits.
We are however also working on a way to run native C# code on an MTA Server, which we are doing by creating the MTA server itself from scratch.

  • Like 2
Link to comment
  • 1 month later...
  • 2 months later...
  • 1 month later...

Language competition sounds great. Hopefully we will attract more developers that are just interested in a comfy sandbox development environment this way! JavaScript after all is very popular, and C# is powerful. In order to make integration of JavaScript and C# worth it please consider carefully suggesting our great and capable MTA client to game enthusiasts across game dev forums.

Link to comment
  • 2 months later...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...