view LightClone/Source/Mediator.h @ 65:41980ff0607d

Added shader and textures for bot
author koryspansel <koryspansel@bendbroadband.com>
date Wed, 05 Oct 2011 12:55:46 -0700
parents 44dcff5abf12
children ffaeccdc105e
line wrap: on
line source

/*
 * Mediator
 */

#ifndef __MEDIATOR_H__
#define __MEDIATOR_H__

#include "Core.h"
#include "Clock.h"
#include "Window.h"
#include "InputManager.h"
#include "GraphicsDevice.h"
#include "ResourceManager.h"
#include "RenderContext.h"
#include "World.h"
#include "ServiceProvider.h"

/*
 * Mediator
 */
class Mediator : public WindowCallback
{
	/*
	 * kWindow
	 */
	Window kWindow;

	/*
	 * kClock
	 */
	Clock kClock;

	/*
	 * pGraphicsDevice
	 */
	GraphicsDevice* pGraphicsDevice;

	/*
	 * kResourceManager
	 */
	ResourceManager kResourceManager;

	/*
	 * kContext
	 */
	RenderContext kContext;

	/*
	 * kInputManager
	 */
	InputManager kInputManager;

	/*
	 * kServiceProvider
	 */
	ServiceProvider kServiceProvider;

	/*
	 * kWorld
	 */
	World kWorld;

public:

	/*
	 * Mediator
	 */
	Mediator();

	/*
	 * Run
	 */
	ErrorCode Run();

	/*
	 * OnMessage
	 */
	virtual int32 OnMessage(Window* pInstance, uint32 nMessage, WPARAM wParam, LPARAM lParam);

private:

	/*
	 * Initialize
	 */
	virtual ErrorCode Initialize();

	/*
	 * Terminate
	 */
	virtual void Terminate();

	/*
	 * Update
	 */
	void Update(float fElapsed);

	/*
	 * Render
	 */
	void Render();

	/*
	 * ProcessMessages
	 */
	virtual void ProcessMessages();
};

#endif //__MEDIATOR_H__