summaryrefslogtreecommitdiff
path: root/src/cat/CommandInterface.h
blob: c77d83c51c1ae0aa9b31a166289f2d2650f580df (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
/*
 * Kitty.h
 *
 *  Created on: Feb 2, 2012
 *      Author: Simon
 */

#ifndef KITTY_H_
#define KITTY_H_

#include <string>
//#include "game/GameModel.h"

class GameModel;
class CommandInterface {
protected:
	std::string lastError;
	GameModel * m;
public:
	enum LogType { LogError, LogWarning, LogNotice };
	enum FormatType { FormatInt, FormatString, FormatChar, FormatFloat };
	CommandInterface(GameModel * m);
	int GetPropertyOffset(std::string key_, FormatType & format);
	int GetParticleType(std::string type);
	void Log(LogType type, std::string message);
	//void AttachGameModel(GameModel * m);
	virtual void Tick() {}
	virtual int Command(std::string command);
	virtual std::string FormatCommand(std::string command);
	std::string GetLastError();
	virtual ~CommandInterface();
};

#endif /* KITTY_H_ */