i am developing a Multiplayer(actually MMORPG) architecture for learning purpose.

I do have some game developement background, but all my engines were very rigid and completly developed for the game itself.

That being said, i wanted to experiment so i designed a generic Entity/Component Model Architecture where i would like to extend the game logic, npc, ai, entities and game objects definition(monsters, characters, weapons, items, etc...) using a Scripting language for Code-Reuse and Hot Load/Reload purpose.

My questions are as follow: Considering that i want a scripting language with the best performance possible and that it need to be actually compatible with both .NET/Mono, what are my options? What would you suggest? I know Lua and Javascript are common, but how about performances? What would be my other options? What managed interpreter library would you use?

How would you proceed to implement such scripting language support in an engine? I plan to actually update the server-side simulation about 10 times per second.

Thanks in advance! ;)

  • 1
    \$\begingroup\$ Why do you care about performance so much? Very large, complex, AAA games have been written using relatively under-performing scripting languages. Worry more about ease of use, ease of integration, and solving real problems than about getting the best performance. \$\endgroup\$ – Sean Middleditch Jun 19 '13 at 22:32

I've been using LuaInterface from c#/XNA. Mostly thus far I've been using it for entity creation (I too am using an entity-component system). That's been working pretty well. I can't speak to the speed as entity-creation is a comparatively rare event, though soon I intend to script collision handling, etc. I suspect it should be fast enough, I understand that Civ and quite a few others use it. It's quite quick in creating the entities (script time is negligible vs the asset loading).

I'm considering switching to CS-Script. I'm not dissatisfied with Lua, but there's some basic impedence in switching between the two. I figure if I can do my scripting in C# it would just make things that much easier. And since the C# script is compiled into an assemby, speed shouldn't be an issue.

| improve this answer | |
  • \$\begingroup\$ Thanks for the reply. Could you give more informations on how you use and deal with your different script? What they do? When they are called and how often? It could give me a good idea about what to expect. ;) \$\endgroup\$ – JPSavard May 20 '13 at 21:18
  • \$\begingroup\$ +1 for CS-Script. Also, in my case, right now CS-Script is used to reload components (as in a component-based entity system) in real-time. Just one of the many benefits of having your scripting language be the same language as the rest of your game. \$\endgroup\$ – Robert Rouhani Jun 19 '13 at 21:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.