We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 06d3263 commit 5e5cf47Copy full SHA for 5e5cf47
src/xrGame/doors_door.cpp
@@ -157,7 +157,7 @@ void door::change_state(actor* initiator)
157
if (m_state == m_target_state)
158
return;
159
160
- m_object.callback(GameObject::eUseObject)(m_object.lua_game_object(), (CScriptGameObject*)initiator->lua_game_object());
+ m_object.callback(GameObject::eUseObject)(m_object.lua_game_object(), initiator ? static_cast<CScriptGameObject*>(initiator->lua_game_object()) : nullptr);
161
#ifdef DEBUG
162
if (g_debug_doors)
163
Msg("door[%s] started to change its state to [%s]", m_object.cName().c_str(),
0 commit comments