forked from teamnwah/openmw-tes3coop
[Server] Add GetBaseEventAction script function
This commit is contained in:
parent
e0bc557aa4
commit
8a5bc77699
2 changed files with 7 additions and 0 deletions
|
@ -131,6 +131,11 @@ unsigned int WorldFunctions::GetObjectChangesSize() noexcept
|
|||
return mwmp::Networking::getPtr()->getLastEvent()->objectChanges.count;
|
||||
}
|
||||
|
||||
unsigned int WorldFunctions::GetBaseEventAction() noexcept
|
||||
{
|
||||
return mwmp::Networking::getPtr()->getLastEvent()->action;
|
||||
}
|
||||
|
||||
const char *WorldFunctions::GetObjectRefId(unsigned int i) noexcept
|
||||
{
|
||||
return mwmp::Networking::getPtr()->getLastEvent()->objectChanges.objects.at(i).refId.c_str();
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
{"SetObjectRotation", WorldFunctions::SetObjectRotation},\
|
||||
\
|
||||
{"GetObjectChangesSize", WorldFunctions::GetObjectChangesSize},\
|
||||
{"GetBaseEventAction", WorldFunctions::GetBaseEventAction},\
|
||||
\
|
||||
{"GetObjectRefId", WorldFunctions::GetObjectRefId},\
|
||||
{"GetObjectRefNumIndex", WorldFunctions::GetObjectRefNumIndex},\
|
||||
|
@ -71,6 +72,7 @@ public:
|
|||
static void SetObjectRotation(double x, double y, double z) noexcept;
|
||||
|
||||
static unsigned int GetObjectChangesSize() noexcept;
|
||||
static unsigned int GetBaseEventAction() noexcept;
|
||||
|
||||
static const char *GetObjectRefId(unsigned int i) noexcept;
|
||||
static int GetObjectRefNumIndex(unsigned int i) noexcept;
|
||||
|
|
Loading…
Reference in a new issue