More General posts
August 22, 2002
Game Scripting in Python

From Gamasutra (free registration required) an article about using python as a scripting languages in games. From what I've read most recent computer games use an embedded script language to control gameplay. Many companies write their own. Rather than develop yet another scripting language this article advocates using python. Same sort of reasoning is behind the company I work for choosing to use javascript instead of developing our own language. I've worked with products where the developers decided to roll their own. Not pretty.

The article lists reasons why you should use a standard scripting language. I'd add that people incorrectly choose to write their own for a couple of reasons.

  • They've always wanted to write a language that works the way they want it to and fixes the deficiencies they see in all other languages. I think most programmers have felt like this at one time or another. The problem is that decent language design is more difficult that it looks from the outside. I don't think you have to be a card carrying member of the language designers union but perhaps a realistic appreciation of your experience and skills, and the potential difficulties, would be useful.
  • The problem they're trying to script for looks pretty simple so clearly a fully fledged language is not needed. Unfortunately the requirements for the language always expand so the features needed have to expand with them. Languages that grow by accretion this way often end up with a strange mismash of features and notations.

Of course there is a tension between this and my previous words in favor of Domain Specific Languages. How to resolve this? I have some ideas for later.

Posted by Alex at August 22, 2002 09:02 PM
Comments
Post a comment
Name:


Email Address:


URL:


Comments:


Remember info?