PageRenderTime 18ms CodeModel.GetById 8ms app.highlight 4ms RepoModel.GetById 2ms app.codeStats 0ms

/TGame/TServerMS/Scene/SceneManagerSvr.h

http://awoe.googlecode.com/
C++ Header | 37 lines | 16 code | 7 blank | 14 comment | 0 complexity | fa58f6c5a357173f2345953e95bd166b MD5 | raw file
 1#ifndef	___SCENE_MANAGER_SVR____
 2#define ___SCENE_MANAGER_SVR____
 3
 4#include "Scene/SceneManager.h"
 5
 6//
 7//	dynamic data interface used for creating a new scene	
 8//
 9class SceneManagerSvr : public SceneManager
10{
11public:
12	SceneManagerSvr();
13	virtual	~SceneManagerSvr();
14
15	//
16	//	add a scene by static id and table 
17	//	scene will be fully initialized in it loading method
18	//
19	virtual IScene* addScene(int nStaticID, short type);
20
21	//
22	//	remove a scene by its instance id
23	//
24	virtual bool	rmvScene(int nInstanceID);
25protected:
26	virtual IScene* createScene(int nStaticID, short type);
27
28	//
29	//	static id to instance id for city only
30	//	note that each city will only have one instance
31	//
32	typedef		stdext::hash_map<int, int>	StaticToInstance;
33	StaticToInstance	m_stoi;
34};
35
36
37#endif