⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gamelayoutersinksection.h

📁 游戏框架
💻 H
字号:
// ***************************************************************
//  GameLayouterSinkSection   version:  1.0
//  -------------------------------------------------------------
//	File Name:	GameLayouterSinkSection.h
//	Created:	2007/07/18
//	Modified:	2007/07/18   17:50
//	Author:		William.Liang
//  Msn:		lwq49@msn.com
//  Email:		lwq49@21cn.com, lwq49@msn.com
//	Description:
//
//	Purpose:	
//  -------------------------------------------------------------
//  license:
//
//  The contents of this file are subject to the Mozilla Public
//  License Version 1.1 (the "License"); you may not use this file
//  except in compliance with the License. You may obtain a copy
//  of the License at http://www.mozilla.org/MPL/ Software dis-
//  tributed under the License is distributed on an "AS IS" 
//  basis, WITHOUT WARRANTY OF ANY KIND, either express or im-
//  plied. See the License for the specific language governing
//  rights and limitations under the License.
//
//  The Initial Developer of the Original Code is William.Liang .
//  Copyright (C) 2007 - All Rights Reserved.
// ***************************************************************
#ifndef GAME_LAYOUTER_SECTION_HEAD_FILE
#define GAME_LAYOUTER_SECTION_HEAD_FILE

#pragma once
#include "gameframe.h"
#include "xmlparser.h"

//***************************************************************
//	    环节布局类,负责对XML中的环节相关的结点进行布局处理。
//	包括:设置视图相关属性,设置/创建场景、设置/创建层和加载
//	对象并设置其与层的关联。
//***************************************************************
class GAME_FRAME_CLASS CGameLayouterSinkSection :
	public IGameLayouterSink
{
protected:
	LPFRAMEMANAGERHANDLE				m_lpFMHandles;				//管理句柄集合
	IGameLayouter*						m_pIGameLayouter;			//父指针

protected:
	IGameSection*						m_pCurrentSection;			//当前环节
	CGameView*							m_pCurrentView;				//当前视图
	CGameScene*							m_pCurrentScene;			//当前场景
	CGameLayer*							m_pCurrentLayer;			//当前层
	float								m_fScreenWidth;				//游戏设定屏宽
	float								m_fScreenHeight;			//游戏设定屏高

public:
	//构造函数
	CGameLayouterSinkSection(void);
	//析构函数
	virtual ~CGameLayouterSinkSection(void);

public:
	//回调处理方法
	virtual void __cdecl Processer(_CString szNodeName, _CString szParentName, LPVOID lpParam);
	//设置上级接口
	virtual void __cdecl SetGameLayouter(IGameLayouter*	pIGameLayouter, LPFRAMEMANAGERHANDLE pFMHandles);

	//模板方法
public:
	//是否有效
	virtual bool __cdecl IsValid() { return AfxIsValidAddress(this,sizeof(CGameLayouterSinkSection))?true:false;};
	//释放对象
	virtual bool __cdecl Release() { if(IsValid()) delete this; return true; };
	//接口查询
	virtual void * __cdecl QueryInterface(const IID & Guid, DWORD dwQueryVer);
};

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -