Lua SyncedInterface


There can be two flavors of Lua scripts, Synced and Unsynced. This corresponds to the network model Spring uses. Currently only Synced scripts are supported. This page documents the available functions and classes.

For more documentation, see LuaBinder.cpp :)

Contents

Classes

Script

This class is meant to be subclassed in a lua script, and spring will call methods at various times.

Name Comment
constructor(string) Pass the string that should be visible in the selection menu
string GetMapName() Return the map that should be used to bypass the map selection menu, or return "" to show the menu
void Update() Called once every simulated frame
void GotChatMsg(string, int) Called when a chat message is received. The first parameter is the message, and the second the id of the sending player

float3

General functions

units

[[Category:Development

Retrieved from "http://spring.clan-sy.com/wiki/Lua_SyncedInterface"

This page has been accessed 497 times. This page was last modified 14:52, 29 January 2007.




Page editing toolbox

Browse
Main Page
Community portal
Current events
Recent changes
Random page
Help
Donations
Edit
View source
Editing help
This page
Discuss this page
Post a comment
Printable version
Context
Page history
What links here
Related changes
My pages
Log in
Special pages
New pages
File list
Statistics
Bug reports
More...

Site layout created by Roflcopter.