Skip to content

Commit

Permalink
Merge pull request daid#1078 from czenker/feature-eeversion
Browse files Browse the repository at this point in the history
expose EE version in lua
  • Loading branch information
daid authored and olivier-vm committed Aug 30, 2021
1 parent 6d2f489 commit f326695
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/gameGlobalInfo.cpp
Expand Up @@ -439,3 +439,11 @@ static int allowNewPlayerShips(lua_State* L)
/// Set if the server is allowed to create new player ships from the ship creation screen.
/// allowNewPlayerShip(false) -- disallow new player ships to be created
REGISTER_SCRIPT_FUNCTION(allowNewPlayerShips);

static int getEEVersion(lua_State* L)
{
lua_pushinteger(L, VERSION_NUMBER);
return 1;
}
/// Get a string with the current version number, like "20191231"
REGISTER_SCRIPT_FUNCTION(getEEVersion);

0 comments on commit f326695

Please sign in to comment.