History

Unload all scripts on entity server loss

Atlante45 committed 9 years ago

Commit 6b0b19d1 parent cbc69fb1 file · +4 −1Browse files

Showing the changes to assignment-client/src/scripts/EntityScriptServer.cpp (1 of 1 file). Show all

Unified · Split

assignment-client/src/scripts/EntityScriptServer.cpp+4−1
@@ -253,7 +253,10 @@ void EntityScriptServer::checkAndCallPreload(const EntityItemID& entityID, const · 252 unmodified lines
253}253}
254 254
255void EntityScriptServer::nodeKilled(SharedNodePointer killedNode) {255void EntityScriptServer::nodeKilled(SharedNodePointer killedNode) {
256 256 if (killedNode->getType() == NodeType::EntityServer) {
257 _entitiesScriptEngine->unloadAllEntityScripts();
258 resetEntitiesScriptEngine();
259 }
257}260}
258 261
259void EntityScriptServer::sendStatsPacket() {262void EntityScriptServer::sendStatsPacket() {