📄 sceneloading.h
字号:
/*//////////////////////////////////////////////////////
场景读取控制
参照sceneLighting的做法
先通过exec把mis文件生成需要的对象数据
然后遍历datagroup调用preload(client)读取Client数据
其中,要使用simEvent,以便能更新进度提示
进度以datablock数量提示
场景读取开始,需要指定场景读取完毕后的脚本回调
李亦 liease@163.com qq:4040719
2006.6.1
/*//////////////////////////////////////////////////////
#ifndef _SCENELOADING_H_
#define _SCENELOADING_H_
#ifndef _SIMBASE_H_
#include "console\simbase.h"
#endif
#pragma once
class SceneLoading : public SimObject
{
typedef SimObject Parent;
S32 m_nStartTime;
U32 m_uLoadingIndex; //进度位置
U32 m_uLoadingNum; //总数量
public:
SceneLoading(void);
~SceneLoading(void);
public:
bool loadScenes();
void processEvent(U32 loadingIndex);
void completed(bool success);
public:
//场景读取开始,需要指定场景读取完毕后的脚本回调
//参数:
// const char* pScriptCallback 指定场景读取完毕后的脚本回调
//返回
// bool 读取成功失败标志
static bool beginSceneLoading(StringTableEntry pScriptCallback);
static bool isLoading();
static StringTableEntry s_pScriptCallback; // loading完成时脚本回调函数
static bool s_bTerminateLoading; // loading终止标识
static F32 s_fLoadingProgress; // 进度指示
};
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -