mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-05-01 15:17:57 +03:00
In EventSetMood, check for Bored/Nervous/Curious/Alert
This commit is contained in:
parent
851fd240d3
commit
df9aead324
1 changed files with 16 additions and 16 deletions
|
@ -5481,21 +5481,9 @@ Make actor dumb.
|
||||||
*/
|
*/
|
||||||
void Actor::Dumb(Event *ev)
|
void Actor::Dumb(Event *ev)
|
||||||
{
|
{
|
||||||
Event e1(EV_Listener_ExecuteScript);
|
Event event(EV_Listener_ExecuteScript);
|
||||||
e1.AddConstString(STRING_GLOBAL_DISABLE_AI_SCR);
|
event.AddConstString(STRING_GLOBAL_DISABLE_AI_SCR);
|
||||||
ExecuteScript(&e1);
|
ExecuteScript(&event);
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
===============
|
|
||||||
Actor::PhysicsOn
|
|
||||||
|
|
||||||
Enable physics.
|
|
||||||
===============
|
|
||||||
*/
|
|
||||||
void Actor::PhysicsOn(Event *ev)
|
|
||||||
{
|
|
||||||
m_bDoPhysics = true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -5510,6 +5498,18 @@ void Actor::PhysicsOff(Event *ev)
|
||||||
m_bDoPhysics = false;
|
m_bDoPhysics = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
===============
|
||||||
|
Actor::PhysicsOn
|
||||||
|
|
||||||
|
Enable physics.
|
||||||
|
===============
|
||||||
|
*/
|
||||||
|
void Actor::PhysicsOn(Event *ev)
|
||||||
|
{
|
||||||
|
m_bDoPhysics = true;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
===============
|
===============
|
||||||
Actor::EventGetMood
|
Actor::EventGetMood
|
||||||
|
@ -5532,7 +5532,7 @@ Set current mood.
|
||||||
void Actor::EventSetMood(Event *ev)
|
void Actor::EventSetMood(Event *ev)
|
||||||
{
|
{
|
||||||
m_csMood = ev->GetConstString(1);
|
m_csMood = ev->GetConstString(1);
|
||||||
if (m_csMood > STRING_ALERT) {
|
if (m_csMood != STRING_BORED && m_csMood != STRING_NERVOUS && m_csMood != STRING_CURIOUS && m_csMood != STRING_ALERT) {
|
||||||
m_csMood = STRING_BORED;
|
m_csMood = STRING_BORED;
|
||||||
ScriptError("invalid mood - setting to bored");
|
ScriptError("invalid mood - setting to bored");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue