Expression2/Starfall S&Box alternative

There have been a couple threads asking about a coding language for players on a server, not raw C# ofc.
I want to reignite the discussion about this, because i think it has potential.
I actually wrote a lexer/tokenizer in C# and am still expanding my little Expression’3’, but i think most stuff is still S&Box dependant (i don’t have access). I wonder what would be the most clean way of creating a E2 port (scary stuff) or a new language altogether.

My idea/feature list is:

  • NO direct C# execution in any way (C#, from my knowledge, doesn’t have sandboxing) - server security is first priority
  • Separate files for types/tokens/operators/modules
  • Access levels (provide more proficient players with more fun stuff to make, and restrict new players from abusing it)
  • As much flexibility as possible (modify/create/restrict functions/modules). Useful when making your own sandbox server - add server-specific functionality.

I might expand this later, if something comes to mind.

Also, as said, i am kind of new’ish to C# and would like any project organization tips for this. (thanks in advance <3)

1 Like

Previous threads/replies:
[Ingame Scripting]
[S&box WAYWO April 2021 - #32 by Robadob]

Myself and thegrb93 are both working on (separate) Lua interpreters for s&box. I think he’s serious about creating a successor to starfall whereas my thing is just a shitpost at this point.

Some of my fondest memories of gmod are from dinking around in E2 so I’m glad to see another person interested in working on this kind of thing.

1 Like

Why there has to be another (and probably worse) language?
It was a pain to move from E2 to Lua back when I was figuring out programming. C# already has everything, it is easy to learn and you can use all the knowledge you get outside of S&box, so why put a layer of pretty much useless and slower language like Lua in that?

You don’t get it.
C# Is great, but it isn’t safe to let any player on your server use it, at all. Gmod wasn’t only for friends goofing around on a local server with lua, and S&box will not be too. In C# you can’t just restrict someone from doing dirty stuff - no sandboxing functionality.

It won’t be as slow as E2 for sure. I don’t think Lua is the only option, it’d be fun to make something new, closer to E2, but more refined.

And we obviously need some kind of benchmark/cpu limit (memory too perhaps) with this, because noone wants a server lagging/crashing from the hands of a ‘particularly’ smart coder/player. OPs in E2, I think were a joke, because the only thing server suffers is cpu time, so i still have no idea why it has that.

1 Like