/TGame/TCommon/Scene/SceneB.cpp
http://awoe.googlecode.com/ · C++ · 158 lines · 115 code · 15 blank · 28 comment · 2 complexity · 79a9155e4d6c0d774b91faec9ac1e961 MD5 · raw file
- #include "stdafx.h"
- #include "SceneB.h"
- #include "SceneLua.h"
- #include "Lua/LuaWrapper.h"
-
-
-
- bool
- SceneB::onLoad()
- {
- SceneLua::push(Lua::instance()->state(), this);
- return Lua::instance()->call("Scene", "onLoad", 1, 0);
- }
-
- //
- // ID
- // This is an instance id generate when scene id add into scene manager
- //
- //
- void
- SceneB::setID(int nID)
- {
- m_nID = nID;
- }
- int
- SceneB::getID()const
- {
- return m_nID;
- }
-
- //
- // Global ID
- // Session ID
- //
- void
- SceneB::setGlobalID(int nID)
- {
- }
- int
- SceneB::getGlobalID()const
- {
- return 0;
- }
-
- void
- SceneB::setStaticID(int val)
- {
- m_nStaticID = val;
- }
- int
- SceneB::getStaticID()const
- {
- return m_nStaticID;
- }
-
- //
- // Static ID
- // ID for static data
- //
- void
- SceneB::setLevel(int v)
- {
- }
- int
- SceneB::getLevel()const
- {
- return 0;
- }
-
- //
- // Scene Global State
- //
- void
- SceneB::setGState(const short& st)
- {
- }
- short
- SceneB::getGState()const
- {
- return 0;
- }
-
-
- //
- // Scene Combat State
- //
- void
- SceneB::setCombatState(const short& st)
- {
- }
- short
- SceneB::getCombatState()const
- {
- return 0;
- }
-
- //
- // Scene Extension Properties
- //
- int
- SceneB::getProps(const short& nIdx)const
- {
- PropsMap::const_iterator it = m_theProps.find(nIdx);
- if (it==m_theProps.end())
- {
- return 0;
- }
- else
- {
- return it->second;
- }
- }
- void
- SceneB::setProps(const short& nIdx, int v)
- {
- m_theProps[nIdx] = v;
- }
-
- //
- // Scene Flags
- //
- void
- SceneB::setFlg(const short& nIdx)
- {
- }
- void
- SceneB::clrFlg(const short& nIdx)
- {
- }
- bool
- SceneB::hasFlg(const short& nIdx)
- {
- return false;
- }
-
-
- //
- // Static Scene Data
- //
- IDataEx*
- SceneB::getStaticSceneData()
- {
- return NULL;
- }
- void
- SceneB::setStaticSceneData(IDataEx* pSED)
- {
- }
-
- void
- SceneB::forEach(IEntityVisitor& v)
- {
- IEntityManager* pEttMgr = getEntityMgr();
- if (pEttMgr)
- {
- pEttMgr->forEach(v);
- }
- }