2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-08 21:07:42 +00:00

Various imps, completed CCollisionResponse RE

This commit is contained in:
2016-07-24 23:24:57 -07:00
parent 7d33e6ede3
commit 9b62191975
16 changed files with 335 additions and 153 deletions

View File

@@ -1,4 +1,5 @@
#include "CScriptRandomRelay.hpp"
#include "CStateManager.hpp"
namespace urde
{
@@ -10,4 +11,33 @@ CScriptRandomRelay::CScriptRandomRelay(TUniqueId uid, const std::string& name, c
x3c_clamp(clamp)
{
}
void CScriptRandomRelay::AcceptScriptMsg(EScriptObjectMessage msg, TUniqueId objId, CStateManager& stateMgr)
{
CEntity::AcceptScriptMsg(msg, objId, stateMgr);
if (msg == EScriptObjectMessage::SetToZero)
{
if (!x30_24_active)
return;
SendLocalScriptMsgs(EScriptObjectState::Zero, stateMgr);
}
}
void CScriptRandomRelay::SendLocalScriptMsgs(EScriptObjectState state, CStateManager &stateMgr)
{
if (state != EScriptObjectState::Zero)
{
SendScriptMsgs(state, stateMgr, EScriptObjectMessage::None);
return;
}
#if 0
std::vector<std::pair<CEntity*, EScriptObjectMessage>> objs;
objs.reserve(10);
for (SConnection& conn : x20_conns)
{
const std::unique_ptr<CObjectList>& objList = stateMgr.GetObjectList();
}
#endif
}
}