Skip to content
Permalink
Browse files

Add clientside lua function resetBlurLevel (#1266)

* Add Clientside lua function `resetBlurLevel`

* Add `resetPlayerBlurLevel` which is an alias to `resetBlurLevvel`

* Revert "Add `resetPlayerBlurLevel` which is an alias to `resetBlurLevvel`"

This reverts commit 7676322.

* Move `getBlurLevel` back in place and remove cast

* Addendum to previous commit
  • Loading branch information
xLuxy committed Mar 16, 2020
1 parent 6757645 commit f3d80a78a5b1adb5253e5c9cde0c1b2a5a175ab9
@@ -549,6 +549,13 @@ int CLuaFunctionDefs::SetBlurLevel(lua_State* luaVM)
return 1;
}

int CLuaFunctionDefs::ResetBlurLevel(lua_State* luaVM)
{
g_pGame->SetBlurLevel(36);
lua_pushboolean(luaVM, true);
return 1;
}

int CLuaFunctionDefs::SetTime(lua_State* luaVM)
{
// bool setTime ( int hour, int minute )
@@ -124,6 +124,7 @@ class CLuaFunctionDefs
LUA_DECLARE(SetGarageOpen);
LUA_DECLARE(SetWorldSpecialPropertyEnabled);
LUA_DECLARE(SetBlurLevel);
LUA_DECLARE(ResetBlurLevel);
LUA_DECLARE(SetJetpackMaxHeight);
LUA_DECLARE(SetCloudsEnabled);
LUA_DECLARE(GetCloudsEnabled);
@@ -316,6 +316,7 @@ void CLuaManager::LoadCFunctions()
{"setGarageOpen", CLuaFunctionDefs::SetGarageOpen},
{"setWorldSpecialPropertyEnabled", CLuaFunctionDefs::SetWorldSpecialPropertyEnabled},
{"setBlurLevel", CLuaFunctionDefs::SetBlurLevel},
{"resetBlurLevel", CLuaFunctionDefs::ResetBlurLevel},
{"setJetpackMaxHeight", CLuaFunctionDefs::SetJetpackMaxHeight},
{"setCloudsEnabled", CLuaFunctionDefs::SetCloudsEnabled},
{"setTrafficLightState", CLuaFunctionDefs::SetTrafficLightState},

0 comments on commit f3d80a7

Please sign in to comment.
You can’t perform that action at this time.