Scripting Roundtable (Friday): Overview (Josh's Notes)
- Topics:
- When is a scripting language worthwhile?
- How complex?
- When should it be replaced?
- How to make easy to use?
- Buy vs. Build? (custom vs. off-the-shelf)
- Integrating with the game
- Who is it for?
- Debugger?
- Memory/resource allocation
- Speed
- Familiarity
- Portability
- Someone put logic in the user data in Max, could visually lay out positions/triggers
- Limitation: hard to track
- Limitation: limited sophistication/space in user data
- Most people would use a scripting language again
- One person: found very worthwhile to put scripter in same office as artists
- Advantages:
- Usable by non-programmers
- Fast compile/turnaround
- Can change while running
- Lots of iteration by designers
- Prototyping ideas
- Performance tricks used by people: compiling to C++, JIT (found to be 2x-3x faster)
- Call C functions:
- People said they found calling C from Java was tricky, someone else said it is easier if you use one of the embedded versions of Java
- Someone created a custom JVM, initially allowed ints to be passed to C functions, later supported strings, etc.
- Calling C from Python was said to be easier
- Some guy working on embedded apps ended up switching to C/C++ after prototyping since script was too slow
- Some are using script languages to change servers at runtime without downtime
- Debugging, development time seen as the biggest disadvantages
- Tip: write out source line numbers into p-codes (can then do source-level debugging)
- "Stars! Supernova" Crisium - rules description language, also AI
- S-Lang: Lua-like (small & dynamically typed), C-like syntax
- Lua gave problems (in older versions) to LucasArts: misspelled variables, assumed global unless declared local
- Someone was happy with Small, though Legal had some problems with using a "free" language
- Look at Civ Call to Power script lang
- Things left out in special purpose languages:
- Inheritance
- "What is the problem you are trying to solve?" -- be very custom, usually shouldn't try being a general language
- Knowledge of "what the problem is" changes, should adapt language to be a really good fit