![]() |
RigsofRods
2023.09
Soft-body Physics Simulation
|
Welcome to the developer portal of Rigs of Rods! Rigs of Rods is a flexible physics simulation environment, supporting a multitude of mods (terrains, vehicles and loads, addon parts, skins, HUDs, gadgets) and offering extensive scripting capabilities using the AngelScript language. This documentation covers scripting features of both the game (client) and the server, from friendly introduction pages to full technical reference. It also covers the full game codebase (written in C++) language, as it very closely matches the scripting realm and can help gaining deeper understanding. To ask questions and suggest extensions, visit our Discord #development channel.
Quick links (for regulars)
- Script doc modules: ScriptrSideAPIs | Script2Game, Game2Script, Script2Script | Script-to-Server Server-to-script
- Client global objects: `game`, `inputs`, `modcache`, `console`
- Client principal enums: `scriptEvents`, `MsgType`
- Server global object: `server`
- Server principal enums: `broadcastType`, `authType`, `serverSayType`
The single best way to get familiar is with the bundled **(in-game) Script editor gadget**. To open it, use top menubar (hover mouse near top to see it), menu 'Tools', item 'Browse gadgets ...' and in the selection window find 'Script editor'. It always opens with pre-made script Tutorial.as - you can simply hit the RUN button to see it in action, and then try making some edits and see what happens.
To get familiar with the AngelScript language, visit it's reference manual on AngelCode.com.
For a friendly introduction, read Scripting features overview. Note Below are pages highlighting specific topics:
The Script Side APIs Doxygen page covers both the game (client) and server, each with distinct features. Both are also documented from "both angles", meaning they describe both the API available to scripts and the callback functions invoked by the applications. Finally, also game subsystems implemented as scripts (race system) are included. To help user navigate all these topics the reference is split into categories 'Who2Who', where Who is Server/Game/Script.
Additionally there is Server scripting reference on GitHub Wiki which nicely sums up the API on one page. See also Server example script on GitHub repo.
The source is hosted on GitHub.
To report bugs, go to rigs-of-rods Issue tracker.
Please see rigs-of-rods Wiki for developer setup & building guides.
For introduction to the game development, see codebase overview page.
For technical reference, use the 'Topics' link on the top of this page - it shows the entire codebase separated to categories (loosely matching the source tree).