1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-26 09:35:28 +00:00

Fix #7439: world.players and nearby.players returns "0_-1" instead of "1_-1"

This commit is contained in:
Petr Mikheev 2023-06-27 23:56:45 +02:00
parent 462d1c5278
commit 8ca7770d56

View File

@ -246,8 +246,8 @@ namespace MWLua
return;
if (!mPlayer.isEmpty())
throw std::logic_error("Player is initialized twice");
mWorldView.setPlayer(ptr);
mWorldView.objectAddedToScene(ptr);
mWorldView.setPlayer(ptr);
mPlayer = ptr;
LocalScripts* localScripts = ptr.getRefData().getLuaScripts();
if (!localScripts)