Merge lp:~widelands-dev/widelands/bug-1814372-lua-gametype into lp:widelands
Proposed by
Notabilis
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 8963 | ||||
Proposed branch: | lp:~widelands-dev/widelands/bug-1814372-lua-gametype | ||||
Merge into: | lp:widelands | ||||
Diff against target: |
59 lines (+30/-1) 2 files modified
src/scripting/lua_root.cc (+29/-1) src/scripting/lua_root.h (+1/-0) |
||||
To merge this branch: | bzr merge lp:~widelands-dev/widelands/bug-1814372-lua-gametype | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Klaus Halfmann | review, compile | Approve | |
Review via email:
|
Commit message
Adding lua method to get the type of the current game, i.e., single or multiplayer.
Description of the change
This allows scripts to differentiate between single- and multiplayer games, allowing to adapt to restrictions of multiplayer games.
The idea for this came up while debugging desyncs, since the lua sleep() command can lead to desyncs in multiplayer if not used properly (i.e., for all players at the same time).
To post a comment you must log in.
Mhh, I do not see any code changes and cannot pull the branch, whats the Problem?