mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-14 10:37:41 -04:00
Track NPC clones
Manual state management in python was kind of fiddly, so let's track all avatar clones in the NetApp and unload them as needed. This also seems to fix a potential bug in plNPCSpawnMod (is that even used?).
This commit is contained in:
@ -2700,7 +2700,7 @@ PyObject* cyMisc::LoadAvatarModel(const char* modelName, pyKey& spawnPoint, cons
|
||||
|
||||
void cyMisc::UnLoadAvatarModel(pyKey& avatar)
|
||||
{
|
||||
plAvatarMgr::GetInstance()->UnLoadAvatar(avatar.getKey(), false);
|
||||
plAvatarMgr::GetInstance()->UnLoadAvatar(avatar.getKey(), false, true);
|
||||
}
|
||||
|
||||
void cyMisc::ForceCursorHidden()
|
||||
|
@ -374,7 +374,8 @@ PYTHON_GLOBAL_METHOD_DEFINITION(PtLoadAvatarModel, args, "Params: modelName, spa
|
||||
return cyMisc::LoadAvatarModel(modelName, *key, userStr.c_str());
|
||||
}
|
||||
|
||||
PYTHON_GLOBAL_METHOD_DEFINITION(PtUnLoadAvatarModel, args, "Params: avatarKey\nUnloads the specified avatar model")
|
||||
PYTHON_GLOBAL_METHOD_DEFINITION(PtUnLoadAvatarModel, args, "Params: avatarKey\nForcibly unloads the specified avatar model.\n"
|
||||
"Do not use this method unless you require fine-grained control of avatar unloading.")
|
||||
{
|
||||
PyObject* keyObj = NULL;
|
||||
if (!PyArg_ParseTuple(args, "O", &keyObj))
|
||||
|
Reference in New Issue
Block a user