mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-14 02:27:40 -04:00
Files for Allowing disabling avatar panic links
(cherry picked from commit 5f3a8644a7
)
This commit is contained in:
@ -1978,3 +1978,12 @@ hsBool cyAvatar::IsCurrentBrainHuman()
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void cyAvatar::SetDontPanicLink(bool value)
|
||||
{
|
||||
if (!fRecvr.empty()) {
|
||||
plArmatureMod* mod = plAvatarMgr::FindAvatar(fRecvr[0]);
|
||||
if (mod)
|
||||
mod->SetDontPanicLinkFlag(value);
|
||||
}
|
||||
}
|
||||
|
@ -566,6 +566,14 @@ public:
|
||||
|
||||
static hsBool IsCurrentBrainHuman();
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Function : SetDontPanicLink
|
||||
// PARAMETERS : value
|
||||
//
|
||||
// PURPOSE : Disables panic linking to Personal Age (warps the avatar back to the start instead)
|
||||
//
|
||||
void SetDontPanicLink(bool value);
|
||||
};
|
||||
|
||||
#endif // cyAvatar_h
|
||||
|
@ -597,6 +597,18 @@ PYTHON_METHOD_DEFINITION(ptAvatar, playSimpleAnimation, args)
|
||||
PYTHON_RETURN_NONE;
|
||||
}
|
||||
|
||||
PYTHON_METHOD_DEFINITION(ptAvatar, setDontPanicLink, args)
|
||||
{
|
||||
bool value;
|
||||
if (!PyArg_ParseTuple(args, "b", &value)) {
|
||||
PyErr_SetString(PyExc_TypeError, "setDontPanicLink expects a boolean");
|
||||
PYTHON_RETURN_ERROR;
|
||||
}
|
||||
|
||||
self->fThis->SetDontPanicLink(value);
|
||||
PYTHON_RETURN_NONE;
|
||||
}
|
||||
|
||||
PYTHON_START_METHODS_TABLE(ptAvatar)
|
||||
PYTHON_METHOD(ptAvatar, netForce, "Params: forceFlag\nSpecify whether this object needs to use messages that are forced to the network\n"
|
||||
"- This is to be used if your Python program is running on only one client\n"
|
||||
@ -651,6 +663,8 @@ PYTHON_START_METHODS_TABLE(ptAvatar)
|
||||
PYTHON_METHOD(ptAvatar, unRegisterForBehaviorNotify, "Params: selfKey\nThis will unregister behavior notifications"),
|
||||
|
||||
PYTHON_METHOD(ptAvatar, playSimpleAnimation, "Params: animName\nPlay simple animation on avatar"),
|
||||
|
||||
PYTHON_METHOD(ptAvatar, setDontPanicLink, "Params: value\nDisables panic linking to Personal Age (warps the avatar back to the start instead)"),
|
||||
PYTHON_END_METHODS_TABLE;
|
||||
|
||||
PYTHON_GLOBAL_METHOD_DEFINITION(PtSetBehaviorLoopCount, args, "Params: behaviorKey,stage,loopCount,netForce\nThis will set the loop count for a particular stage in a multistage behavior")
|
||||
|
Reference in New Issue
Block a user