Apply clang-modernize -add-override
parent
2dbacc28b5
commit
ba3284b8b8
398
src/CBot/CBot.h
398
src/CBot/CBot.h
|
@ -483,8 +483,8 @@ public:
|
||||||
~CBotWhile();
|
~CBotWhile();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotDo : public CBotInstr
|
class CBotDo : public CBotInstr
|
||||||
|
@ -499,8 +499,8 @@ public:
|
||||||
~CBotDo();
|
~CBotDo();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotFor : public CBotInstr
|
class CBotFor : public CBotInstr
|
||||||
|
@ -517,8 +517,8 @@ public:
|
||||||
~CBotFor();
|
~CBotFor();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotBreak : public CBotInstr
|
class CBotBreak : public CBotInstr
|
||||||
|
@ -531,8 +531,8 @@ public:
|
||||||
~CBotBreak();
|
~CBotBreak();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotReturn : public CBotInstr
|
class CBotReturn : public CBotInstr
|
||||||
|
@ -545,8 +545,8 @@ public:
|
||||||
~CBotReturn();
|
~CBotReturn();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -561,8 +561,8 @@ public:
|
||||||
~CBotSwitch();
|
~CBotSwitch();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -576,9 +576,9 @@ public:
|
||||||
~CBotCase();
|
~CBotCase();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
bool CompCase(CBotStack* &pj, int val);
|
bool CompCase(CBotStack* &pj, int val) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotCatch : public CBotInstr
|
class CBotCatch : public CBotInstr
|
||||||
|
@ -595,8 +595,8 @@ public:
|
||||||
static
|
static
|
||||||
CBotCatch* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotCatch* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool TestCatch(CBotStack* &pj, int val);
|
bool TestCatch(CBotStack* &pj, int val);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
void RestoreCondState(CBotStack* &pj, bool bMain);
|
void RestoreCondState(CBotStack* &pj, bool bMain);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -612,8 +612,8 @@ public:
|
||||||
~CBotTry();
|
~CBotTry();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotThrow : public CBotInstr
|
class CBotThrow : public CBotInstr
|
||||||
|
@ -626,8 +626,8 @@ public:
|
||||||
~CBotThrow();
|
~CBotThrow();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -640,7 +640,7 @@ public:
|
||||||
~CBotStartDebugDD();
|
~CBotStartDebugDD();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -656,8 +656,8 @@ public:
|
||||||
~CBotIf();
|
~CBotIf();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -675,8 +675,8 @@ public:
|
||||||
~CBotInt();
|
~CBotInt();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip = false);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip = false);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// definition of an array
|
// definition of an array
|
||||||
|
@ -695,8 +695,8 @@ public:
|
||||||
~CBotInstArray();
|
~CBotInstArray();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotTypResult type);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotTypResult type);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -713,15 +713,15 @@ public:
|
||||||
~CBotListArray();
|
~CBotListArray();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotTypResult type);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotTypResult type);
|
||||||
bool Execute(CBotStack* &pj, CBotVar* pVar);
|
bool Execute(CBotStack* &pj, CBotVar* pVar) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class CBotEmpty : public CBotInstr
|
class CBotEmpty : public CBotInstr
|
||||||
{
|
{
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// defininition of a boolean
|
// defininition of a boolean
|
||||||
|
@ -737,8 +737,8 @@ public:
|
||||||
~CBotBoolean();
|
~CBotBoolean();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip=false);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip=false);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -755,8 +755,8 @@ public:
|
||||||
~CBotFloat();
|
~CBotFloat();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip=false);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip=false);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// definition of an element string
|
// definition of an element string
|
||||||
|
@ -772,8 +772,8 @@ public:
|
||||||
~CBotIString();
|
~CBotIString();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip=false);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool cont = false, bool noskip=false);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// definition of an element of any class
|
// definition of an element of any class
|
||||||
|
@ -793,8 +793,8 @@ public:
|
||||||
~CBotClassInst();
|
~CBotClassInst();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotClass* pClass = nullptr);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotClass* pClass = nullptr);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotCondition : public CBotInstr
|
class CBotCondition : public CBotInstr
|
||||||
|
@ -823,9 +823,9 @@ public:
|
||||||
CBotLeftExpr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotLeftExpr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pStack, CBotStack* array);
|
bool Execute(CBotStack* &pStack, CBotStack* array);
|
||||||
|
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotCStack* &pile);
|
bool ExecuteVar(CBotVar* &pVar, CBotCStack* &pile) override;
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep);
|
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep);
|
||||||
void RestoreStateVar(CBotStack* &pile, bool bMain);
|
void RestoreStateVar(CBotStack* &pile, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -843,9 +843,9 @@ public:
|
||||||
void SetUniqNum(int num);
|
void SetUniqNum(int num);
|
||||||
// static
|
// static
|
||||||
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotCStack* &pile);
|
bool ExecuteVar(CBotVar* &pVar, CBotCStack* &pile) override;
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep, bool bExtend);
|
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep, bool bExtend) override;
|
||||||
void RestoreStateVar(CBotStack* &pj, bool bMain);
|
void RestoreStateVar(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// management of indices of the tables
|
// management of indices of the tables
|
||||||
|
@ -862,9 +862,9 @@ public:
|
||||||
~CBotIndexExpr();
|
~CBotIndexExpr();
|
||||||
// static
|
// static
|
||||||
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotCStack* &pile);
|
bool ExecuteVar(CBotVar* &pVar, CBotCStack* &pile) override;
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep, bool bExtend);
|
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep, bool bExtend) override;
|
||||||
void RestoreStateVar(CBotStack* &pj, bool bMain);
|
void RestoreStateVar(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// expressions like
|
// expressions like
|
||||||
|
@ -882,8 +882,8 @@ public:
|
||||||
~CBotExpression();
|
~CBotExpression();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pStack);
|
bool Execute(CBotStack* &pStack) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotListExpression : public CBotInstr
|
class CBotListExpression : public CBotInstr
|
||||||
|
@ -896,8 +896,8 @@ public:
|
||||||
~CBotListExpression();
|
~CBotListExpression();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pStack);
|
bool Execute(CBotStack* &pStack) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotLogicExpr : public CBotInstr
|
class CBotLogicExpr : public CBotInstr
|
||||||
|
@ -913,8 +913,8 @@ public:
|
||||||
~CBotLogicExpr();
|
~CBotLogicExpr();
|
||||||
// static
|
// static
|
||||||
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pStack);
|
bool Execute(CBotStack* &pStack) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -952,8 +952,8 @@ public:
|
||||||
~CBotExprUnaire();
|
~CBotExprUnaire();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pStack);
|
bool Execute(CBotStack* &pStack) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// all operations with two operands
|
// all operations with two operands
|
||||||
|
@ -968,8 +968,8 @@ public:
|
||||||
~CBotTwoOpExpr();
|
~CBotTwoOpExpr();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, int* pOperations = nullptr);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, int* pOperations = nullptr);
|
||||||
bool Execute(CBotStack* &pStack);
|
bool Execute(CBotStack* &pStack) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1000,8 +1000,8 @@ public:
|
||||||
~CBotListInstr();
|
~CBotListInstr();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool bLocal = true);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, bool bLocal = true);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1020,8 +1020,8 @@ public:
|
||||||
~CBotInstrCall();
|
~CBotInstrCall();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// a call of method
|
// a call of method
|
||||||
|
@ -1045,9 +1045,9 @@ public:
|
||||||
~CBotInstrMethode();
|
~CBotInstrMethode();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotVar* pVar);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack, CBotVar* pVar);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pj, CBotToken* prevToken, bool bStep, bool bExtend);
|
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pj, CBotToken* prevToken, bool bStep, bool bExtend) override;
|
||||||
void RestoreStateVar(CBotStack* &pj, bool bMain);
|
void RestoreStateVar(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// expression for the variable name
|
// expression for the variable name
|
||||||
|
@ -1067,11 +1067,11 @@ public:
|
||||||
static
|
static
|
||||||
CBotInstr* CompileMethode(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* CompileMethode(CBotToken* &p, CBotCStack* pStack);
|
||||||
|
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep);
|
bool ExecuteVar(CBotVar* &pVar, CBotStack* &pile, CBotToken* prevToken, bool bStep);
|
||||||
bool Execute2Var(CBotVar* &pVar, CBotStack* &pj, CBotToken* prevToken, bool bStep);
|
bool Execute2Var(CBotVar* &pVar, CBotStack* &pj, CBotToken* prevToken, bool bStep);
|
||||||
void RestoreStateVar(CBotStack* &pj, bool bMain);
|
void RestoreStateVar(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotPostIncExpr : public CBotInstr
|
class CBotPostIncExpr : public CBotInstr
|
||||||
|
@ -1085,8 +1085,8 @@ public:
|
||||||
~CBotPostIncExpr();
|
~CBotPostIncExpr();
|
||||||
// static
|
// static
|
||||||
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotPreIncExpr : public CBotInstr
|
class CBotPreIncExpr : public CBotInstr
|
||||||
|
@ -1100,8 +1100,8 @@ public:
|
||||||
~CBotPreIncExpr();
|
~CBotPreIncExpr();
|
||||||
// static
|
// static
|
||||||
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
// CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1118,8 +1118,8 @@ public:
|
||||||
~CBotLeftExprVar();
|
~CBotLeftExprVar();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1133,8 +1133,8 @@ public:
|
||||||
|
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1146,8 +1146,8 @@ public:
|
||||||
CBotExprNull();
|
CBotExprNull();
|
||||||
~CBotExprNull();
|
~CBotExprNull();
|
||||||
|
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotExprNan : public CBotInstr
|
class CBotExprNan : public CBotInstr
|
||||||
|
@ -1158,8 +1158,8 @@ public:
|
||||||
CBotExprNan();
|
CBotExprNan();
|
||||||
~CBotExprNan();
|
~CBotExprNan();
|
||||||
|
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBotNew : public CBotInstr
|
class CBotNew : public CBotInstr
|
||||||
|
@ -1176,8 +1176,8 @@ public:
|
||||||
|
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// expression representing a number
|
// expression representing a number
|
||||||
|
@ -1194,8 +1194,8 @@ public:
|
||||||
~CBotExprNum();
|
~CBotExprNum();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1211,8 +1211,8 @@ public:
|
||||||
~CBotExprAlpha();
|
~CBotExprAlpha();
|
||||||
static
|
static
|
||||||
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
CBotInstr* Compile(CBotToken* &p, CBotCStack* pStack);
|
||||||
bool Execute(CBotStack* &pj);
|
bool Execute(CBotStack* &pj) override;
|
||||||
void RestoreState(CBotStack* &pj, bool bMain);
|
void RestoreState(CBotStack* &pj, bool bMain) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1231,44 +1231,44 @@ public:
|
||||||
CBotVarInt( const CBotToken* name );
|
CBotVarInt( const CBotToken* name );
|
||||||
// ~CBotVarInt();
|
// ~CBotVarInt();
|
||||||
|
|
||||||
void SetValInt(int val, const char* s = nullptr);
|
void SetValInt(int val, const char* s = nullptr) override;
|
||||||
void SetValFloat(float val);
|
void SetValFloat(float val) override;
|
||||||
int GetValInt();
|
int GetValInt() override;
|
||||||
float GetValFloat();
|
float GetValFloat() override;
|
||||||
CBotString GetValString();
|
CBotString GetValString() override;
|
||||||
|
|
||||||
void Copy(CBotVar* pSrc, bool bName=true);
|
void Copy(CBotVar* pSrc, bool bName=true) override;
|
||||||
|
|
||||||
|
|
||||||
void Add(CBotVar* left, CBotVar* right); // addition
|
void Add(CBotVar* left, CBotVar* right) override; // addition
|
||||||
void Sub(CBotVar* left, CBotVar* right); // substraction
|
void Sub(CBotVar* left, CBotVar* right) override; // substraction
|
||||||
void Mul(CBotVar* left, CBotVar* right); // multiplication
|
void Mul(CBotVar* left, CBotVar* right) override; // multiplication
|
||||||
int Div(CBotVar* left, CBotVar* right); // division
|
int Div(CBotVar* left, CBotVar* right) override; // division
|
||||||
int Modulo(CBotVar* left, CBotVar* right); // remainder of division
|
int Modulo(CBotVar* left, CBotVar* right) override; // remainder of division
|
||||||
void Power(CBotVar* left, CBotVar* right); // power
|
void Power(CBotVar* left, CBotVar* right) override; // power
|
||||||
|
|
||||||
bool Lo(CBotVar* left, CBotVar* right);
|
bool Lo(CBotVar* left, CBotVar* right) override;
|
||||||
bool Hi(CBotVar* left, CBotVar* right);
|
bool Hi(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ls(CBotVar* left, CBotVar* right);
|
bool Ls(CBotVar* left, CBotVar* right) override;
|
||||||
bool Hs(CBotVar* left, CBotVar* right);
|
bool Hs(CBotVar* left, CBotVar* right) override;
|
||||||
bool Eq(CBotVar* left, CBotVar* right);
|
bool Eq(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ne(CBotVar* left, CBotVar* right);
|
bool Ne(CBotVar* left, CBotVar* right) override;
|
||||||
|
|
||||||
void XOr(CBotVar* left, CBotVar* right);
|
void XOr(CBotVar* left, CBotVar* right) override;
|
||||||
void Or(CBotVar* left, CBotVar* right);
|
void Or(CBotVar* left, CBotVar* right) override;
|
||||||
void And(CBotVar* left, CBotVar* right);
|
void And(CBotVar* left, CBotVar* right) override;
|
||||||
|
|
||||||
void SL(CBotVar* left, CBotVar* right);
|
void SL(CBotVar* left, CBotVar* right) override;
|
||||||
void SR(CBotVar* left, CBotVar* right);
|
void SR(CBotVar* left, CBotVar* right) override;
|
||||||
void ASR(CBotVar* left, CBotVar* right);
|
void ASR(CBotVar* left, CBotVar* right) override;
|
||||||
|
|
||||||
void Neg();
|
void Neg() override;
|
||||||
void Not();
|
void Not() override;
|
||||||
void Inc();
|
void Inc() override;
|
||||||
void Dec();
|
void Dec() override;
|
||||||
|
|
||||||
bool Save0State(FILE* pf);
|
bool Save0State(FILE* pf) override;
|
||||||
bool Save1State(FILE* pf);
|
bool Save1State(FILE* pf) override;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1282,34 +1282,34 @@ public:
|
||||||
CBotVarFloat( const CBotToken* name );
|
CBotVarFloat( const CBotToken* name );
|
||||||
// ~CBotVarFloat();
|
// ~CBotVarFloat();
|
||||||
|
|
||||||
void SetValInt(int val, const char* s = nullptr);
|
void SetValInt(int val, const char* s = nullptr) override;
|
||||||
void SetValFloat(float val);
|
void SetValFloat(float val) override;
|
||||||
int GetValInt();
|
int GetValInt() override;
|
||||||
float GetValFloat();
|
float GetValFloat() override;
|
||||||
CBotString GetValString();
|
CBotString GetValString() override;
|
||||||
|
|
||||||
void Copy(CBotVar* pSrc, bool bName=true);
|
void Copy(CBotVar* pSrc, bool bName=true) override;
|
||||||
|
|
||||||
|
|
||||||
void Add(CBotVar* left, CBotVar* right); // addition
|
void Add(CBotVar* left, CBotVar* right) override; // addition
|
||||||
void Sub(CBotVar* left, CBotVar* right); // substraction
|
void Sub(CBotVar* left, CBotVar* right) override; // substraction
|
||||||
void Mul(CBotVar* left, CBotVar* right); // multiplication
|
void Mul(CBotVar* left, CBotVar* right) override; // multiplication
|
||||||
int Div(CBotVar* left, CBotVar* right); // division
|
int Div(CBotVar* left, CBotVar* right) override; // division
|
||||||
int Modulo(CBotVar* left, CBotVar* right); // remainder of division
|
int Modulo(CBotVar* left, CBotVar* right) override; // remainder of division
|
||||||
void Power(CBotVar* left, CBotVar* right); // power
|
void Power(CBotVar* left, CBotVar* right) override; // power
|
||||||
|
|
||||||
bool Lo(CBotVar* left, CBotVar* right);
|
bool Lo(CBotVar* left, CBotVar* right) override;
|
||||||
bool Hi(CBotVar* left, CBotVar* right);
|
bool Hi(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ls(CBotVar* left, CBotVar* right);
|
bool Ls(CBotVar* left, CBotVar* right) override;
|
||||||
bool Hs(CBotVar* left, CBotVar* right);
|
bool Hs(CBotVar* left, CBotVar* right) override;
|
||||||
bool Eq(CBotVar* left, CBotVar* right);
|
bool Eq(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ne(CBotVar* left, CBotVar* right);
|
bool Ne(CBotVar* left, CBotVar* right) override;
|
||||||
|
|
||||||
void Neg();
|
void Neg() override;
|
||||||
void Inc();
|
void Inc() override;
|
||||||
void Dec();
|
void Dec() override;
|
||||||
|
|
||||||
bool Save1State(FILE* pf);
|
bool Save1State(FILE* pf) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1323,21 +1323,21 @@ public:
|
||||||
CBotVarString( const CBotToken* name );
|
CBotVarString( const CBotToken* name );
|
||||||
// ~CBotVarString();
|
// ~CBotVarString();
|
||||||
|
|
||||||
void SetValString(const char* p);
|
void SetValString(const char* p) override;
|
||||||
CBotString GetValString();
|
CBotString GetValString() override;
|
||||||
|
|
||||||
void Copy(CBotVar* pSrc, bool bName=true);
|
void Copy(CBotVar* pSrc, bool bName=true) override;
|
||||||
|
|
||||||
void Add(CBotVar* left, CBotVar* right); // addition
|
void Add(CBotVar* left, CBotVar* right) override; // addition
|
||||||
|
|
||||||
bool Lo(CBotVar* left, CBotVar* right);
|
bool Lo(CBotVar* left, CBotVar* right) override;
|
||||||
bool Hi(CBotVar* left, CBotVar* right);
|
bool Hi(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ls(CBotVar* left, CBotVar* right);
|
bool Ls(CBotVar* left, CBotVar* right) override;
|
||||||
bool Hs(CBotVar* left, CBotVar* right);
|
bool Hs(CBotVar* left, CBotVar* right) override;
|
||||||
bool Eq(CBotVar* left, CBotVar* right);
|
bool Eq(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ne(CBotVar* left, CBotVar* right);
|
bool Ne(CBotVar* left, CBotVar* right) override;
|
||||||
|
|
||||||
bool Save1State(FILE* pf);
|
bool Save1State(FILE* pf) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// class for the management of boolean
|
// class for the management of boolean
|
||||||
|
@ -1350,22 +1350,22 @@ public:
|
||||||
CBotVarBoolean( const CBotToken* name );
|
CBotVarBoolean( const CBotToken* name );
|
||||||
// ~CBotVarBoolean();
|
// ~CBotVarBoolean();
|
||||||
|
|
||||||
void SetValInt(int val, const char* s = nullptr);
|
void SetValInt(int val, const char* s = nullptr) override;
|
||||||
void SetValFloat(float val);
|
void SetValFloat(float val) override;
|
||||||
int GetValInt();
|
int GetValInt() override;
|
||||||
float GetValFloat();
|
float GetValFloat() override;
|
||||||
CBotString GetValString();
|
CBotString GetValString() override;
|
||||||
|
|
||||||
void Copy(CBotVar* pSrc, bool bName=true);
|
void Copy(CBotVar* pSrc, bool bName=true) override;
|
||||||
|
|
||||||
void And(CBotVar* left, CBotVar* right);
|
void And(CBotVar* left, CBotVar* right) override;
|
||||||
void Or(CBotVar* left, CBotVar* right);
|
void Or(CBotVar* left, CBotVar* right) override;
|
||||||
void XOr(CBotVar* left, CBotVar* right);
|
void XOr(CBotVar* left, CBotVar* right) override;
|
||||||
void Not();
|
void Not() override;
|
||||||
bool Eq(CBotVar* left, CBotVar* right);
|
bool Eq(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ne(CBotVar* left, CBotVar* right);
|
bool Ne(CBotVar* left, CBotVar* right) override;
|
||||||
|
|
||||||
bool Save1State(FILE* pf);
|
bool Save1State(FILE* pf) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1394,38 +1394,38 @@ public:
|
||||||
~CBotVarClass();
|
~CBotVarClass();
|
||||||
// void InitCBotVarClass( const CBotToken* name, CBotTypResult& type, int &nIdent );
|
// void InitCBotVarClass( const CBotToken* name, CBotTypResult& type, int &nIdent );
|
||||||
|
|
||||||
void Copy(CBotVar* pSrc, bool bName=true);
|
void Copy(CBotVar* pSrc, bool bName=true) override;
|
||||||
void SetClass(CBotClass* pClass); //, int &nIdent);
|
void SetClass(CBotClass* pClass) override; //, int &nIdent);
|
||||||
CBotClass* GetClass();
|
CBotClass* GetClass() override;
|
||||||
CBotVar* GetItem(const char* name); // return an element of a class according to its name (*)
|
CBotVar* GetItem(const char* name) override; // return an element of a class according to its name (*)
|
||||||
CBotVar* GetItemRef(int nIdent);
|
CBotVar* GetItemRef(int nIdent) override;
|
||||||
|
|
||||||
CBotVar* GetItem(int n, bool bExtend);
|
CBotVar* GetItem(int n, bool bExtend) override;
|
||||||
CBotVar* GetItemList();
|
CBotVar* GetItemList() override;
|
||||||
|
|
||||||
CBotString GetValString();
|
CBotString GetValString() override;
|
||||||
|
|
||||||
bool Save1State(FILE* pf);
|
bool Save1State(FILE* pf) override;
|
||||||
void Maj(void* pUser, bool bContinue);
|
void Maj(void* pUser, bool bContinue) override;
|
||||||
|
|
||||||
void IncrementUse(); // a reference to incrementation
|
void IncrementUse(); // a reference to incrementation
|
||||||
void DecrementUse(); // a reference to decrementation
|
void DecrementUse(); // a reference to decrementation
|
||||||
|
|
||||||
CBotVarClass*
|
CBotVarClass*
|
||||||
GetPointer();
|
GetPointer() override;
|
||||||
void SetItemList(CBotVar* pVar);
|
void SetItemList(CBotVar* pVar);
|
||||||
|
|
||||||
void SetIdent(long n);
|
void SetIdent(long n) override;
|
||||||
|
|
||||||
static CBotVarClass* Find(long id);
|
static CBotVarClass* Find(long id);
|
||||||
|
|
||||||
|
|
||||||
// CBotVar* GetMyThis();
|
// CBotVar* GetMyThis();
|
||||||
|
|
||||||
bool Eq(CBotVar* left, CBotVar* right);
|
bool Eq(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ne(CBotVar* left, CBotVar* right);
|
bool Ne(CBotVar* left, CBotVar* right) override;
|
||||||
|
|
||||||
void ConstructorSet();
|
void ConstructorSet() override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1442,27 +1442,27 @@ public:
|
||||||
CBotVarPointer( const CBotToken* name, CBotTypResult& type );
|
CBotVarPointer( const CBotToken* name, CBotTypResult& type );
|
||||||
~CBotVarPointer();
|
~CBotVarPointer();
|
||||||
|
|
||||||
void Copy(CBotVar* pSrc, bool bName=true);
|
void Copy(CBotVar* pSrc, bool bName=true) override;
|
||||||
void SetClass(CBotClass* pClass);
|
void SetClass(CBotClass* pClass) override;
|
||||||
CBotClass* GetClass();
|
CBotClass* GetClass() override;
|
||||||
CBotVar* GetItem(const char* name); // return an element of a class according to its name (*)
|
CBotVar* GetItem(const char* name) override; // return an element of a class according to its name (*)
|
||||||
CBotVar* GetItemRef(int nIdent);
|
CBotVar* GetItemRef(int nIdent) override;
|
||||||
CBotVar* GetItemList();
|
CBotVar* GetItemList() override;
|
||||||
|
|
||||||
CBotString GetValString();
|
CBotString GetValString() override;
|
||||||
void SetPointer(CBotVar* p);
|
void SetPointer(CBotVar* p) override;
|
||||||
CBotVarClass*
|
CBotVarClass*
|
||||||
GetPointer();
|
GetPointer() override;
|
||||||
|
|
||||||
void SetIdent(long n); // associates an identification number (unique)
|
void SetIdent(long n) override; // associates an identification number (unique)
|
||||||
long GetIdent(); // gives the identification number associated with
|
long GetIdent(); // gives the identification number associated with
|
||||||
void ConstructorSet();
|
void ConstructorSet() override;
|
||||||
|
|
||||||
bool Save1State(FILE* pf);
|
bool Save1State(FILE* pf) override;
|
||||||
void Maj(void* pUser, bool bContinue);
|
void Maj(void* pUser, bool bContinue) override;
|
||||||
|
|
||||||
bool Eq(CBotVar* left, CBotVar* right);
|
bool Eq(CBotVar* left, CBotVar* right) override;
|
||||||
bool Ne(CBotVar* left, CBotVar* right);
|
bool Ne(CBotVar* left, CBotVar* right) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1482,19 +1482,19 @@ public:
|
||||||
CBotVarArray( const CBotToken* name, CBotTypResult& type );
|
CBotVarArray( const CBotToken* name, CBotTypResult& type );
|
||||||
~CBotVarArray();
|
~CBotVarArray();
|
||||||
|
|
||||||
void SetPointer(CBotVar* p);
|
void SetPointer(CBotVar* p) override;
|
||||||
CBotVarClass*
|
CBotVarClass*
|
||||||
GetPointer();
|
GetPointer() override;
|
||||||
|
|
||||||
void Copy(CBotVar* pSrc, bool bName=true);
|
void Copy(CBotVar* pSrc, bool bName=true) override;
|
||||||
CBotVar* GetItem(int n, bool bGrow=false); // makes an element according to its numeric index
|
CBotVar* GetItem(int n, bool bGrow=false) override; // makes an element according to its numeric index
|
||||||
// enlarged the table if necessary if bExtend
|
// enlarged the table if necessary if bExtend
|
||||||
// CBotVar* GetItem(const char* name); // makes a element by literal index
|
// CBotVar* GetItem(const char* name); // makes a element by literal index
|
||||||
CBotVar* GetItemList(); // gives the first item in the list
|
CBotVar* GetItemList() override; // gives the first item in the list
|
||||||
|
|
||||||
CBotString GetValString(); // gets the contents of the array into a string
|
CBotString GetValString() override; // gets the contents of the array into a string
|
||||||
|
|
||||||
bool Save1State(FILE* pf);
|
bool Save1State(FILE* pf) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -35,16 +35,16 @@ struct SystemTimeStamp
|
||||||
class CSystemUtilsLinux : public CSystemUtils
|
class CSystemUtilsLinux : public CSystemUtils
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() override;
|
void Init() override;
|
||||||
|
|
||||||
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
||||||
|
|
||||||
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
||||||
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
||||||
|
|
||||||
virtual std::string GetSaveDir() override;
|
std::string GetSaveDir() override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) override;
|
void Usleep(int usec) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
bool m_zenityAvailable = false;
|
bool m_zenityAvailable = false;
|
||||||
|
|
|
@ -28,13 +28,13 @@
|
||||||
class CSystemUtilsMacOSX : public CSystemUtilsOther
|
class CSystemUtilsMacOSX : public CSystemUtilsOther
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() override;
|
void Init() override;
|
||||||
|
|
||||||
virtual std::string GetDataPath() override;
|
std::string GetDataPath() override;
|
||||||
virtual std::string GetLangPath() override;
|
std::string GetLangPath() override;
|
||||||
virtual std::string GetSaveDir() override;
|
std::string GetSaveDir() override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) override;
|
void Usleep(int usec) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::string m_ASPath;
|
std::string m_ASPath;
|
||||||
|
|
|
@ -42,12 +42,12 @@ struct SystemTimeStamp
|
||||||
class CSystemUtilsOther : public CSystemUtils
|
class CSystemUtilsOther : public CSystemUtils
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() override;
|
void Init() override;
|
||||||
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
||||||
|
|
||||||
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
||||||
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) override;
|
void Usleep(int usec) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -33,16 +33,16 @@ struct SystemTimeStamp
|
||||||
class CSystemUtilsWindows : public CSystemUtils
|
class CSystemUtilsWindows : public CSystemUtils
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() override;
|
void Init() override;
|
||||||
|
|
||||||
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
||||||
|
|
||||||
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
||||||
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
||||||
|
|
||||||
virtual std::string GetSaveDir() override;
|
std::string GetSaveDir() override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) override;
|
void Usleep(int usec) override;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static std::string UTF8_Encode(const std::wstring &wstr);
|
static std::string UTF8_Encode(const std::wstring &wstr);
|
||||||
|
|
|
@ -122,40 +122,40 @@ public:
|
||||||
explicit CDefaultFramebuffer(const FramebufferParams ¶ms);
|
explicit CDefaultFramebuffer(const FramebufferParams ¶ms);
|
||||||
|
|
||||||
//! Creates default framebuffer
|
//! Creates default framebuffer
|
||||||
virtual void Create() override;
|
void Create() override;
|
||||||
|
|
||||||
//! Destroys default framebuffer
|
//! Destroys default framebuffer
|
||||||
virtual void Destroy() override;
|
void Destroy() override;
|
||||||
|
|
||||||
//! Returns true
|
//! Returns true
|
||||||
virtual bool IsDefault() override;
|
bool IsDefault() override;
|
||||||
|
|
||||||
//! Returns width of buffers in this framebuffer
|
//! Returns width of buffers in this framebuffer
|
||||||
virtual int GetWidth() override;
|
int GetWidth() override;
|
||||||
|
|
||||||
//! Returns height of buffers in this framebuffer
|
//! Returns height of buffers in this framebuffer
|
||||||
virtual int GetHeight() override;
|
int GetHeight() override;
|
||||||
|
|
||||||
//! Returns depth size in bits
|
//! Returns depth size in bits
|
||||||
virtual int GetDepth() override;
|
int GetDepth() override;
|
||||||
|
|
||||||
//! Returns number of samples or 1 if multisampling is not supported
|
//! Returns number of samples or 1 if multisampling is not supported
|
||||||
virtual int GetSamples() override;
|
int GetSamples() override;
|
||||||
|
|
||||||
//! Returns texture that contains color buffer or 0 if not available
|
//! Returns texture that contains color buffer or 0 if not available
|
||||||
virtual int GetColorTexture() override;
|
int GetColorTexture() override;
|
||||||
|
|
||||||
//! Returns texture that contains depth buffer or 0 if not available
|
//! Returns texture that contains depth buffer or 0 if not available
|
||||||
virtual int GetDepthTexture() override;
|
int GetDepthTexture() override;
|
||||||
|
|
||||||
//! Binds this framebuffer to context
|
//! Binds this framebuffer to context
|
||||||
virtual void Bind() override;
|
void Bind() override;
|
||||||
|
|
||||||
//! Unbinds this framebuffer from context
|
//! Unbinds this framebuffer from context
|
||||||
virtual void Unbind() override;
|
void Unbind() override;
|
||||||
|
|
||||||
//! Copies content of color buffer to screen
|
//! Copies content of color buffer to screen
|
||||||
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end of Gfx
|
} // end of Gfx
|
||||||
|
|
|
@ -73,24 +73,10 @@ void CNullDevice::SetTransform(TransformType type, const Math::Matrix &matrix)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
const Math::Matrix& CNullDevice::GetTransform(TransformType type)
|
|
||||||
{
|
|
||||||
return m_matrix;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::MultiplyTransform(TransformType type, const Math::Matrix &matrix)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetMaterial(const Material &material)
|
void CNullDevice::SetMaterial(const Material &material)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
const Material& CNullDevice::GetMaterial()
|
|
||||||
{
|
|
||||||
return m_material;
|
|
||||||
}
|
|
||||||
|
|
||||||
int CNullDevice::GetMaxLightCount()
|
int CNullDevice::GetMaxLightCount()
|
||||||
{
|
{
|
||||||
return 99;
|
return 99;
|
||||||
|
@ -100,20 +86,10 @@ void CNullDevice::SetLight(int index, const Light &light)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
const Light& CNullDevice::GetLight(int index)
|
|
||||||
{
|
|
||||||
return m_light;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetLightEnabled(int index, bool enabled)
|
void CNullDevice::SetLightEnabled(int index, bool enabled)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CNullDevice::GetLightEnabled(int index)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
Texture CNullDevice::CreateTexture(CImage *image, const TextureCreateParams ¶ms)
|
Texture CNullDevice::CreateTexture(CImage *image, const TextureCreateParams ¶ms)
|
||||||
{
|
{
|
||||||
Texture tex;
|
Texture tex;
|
||||||
|
@ -156,20 +132,10 @@ void CNullDevice::SetTexture(int index, unsigned int textureId)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
Texture CNullDevice::GetTexture(int index)
|
|
||||||
{
|
|
||||||
return Texture();
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetTextureEnabled(int index, bool enabled)
|
void CNullDevice::SetTextureEnabled(int index, bool enabled)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CNullDevice::GetTextureEnabled(int index)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetTextureStageParams(int index, const TextureStageParams ¶ms)
|
void CNullDevice::SetTextureStageParams(int index, const TextureStageParams ¶ms)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -182,11 +148,6 @@ void CNullDevice::SetTextureCoordGeneration(int index, TextureGenerationParams &
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
TextureStageParams CNullDevice::GetTextureStageParams(int index)
|
|
||||||
{
|
|
||||||
return TextureStageParams();
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::DrawPrimitive(PrimitiveType type, const Vertex *vertices, int vertexCount,
|
void CNullDevice::DrawPrimitive(PrimitiveType type, const Vertex *vertices, int vertexCount,
|
||||||
Color color)
|
Color color)
|
||||||
{
|
{
|
||||||
|
@ -249,11 +210,6 @@ void CNullDevice::SetRenderState(RenderState state, bool enabled)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CNullDevice::GetRenderState(RenderState state)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetColorMask(bool red, bool green, bool blue, bool alpha)
|
void CNullDevice::SetColorMask(bool red, bool green, bool blue, bool alpha)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -262,86 +218,38 @@ void CNullDevice::SetDepthTestFunc(CompFunc func)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
CompFunc CNullDevice::GetDepthTestFunc()
|
|
||||||
{
|
|
||||||
return COMP_FUNC_NEVER;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetDepthBias(float factor, float units)
|
void CNullDevice::SetDepthBias(float factor, float units)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
float CNullDevice::GetDepthBias()
|
|
||||||
{
|
|
||||||
return 0.0f;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetAlphaTestFunc(CompFunc func, float refValue)
|
void CNullDevice::SetAlphaTestFunc(CompFunc func, float refValue)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void CNullDevice::GetAlphaTestFunc(CompFunc &func, float &refValue)
|
|
||||||
{
|
|
||||||
|
|
||||||
func = COMP_FUNC_NEVER;
|
|
||||||
refValue = 0.0f;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend)
|
void CNullDevice::SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void CNullDevice::GetBlendFunc(BlendFunc &srcBlend, BlendFunc &dstBlend)
|
|
||||||
{
|
|
||||||
srcBlend = BLEND_ZERO;
|
|
||||||
dstBlend = BLEND_ZERO;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetClearColor(const Color &color)
|
void CNullDevice::SetClearColor(const Color &color)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
Color CNullDevice::GetClearColor()
|
|
||||||
{
|
|
||||||
return Color(0.0f, 0.0f, 0.0f, 0.0f);
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetGlobalAmbient(const Color &color)
|
void CNullDevice::SetGlobalAmbient(const Color &color)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
Color CNullDevice::GetGlobalAmbient()
|
|
||||||
{
|
|
||||||
return Color(0.0f, 0.0f, 0.0f, 0.0f);
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetFogParams(FogMode mode, const Color &color, float start, float end, float density)
|
void CNullDevice::SetFogParams(FogMode mode, const Color &color, float start, float end, float density)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void CNullDevice::GetFogParams(FogMode &mode, Color &color, float &start, float &end, float &density)
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetCullMode(CullMode mode)
|
void CNullDevice::SetCullMode(CullMode mode)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
CullMode CNullDevice::GetCullMode()
|
|
||||||
{
|
|
||||||
return CULL_CW;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetShadeModel(ShadeModel model)
|
void CNullDevice::SetShadeModel(ShadeModel model)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
ShadeModel CNullDevice::GetShadeModel()
|
|
||||||
{
|
|
||||||
return SHADE_FLAT;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::SetShadowColor(float value)
|
void CNullDevice::SetShadowColor(float value)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -350,11 +258,6 @@ void CNullDevice::SetFillMode(FillMode mode)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
FillMode CNullDevice::GetFillMode()
|
|
||||||
{
|
|
||||||
return FILL_POINT;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CNullDevice::CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height)
|
void CNullDevice::CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,127 +42,106 @@ public:
|
||||||
CNullDevice();
|
CNullDevice();
|
||||||
virtual ~CNullDevice();
|
virtual ~CNullDevice();
|
||||||
|
|
||||||
virtual void DebugHook();
|
void DebugHook() override;
|
||||||
virtual void DebugLights();
|
void DebugLights() override;
|
||||||
|
|
||||||
virtual bool Create();
|
bool Create() override;
|
||||||
virtual void Destroy();
|
void Destroy() override;
|
||||||
|
|
||||||
virtual void ConfigChanged(const DeviceConfig &newConfig);
|
void ConfigChanged(const DeviceConfig &newConfig) override;
|
||||||
|
|
||||||
virtual void BeginScene();
|
void BeginScene() override;
|
||||||
virtual void EndScene();
|
void EndScene() override;
|
||||||
|
|
||||||
virtual void Clear();
|
void Clear() override;
|
||||||
|
|
||||||
virtual void SetTransform(TransformType type, const Math::Matrix &matrix);
|
void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
||||||
virtual const Math::Matrix& GetTransform(TransformType type);
|
|
||||||
virtual void MultiplyTransform(TransformType type, const Math::Matrix &matrix);
|
|
||||||
|
|
||||||
virtual void SetMaterial(const Material &material);
|
void SetMaterial(const Material &material) override;
|
||||||
virtual const Material& GetMaterial();
|
|
||||||
|
|
||||||
virtual int GetMaxLightCount();
|
int GetMaxLightCount() override;
|
||||||
virtual void SetLight(int index, const Light &light);
|
void SetLight(int index, const Light &light) override;
|
||||||
virtual const Light& GetLight(int index);
|
void SetLightEnabled(int index, bool enabled) override;
|
||||||
virtual void SetLightEnabled(int index, bool enabled);
|
|
||||||
virtual bool GetLightEnabled(int index);
|
|
||||||
|
|
||||||
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms);
|
Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms);
|
Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateDepthTexture(int width, int height, int depth);
|
Texture CreateDepthTexture(int width, int height, int depth) override;
|
||||||
virtual void DestroyTexture(const Texture &texture);
|
void DestroyTexture(const Texture &texture) override;
|
||||||
virtual void DestroyAllTextures();
|
void DestroyAllTextures() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureStageCount();
|
int GetMaxTextureStageCount() override;
|
||||||
virtual void SetTexture(int index, const Texture &texture);
|
void SetTexture(int index, const Texture &texture) override;
|
||||||
virtual void SetTexture(int index, unsigned int textureId);
|
void SetTexture(int index, unsigned int textureId) override;
|
||||||
virtual Texture GetTexture(int index);
|
void SetTextureEnabled(int index, bool enabled) override;
|
||||||
virtual void SetTextureEnabled(int index, bool enabled);
|
|
||||||
virtual bool GetTextureEnabled(int index);
|
|
||||||
|
|
||||||
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms);
|
void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
||||||
virtual TextureStageParams GetTextureStageParams(int index);
|
|
||||||
|
|
||||||
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT);
|
void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
||||||
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms);
|
void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
||||||
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
void DrawPrimitive(PrimitiveType type, const Vertex* vertices, int vertexCount, Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f));
|
void DrawPrimitive(PrimitiveType type, const VertexTex2* vertices, int vertexCount, Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f));
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount);
|
|
||||||
|
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount);
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount);
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount);
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount);
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount);
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount);
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void DrawStaticBuffer(unsigned int bufferId);
|
void DrawStaticBuffer(unsigned int bufferId) override;
|
||||||
virtual void DestroyStaticBuffer(unsigned int bufferId);
|
void DestroyStaticBuffer(unsigned int bufferId) override;
|
||||||
|
|
||||||
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius);
|
int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
||||||
|
|
||||||
virtual void SetViewport(int x, int y, int width, int height);
|
void SetViewport(int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void SetRenderState(RenderState state, bool enabled);
|
void SetRenderState(RenderState state, bool enabled) override;
|
||||||
virtual bool GetRenderState(RenderState state);
|
|
||||||
|
|
||||||
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha);
|
void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
||||||
|
|
||||||
virtual void SetDepthTestFunc(CompFunc func);
|
void SetDepthTestFunc(CompFunc func) override;
|
||||||
virtual CompFunc GetDepthTestFunc();
|
|
||||||
|
|
||||||
virtual void SetDepthBias(float factor, float units);
|
void SetDepthBias(float factor, float units) override;
|
||||||
virtual float GetDepthBias();
|
|
||||||
|
|
||||||
virtual void SetAlphaTestFunc(CompFunc func, float refValue);
|
void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
||||||
virtual void GetAlphaTestFunc(CompFunc &func, float &refValue);
|
|
||||||
|
|
||||||
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend);
|
void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
||||||
virtual void GetBlendFunc(BlendFunc &srcBlend, BlendFunc &dstBlend);
|
|
||||||
|
|
||||||
virtual void SetClearColor(const Color &color);
|
void SetClearColor(const Color &color) override;
|
||||||
virtual Color GetClearColor();
|
|
||||||
|
|
||||||
virtual void SetGlobalAmbient(const Color &color);
|
void SetGlobalAmbient(const Color &color) override;
|
||||||
virtual Color GetGlobalAmbient();
|
|
||||||
|
|
||||||
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density);
|
void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
||||||
virtual void GetFogParams(FogMode &mode, Color &color, float &start, float &end, float &density);
|
|
||||||
|
|
||||||
virtual void SetCullMode(CullMode mode);
|
void SetCullMode(CullMode mode) override;
|
||||||
virtual CullMode GetCullMode();
|
|
||||||
|
|
||||||
virtual void SetShadeModel(ShadeModel model);
|
void SetShadeModel(ShadeModel model) override;
|
||||||
virtual ShadeModel GetShadeModel();
|
|
||||||
|
|
||||||
virtual void SetShadowColor(float value);
|
void SetShadowColor(float value) override;
|
||||||
|
|
||||||
virtual void SetFillMode(FillMode mode) ;
|
void SetFillMode(FillMode mode) override;
|
||||||
virtual FillMode GetFillMode();
|
|
||||||
|
|
||||||
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height);
|
void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const;
|
std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const override;
|
||||||
|
|
||||||
virtual CFramebuffer* GetFramebuffer(std::string name);
|
CFramebuffer* GetFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params);
|
CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
||||||
|
|
||||||
virtual void DeleteFramebuffer(std::string name);
|
void DeleteFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual bool IsAnisotropySupported();
|
bool IsAnisotropySupported() override;
|
||||||
virtual int GetMaxAnisotropyLevel();
|
int GetMaxAnisotropyLevel() override;
|
||||||
|
|
||||||
virtual int GetMaxSamples();
|
int GetMaxSamples() override;
|
||||||
|
|
||||||
virtual bool IsShadowMappingSupported();
|
bool IsShadowMappingSupported() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureSize();
|
int GetMaxTextureSize() override;
|
||||||
|
|
||||||
virtual bool IsFramebufferSupported();
|
bool IsFramebufferSupported() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Math::Matrix m_matrix;
|
Math::Matrix m_matrix;
|
||||||
|
|
|
@ -57,108 +57,108 @@ public:
|
||||||
CGL21Device(const DeviceConfig &config);
|
CGL21Device(const DeviceConfig &config);
|
||||||
virtual ~CGL21Device();
|
virtual ~CGL21Device();
|
||||||
|
|
||||||
virtual void DebugHook() override;
|
void DebugHook() override;
|
||||||
virtual void DebugLights() override;
|
void DebugLights() override;
|
||||||
|
|
||||||
virtual bool Create() override;
|
bool Create() override;
|
||||||
virtual void Destroy() override;
|
void Destroy() override;
|
||||||
|
|
||||||
virtual void ConfigChanged(const DeviceConfig &newConfig) override;
|
void ConfigChanged(const DeviceConfig &newConfig) override;
|
||||||
|
|
||||||
virtual void BeginScene() override;
|
void BeginScene() override;
|
||||||
virtual void EndScene() override;
|
void EndScene() override;
|
||||||
|
|
||||||
virtual void Clear() override;
|
void Clear() override;
|
||||||
|
|
||||||
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
||||||
|
|
||||||
virtual void SetMaterial(const Material &material) override;
|
void SetMaterial(const Material &material) override;
|
||||||
|
|
||||||
virtual int GetMaxLightCount() override;
|
int GetMaxLightCount() override;
|
||||||
virtual void SetLight(int index, const Light &light) override;
|
void SetLight(int index, const Light &light) override;
|
||||||
virtual void SetLightEnabled(int index, bool enabled) override;
|
void SetLightEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateDepthTexture(int width, int height, int depth) override;
|
Texture CreateDepthTexture(int width, int height, int depth) override;
|
||||||
virtual void DestroyTexture(const Texture &texture) override;
|
void DestroyTexture(const Texture &texture) override;
|
||||||
virtual void DestroyAllTextures() override;
|
void DestroyAllTextures() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureStageCount() override;
|
int GetMaxTextureStageCount() override;
|
||||||
virtual void SetTexture(int index, const Texture &texture) override;
|
void SetTexture(int index, const Texture &texture) override;
|
||||||
virtual void SetTexture(int index, unsigned int textureId) override;
|
void SetTexture(int index, unsigned int textureId) override;
|
||||||
virtual void SetTextureEnabled(int index, bool enabled) override;
|
void SetTextureEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
||||||
|
|
||||||
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
||||||
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
||||||
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
||||||
|
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void DrawStaticBuffer(unsigned int bufferId) override;
|
void DrawStaticBuffer(unsigned int bufferId) override;
|
||||||
virtual void DestroyStaticBuffer(unsigned int bufferId) override;
|
void DestroyStaticBuffer(unsigned int bufferId) override;
|
||||||
|
|
||||||
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
||||||
|
|
||||||
virtual void SetViewport(int x, int y, int width, int height) override;
|
void SetViewport(int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void SetRenderState(RenderState state, bool enabled) override;
|
void SetRenderState(RenderState state, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
||||||
|
|
||||||
virtual void SetDepthTestFunc(CompFunc func) override;
|
void SetDepthTestFunc(CompFunc func) override;
|
||||||
|
|
||||||
virtual void SetDepthBias(float factor, float units) override;
|
void SetDepthBias(float factor, float units) override;
|
||||||
|
|
||||||
virtual void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
||||||
|
|
||||||
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
||||||
|
|
||||||
virtual void SetClearColor(const Color &color) override;
|
void SetClearColor(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetGlobalAmbient(const Color &color) override;
|
void SetGlobalAmbient(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
||||||
|
|
||||||
virtual void SetCullMode(CullMode mode) override;
|
void SetCullMode(CullMode mode) override;
|
||||||
|
|
||||||
virtual void SetShadeModel(ShadeModel model) override;
|
void SetShadeModel(ShadeModel model) override;
|
||||||
|
|
||||||
virtual void SetShadowColor(float value) override;
|
void SetShadowColor(float value) override;
|
||||||
|
|
||||||
virtual void SetFillMode(FillMode mode) override;
|
void SetFillMode(FillMode mode) override;
|
||||||
|
|
||||||
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const override;
|
std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const override;
|
||||||
|
|
||||||
virtual CFramebuffer* GetFramebuffer(std::string name) override;
|
CFramebuffer* GetFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
||||||
|
|
||||||
virtual void DeleteFramebuffer(std::string name) override;
|
void DeleteFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual bool IsAnisotropySupported() override;
|
bool IsAnisotropySupported() override;
|
||||||
virtual int GetMaxAnisotropyLevel() override;
|
int GetMaxAnisotropyLevel() override;
|
||||||
|
|
||||||
virtual int GetMaxSamples() override;
|
int GetMaxSamples() override;
|
||||||
|
|
||||||
virtual bool IsShadowMappingSupported() override;
|
bool IsShadowMappingSupported() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureSize() override;
|
int GetMaxTextureSize() override;
|
||||||
|
|
||||||
virtual bool IsFramebufferSupported() override;
|
bool IsFramebufferSupported() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! Updates position for given light based on transformation matrices
|
//! Updates position for given light based on transformation matrices
|
||||||
|
|
|
@ -57,108 +57,108 @@ public:
|
||||||
CGL33Device(const DeviceConfig &config);
|
CGL33Device(const DeviceConfig &config);
|
||||||
virtual ~CGL33Device();
|
virtual ~CGL33Device();
|
||||||
|
|
||||||
virtual void DebugHook() override;
|
void DebugHook() override;
|
||||||
virtual void DebugLights() override;
|
void DebugLights() override;
|
||||||
|
|
||||||
virtual bool Create() override;
|
bool Create() override;
|
||||||
virtual void Destroy() override;
|
void Destroy() override;
|
||||||
|
|
||||||
virtual void ConfigChanged(const DeviceConfig &newConfig) override;
|
void ConfigChanged(const DeviceConfig &newConfig) override;
|
||||||
|
|
||||||
virtual void BeginScene() override;
|
void BeginScene() override;
|
||||||
virtual void EndScene() override;
|
void EndScene() override;
|
||||||
|
|
||||||
virtual void Clear() override;
|
void Clear() override;
|
||||||
|
|
||||||
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
||||||
|
|
||||||
virtual void SetMaterial(const Material &material) override;
|
void SetMaterial(const Material &material) override;
|
||||||
|
|
||||||
virtual int GetMaxLightCount() override;
|
int GetMaxLightCount() override;
|
||||||
virtual void SetLight(int index, const Light &light) override;
|
void SetLight(int index, const Light &light) override;
|
||||||
virtual void SetLightEnabled(int index, bool enabled) override;
|
void SetLightEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateDepthTexture(int width, int height, int depth) override;
|
Texture CreateDepthTexture(int width, int height, int depth) override;
|
||||||
virtual void DestroyTexture(const Texture &texture) override;
|
void DestroyTexture(const Texture &texture) override;
|
||||||
virtual void DestroyAllTextures() override;
|
void DestroyAllTextures() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureStageCount() override;
|
int GetMaxTextureStageCount() override;
|
||||||
virtual void SetTexture(int index, const Texture &texture) override;
|
void SetTexture(int index, const Texture &texture) override;
|
||||||
virtual void SetTexture(int index, unsigned int textureId) override;
|
void SetTexture(int index, unsigned int textureId) override;
|
||||||
virtual void SetTextureEnabled(int index, bool enabled) override;
|
void SetTextureEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
||||||
|
|
||||||
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
||||||
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
||||||
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
||||||
|
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void DrawStaticBuffer(unsigned int bufferId) override;
|
void DrawStaticBuffer(unsigned int bufferId) override;
|
||||||
virtual void DestroyStaticBuffer(unsigned int bufferId) override;
|
void DestroyStaticBuffer(unsigned int bufferId) override;
|
||||||
|
|
||||||
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
||||||
|
|
||||||
virtual void SetViewport(int x, int y, int width, int height) override;
|
void SetViewport(int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void SetRenderState(RenderState state, bool enabled) override;
|
void SetRenderState(RenderState state, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
||||||
|
|
||||||
virtual void SetDepthTestFunc(CompFunc func) override;
|
void SetDepthTestFunc(CompFunc func) override;
|
||||||
|
|
||||||
virtual void SetDepthBias(float factor, float units) override;
|
void SetDepthBias(float factor, float units) override;
|
||||||
|
|
||||||
virtual void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
||||||
|
|
||||||
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
||||||
|
|
||||||
virtual void SetClearColor(const Color &color) override;
|
void SetClearColor(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetGlobalAmbient(const Color &color) override;
|
void SetGlobalAmbient(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
||||||
|
|
||||||
virtual void SetCullMode(CullMode mode) override;
|
void SetCullMode(CullMode mode) override;
|
||||||
|
|
||||||
virtual void SetShadeModel(ShadeModel model) override;
|
void SetShadeModel(ShadeModel model) override;
|
||||||
|
|
||||||
virtual void SetShadowColor(float value) override;
|
void SetShadowColor(float value) override;
|
||||||
|
|
||||||
virtual void SetFillMode(FillMode mode) override;
|
void SetFillMode(FillMode mode) override;
|
||||||
|
|
||||||
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const override;
|
std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const override;
|
||||||
|
|
||||||
virtual CFramebuffer* GetFramebuffer(std::string name) override;
|
CFramebuffer* GetFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
||||||
|
|
||||||
virtual void DeleteFramebuffer(std::string name) override;
|
void DeleteFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual bool IsAnisotropySupported() override;
|
bool IsAnisotropySupported() override;
|
||||||
virtual int GetMaxAnisotropyLevel() override;
|
int GetMaxAnisotropyLevel() override;
|
||||||
|
|
||||||
virtual int GetMaxSamples() override;
|
int GetMaxSamples() override;
|
||||||
|
|
||||||
virtual bool IsShadowMappingSupported() override;
|
bool IsShadowMappingSupported() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureSize() override;
|
int GetMaxTextureSize() override;
|
||||||
|
|
||||||
virtual bool IsFramebufferSupported() override;
|
bool IsFramebufferSupported() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! Updates position for given light based on transformation matrices
|
//! Updates position for given light based on transformation matrices
|
||||||
|
|
|
@ -76,108 +76,108 @@ public:
|
||||||
CGLDevice(const DeviceConfig &config);
|
CGLDevice(const DeviceConfig &config);
|
||||||
virtual ~CGLDevice();
|
virtual ~CGLDevice();
|
||||||
|
|
||||||
virtual void DebugHook() override;
|
void DebugHook() override;
|
||||||
virtual void DebugLights() override;
|
void DebugLights() override;
|
||||||
|
|
||||||
virtual bool Create() override;
|
bool Create() override;
|
||||||
virtual void Destroy() override;
|
void Destroy() override;
|
||||||
|
|
||||||
virtual void ConfigChanged(const DeviceConfig &newConfig) override;
|
void ConfigChanged(const DeviceConfig &newConfig) override;
|
||||||
|
|
||||||
virtual void BeginScene() override;
|
void BeginScene() override;
|
||||||
virtual void EndScene() override;
|
void EndScene() override;
|
||||||
|
|
||||||
virtual void Clear() override;
|
void Clear() override;
|
||||||
|
|
||||||
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
||||||
|
|
||||||
virtual void SetMaterial(const Material &material) override;
|
void SetMaterial(const Material &material) override;
|
||||||
|
|
||||||
virtual int GetMaxLightCount() override;
|
int GetMaxLightCount() override;
|
||||||
virtual void SetLight(int index, const Light &light) override;
|
void SetLight(int index, const Light &light) override;
|
||||||
virtual void SetLightEnabled(int index, bool enabled) override;
|
void SetLightEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateDepthTexture(int width, int height, int depth) override;
|
Texture CreateDepthTexture(int width, int height, int depth) override;
|
||||||
virtual void DestroyTexture(const Texture &texture) override;
|
void DestroyTexture(const Texture &texture) override;
|
||||||
virtual void DestroyAllTextures() override;
|
void DestroyAllTextures() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureStageCount() override;
|
int GetMaxTextureStageCount() override;
|
||||||
virtual void SetTexture(int index, const Texture &texture) override;
|
void SetTexture(int index, const Texture &texture) override;
|
||||||
virtual void SetTexture(int index, unsigned int textureId) override;
|
void SetTexture(int index, unsigned int textureId) override;
|
||||||
virtual void SetTextureEnabled(int index, bool enabled) override;
|
void SetTextureEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
||||||
|
|
||||||
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
||||||
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
||||||
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
||||||
|
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void DrawStaticBuffer(unsigned int bufferId) override;
|
void DrawStaticBuffer(unsigned int bufferId) override;
|
||||||
virtual void DestroyStaticBuffer(unsigned int bufferId) override;
|
void DestroyStaticBuffer(unsigned int bufferId) override;
|
||||||
|
|
||||||
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
||||||
|
|
||||||
virtual void SetViewport(int x, int y, int width, int height) override;
|
void SetViewport(int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void SetRenderState(RenderState state, bool enabled) override;
|
void SetRenderState(RenderState state, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
||||||
|
|
||||||
virtual void SetDepthTestFunc(CompFunc func) override;
|
void SetDepthTestFunc(CompFunc func) override;
|
||||||
|
|
||||||
virtual void SetDepthBias(float factor, float units) override;
|
void SetDepthBias(float factor, float units) override;
|
||||||
|
|
||||||
virtual void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
||||||
|
|
||||||
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
||||||
|
|
||||||
virtual void SetClearColor(const Color &color) override;
|
void SetClearColor(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetGlobalAmbient(const Color &color) override;
|
void SetGlobalAmbient(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
||||||
|
|
||||||
virtual void SetCullMode(CullMode mode) override;
|
void SetCullMode(CullMode mode) override;
|
||||||
|
|
||||||
virtual void SetShadeModel(ShadeModel model) override;
|
void SetShadeModel(ShadeModel model) override;
|
||||||
|
|
||||||
virtual void SetShadowColor(float value) override;
|
void SetShadowColor(float value) override;
|
||||||
|
|
||||||
virtual void SetFillMode(FillMode mode) override;
|
void SetFillMode(FillMode mode) override;
|
||||||
|
|
||||||
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const override;
|
std::unique_ptr<CFrameBufferPixels> GetFrameBufferPixels() const override;
|
||||||
|
|
||||||
virtual CFramebuffer* GetFramebuffer(std::string name) override;
|
CFramebuffer* GetFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
||||||
|
|
||||||
virtual void DeleteFramebuffer(std::string name) override;
|
void DeleteFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual bool IsAnisotropySupported() override;
|
bool IsAnisotropySupported() override;
|
||||||
virtual int GetMaxAnisotropyLevel() override;
|
int GetMaxAnisotropyLevel() override;
|
||||||
|
|
||||||
virtual int GetMaxSamples() override;
|
int GetMaxSamples() override;
|
||||||
|
|
||||||
virtual bool IsShadowMappingSupported() override;
|
bool IsShadowMappingSupported() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureSize() override;
|
int GetMaxTextureSize() override;
|
||||||
|
|
||||||
virtual bool IsFramebufferSupported() override;
|
bool IsFramebufferSupported() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! Updates internal modelview matrix
|
//! Updates internal modelview matrix
|
||||||
|
|
|
@ -51,29 +51,29 @@ protected:
|
||||||
public:
|
public:
|
||||||
CGLFramebuffer(const FramebufferParams& params);
|
CGLFramebuffer(const FramebufferParams& params);
|
||||||
|
|
||||||
virtual void Create() override;
|
void Create() override;
|
||||||
|
|
||||||
virtual void Destroy() override;
|
void Destroy() override;
|
||||||
|
|
||||||
virtual bool IsDefault() override;
|
bool IsDefault() override;
|
||||||
|
|
||||||
virtual int GetWidth() override;
|
int GetWidth() override;
|
||||||
|
|
||||||
virtual int GetHeight() override;
|
int GetHeight() override;
|
||||||
|
|
||||||
virtual int GetDepth() override;
|
int GetDepth() override;
|
||||||
|
|
||||||
virtual int GetSamples() override;
|
int GetSamples() override;
|
||||||
|
|
||||||
virtual int GetColorTexture() override;
|
int GetColorTexture() override;
|
||||||
|
|
||||||
virtual int GetDepthTexture() override;
|
int GetDepthTexture() override;
|
||||||
|
|
||||||
virtual void Bind() override;
|
void Bind() override;
|
||||||
|
|
||||||
virtual void Unbind() override;
|
void Unbind() override;
|
||||||
|
|
||||||
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -101,29 +101,29 @@ protected:
|
||||||
public:
|
public:
|
||||||
CGLFramebufferEXT(const FramebufferParams& params);
|
CGLFramebufferEXT(const FramebufferParams& params);
|
||||||
|
|
||||||
virtual void Create() override;
|
void Create() override;
|
||||||
|
|
||||||
virtual void Destroy() override;
|
void Destroy() override;
|
||||||
|
|
||||||
virtual bool IsDefault() override;
|
bool IsDefault() override;
|
||||||
|
|
||||||
virtual int GetWidth() override;
|
int GetWidth() override;
|
||||||
|
|
||||||
virtual int GetHeight() override;
|
int GetHeight() override;
|
||||||
|
|
||||||
virtual int GetDepth() override;
|
int GetDepth() override;
|
||||||
|
|
||||||
virtual int GetSamples() override;
|
int GetSamples() override;
|
||||||
|
|
||||||
virtual int GetColorTexture() override;
|
int GetColorTexture() override;
|
||||||
|
|
||||||
virtual int GetDepthTexture() override;
|
int GetDepthTexture() override;
|
||||||
|
|
||||||
virtual void Bind() override;
|
void Bind() override;
|
||||||
|
|
||||||
virtual void Unbind() override;
|
void Unbind() override;
|
||||||
|
|
||||||
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end of Gfx
|
} // end of Gfx
|
||||||
|
|
|
@ -80,7 +80,7 @@ public:
|
||||||
bool immediat = false;
|
bool immediat = false;
|
||||||
|
|
||||||
//! Read from line in scene file
|
//! Read from line in scene file
|
||||||
virtual void Read(CLevelParserLine* line);
|
void Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
//! Checks if lost condition is met
|
//! Checks if lost condition is met
|
||||||
bool CheckLost();
|
bool CheckLost();
|
||||||
|
@ -102,5 +102,5 @@ public:
|
||||||
bool changed = false;
|
bool changed = false;
|
||||||
|
|
||||||
//! Read from line in scene file
|
//! Read from line in scene file
|
||||||
virtual void Read(CLevelParserLine* line);
|
void Read(CLevelParserLine* line) override;
|
||||||
};
|
};
|
||||||
|
|
|
@ -72,15 +72,15 @@ public:
|
||||||
CAutoBase(COldObject* object);
|
CAutoBase(COldObject* object);
|
||||||
~CAutoBase();
|
~CAutoBase();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
void Start(int param);
|
void Start(int param) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
Error TakeOff(bool printMsg);
|
Error TakeOff(bool printMsg);
|
||||||
|
|
||||||
|
|
|
@ -42,17 +42,17 @@ public:
|
||||||
CAutoConvert(COldObject* object);
|
CAutoConvert(COldObject* object);
|
||||||
~CAutoConvert();
|
~CAutoConvert();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* SearchStone(ObjectType type);
|
CObject* SearchStone(ObjectType type);
|
||||||
|
|
|
@ -42,16 +42,16 @@ public:
|
||||||
CAutoDerrick(COldObject* object);
|
CAutoDerrick(COldObject* object);
|
||||||
~CAutoDerrick();
|
~CAutoDerrick();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* SearchCargo();
|
CObject* SearchCargo();
|
||||||
|
|
|
@ -42,18 +42,18 @@ public:
|
||||||
CAutoDestroyer(COldObject* object);
|
CAutoDestroyer(COldObject* object);
|
||||||
~CAutoDestroyer();
|
~CAutoDestroyer();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
Error StartAction(int param);
|
Error StartAction(int param) override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* SearchPlastic();
|
CObject* SearchPlastic();
|
||||||
|
|
|
@ -43,18 +43,18 @@ public:
|
||||||
CAutoFactory(COldObject* object);
|
CAutoFactory(COldObject* object);
|
||||||
~CAutoFactory();
|
~CAutoFactory();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error StartAction(int param);
|
Error StartAction(int param) override;
|
||||||
void SetProgram(const std::string& program);
|
void SetProgram(const std::string& program);
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateInterface();
|
void UpdateInterface();
|
||||||
|
|
|
@ -30,12 +30,12 @@ public:
|
||||||
CAutoFlag(COldObject* object);
|
CAutoFlag(COldObject* object);
|
||||||
~CAutoFlag();
|
~CAutoFlag();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
void Start(int param);
|
void Start(int param) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_strong = 0.0f;
|
float m_strong = 0.0f;
|
||||||
|
|
|
@ -46,15 +46,15 @@ public:
|
||||||
CAutoHouston(COldObject* object);
|
CAutoHouston(COldObject* object);
|
||||||
~CAutoHouston();
|
~CAutoHouston();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
void Start(int param);
|
void Start(int param) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_progress = 0.0f;
|
float m_progress = 0.0f;
|
||||||
|
|
|
@ -47,17 +47,17 @@ public:
|
||||||
CAutoLabo(COldObject* object);
|
CAutoLabo(COldObject* object);
|
||||||
~CAutoLabo();
|
~CAutoLabo();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
Error StartAction(int param);
|
Error StartAction(int param) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateInterface();
|
void UpdateInterface();
|
||||||
|
|
|
@ -41,14 +41,14 @@ public:
|
||||||
CAutoMush(COldObject* object);
|
CAutoMush(COldObject* object);
|
||||||
~CAutoMush();
|
~CAutoMush();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
bool SearchTarget();
|
bool SearchTarget();
|
||||||
|
|
|
@ -39,14 +39,14 @@ public:
|
||||||
CAutoNest(COldObject* object);
|
CAutoNest(COldObject* object);
|
||||||
~CAutoNest();
|
~CAutoNest();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
bool SearchFree(Math::Vector pos);
|
bool SearchFree(Math::Vector pos);
|
||||||
|
|
|
@ -42,16 +42,16 @@ public:
|
||||||
CAutoNuclearPlant(COldObject* object);
|
CAutoNuclearPlant(COldObject* object);
|
||||||
~CAutoNuclearPlant();
|
~CAutoNuclearPlant();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* SearchUranium();
|
CObject* SearchUranium();
|
||||||
|
|
|
@ -43,13 +43,13 @@ public:
|
||||||
CAutoPortico(COldObject* object);
|
CAutoPortico(COldObject* object);
|
||||||
~CAutoPortico();
|
~CAutoPortico();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
void Start(int param);
|
void Start(int param) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateTrackMapping(float left, float right);
|
void UpdateTrackMapping(float left, float right);
|
||||||
|
|
|
@ -39,17 +39,17 @@ public:
|
||||||
CAutoPowerCaptor(COldObject* object);
|
CAutoPowerCaptor(COldObject* object);
|
||||||
~CAutoPowerCaptor();
|
~CAutoPowerCaptor();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
void StartLightning();
|
void StartLightning();
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void ChargeObject(float rTime);
|
void ChargeObject(float rTime);
|
||||||
|
|
|
@ -43,16 +43,16 @@ public:
|
||||||
CAutoPowerPlant(COldObject* object);
|
CAutoPowerPlant(COldObject* object);
|
||||||
~CAutoPowerPlant();
|
~CAutoPowerPlant();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateInterface(float rTime);
|
void UpdateInterface(float rTime);
|
||||||
|
|
|
@ -31,13 +31,13 @@ public:
|
||||||
CAutoPowerStation(COldObject* object);
|
CAutoPowerStation(COldObject* object);
|
||||||
~CAutoPowerStation();
|
~CAutoPowerStation();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateInterface(float rTime);
|
void UpdateInterface(float rTime);
|
||||||
|
|
|
@ -40,12 +40,12 @@ public:
|
||||||
CAutoRadar(COldObject* object);
|
CAutoRadar(COldObject* object);
|
||||||
~CAutoRadar();
|
~CAutoRadar();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateInterface();
|
void UpdateInterface();
|
||||||
|
|
|
@ -42,16 +42,16 @@ public:
|
||||||
CAutoRepair(COldObject* object);
|
CAutoRepair(COldObject* object);
|
||||||
~CAutoRepair();
|
~CAutoRepair();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* SearchVehicle();
|
CObject* SearchVehicle();
|
||||||
|
|
|
@ -39,17 +39,17 @@ public:
|
||||||
CAutoResearch(COldObject* object);
|
CAutoResearch(COldObject* object);
|
||||||
~CAutoResearch();
|
~CAutoResearch();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
Error StartAction(int result);
|
Error StartAction(int result) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateInterface();
|
void UpdateInterface();
|
||||||
|
|
|
@ -30,11 +30,11 @@ public:
|
||||||
CAutoRoot(COldObject* object);
|
CAutoRoot(COldObject* object);
|
||||||
~CAutoRoot();
|
~CAutoRoot();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
|
|
|
@ -42,16 +42,16 @@ public:
|
||||||
CAutoTower(COldObject* object);
|
CAutoTower(COldObject* object);
|
||||||
~CAutoTower();
|
~CAutoTower();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void UpdateInterface(float rTime);
|
void UpdateInterface(float rTime);
|
||||||
|
|
|
@ -40,16 +40,16 @@ public:
|
||||||
CAutoVault(COldObject* object);
|
CAutoVault(COldObject* object);
|
||||||
~CAutoVault();
|
~CAutoVault();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init();
|
void Init() override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error GetError();
|
Error GetError() override;
|
||||||
|
|
||||||
bool CreateInterface(bool bSelect);
|
bool CreateInterface(bool bSelect) override;
|
||||||
|
|
||||||
bool Write(CLevelParserLine* line);
|
bool Write(CLevelParserLine* line) override;
|
||||||
bool Read(CLevelParserLine* line);
|
bool Read(CLevelParserLine* line) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
int CountKeys();
|
int CountKeys();
|
||||||
|
|
|
@ -50,9 +50,9 @@ public:
|
||||||
CMotionAnt(COldObject* object);
|
CMotionAnt(COldObject* object);
|
||||||
~CMotionAnt();
|
~CMotionAnt();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void CreatePhysics();
|
void CreatePhysics();
|
||||||
|
|
|
@ -44,9 +44,9 @@ public:
|
||||||
CMotionBee(COldObject* object);
|
CMotionBee(COldObject* object);
|
||||||
~CMotionBee();
|
~CMotionBee();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void CreatePhysics();
|
void CreatePhysics();
|
||||||
|
|
|
@ -62,10 +62,10 @@ public:
|
||||||
CMotionHuman(COldObject* object);
|
CMotionHuman(COldObject* object);
|
||||||
~CMotionHuman();
|
~CMotionHuman();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error SetAction(int action, float time=0.2f);
|
Error SetAction(int action, float time=0.2f) override;
|
||||||
|
|
||||||
void StartDisplayPerso();
|
void StartDisplayPerso();
|
||||||
void StopDisplayPerso();
|
void StopDisplayPerso();
|
||||||
|
|
|
@ -28,6 +28,6 @@ public:
|
||||||
CMotionLevelController(COldObject* object);
|
CMotionLevelController(COldObject* object);
|
||||||
~CMotionLevelController();
|
~CMotionLevelController();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
};
|
};
|
||||||
|
|
|
@ -30,9 +30,9 @@ public:
|
||||||
CMotionQueen(COldObject* object);
|
CMotionQueen(COldObject* object);
|
||||||
~CMotionQueen();
|
~CMotionQueen();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void CreatePhysics();
|
void CreatePhysics();
|
||||||
|
|
|
@ -48,9 +48,9 @@ public:
|
||||||
CMotionSpider(COldObject* object);
|
CMotionSpider(COldObject* object);
|
||||||
~CMotionSpider();
|
~CMotionSpider();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void CreatePhysics();
|
void CreatePhysics();
|
||||||
|
|
|
@ -39,10 +39,10 @@ public:
|
||||||
CMotionToto(COldObject* object);
|
CMotionToto(COldObject* object);
|
||||||
~CMotionToto();
|
~CMotionToto();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
Error SetAction(int action, float time=0.2f);
|
Error SetAction(int action, float time=0.2f) override;
|
||||||
void SetLinkType(ObjectType type);
|
void SetLinkType(ObjectType type);
|
||||||
|
|
||||||
void StartDisplayInfo();
|
void StartDisplayInfo();
|
||||||
|
|
|
@ -29,9 +29,9 @@ public:
|
||||||
CMotionVehicle(COldObject* object);
|
CMotionVehicle(COldObject* object);
|
||||||
~CMotionVehicle();
|
~CMotionVehicle();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void CreatePhysics(ObjectType type);
|
void CreatePhysics(ObjectType type);
|
||||||
|
|
|
@ -30,12 +30,12 @@ public:
|
||||||
CMotionWorm(COldObject* object);
|
CMotionWorm(COldObject* object);
|
||||||
~CMotionWorm();
|
~CMotionWorm();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false);
|
void DeleteObject(bool bAll=false) override;
|
||||||
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager);
|
void Create(Math::Vector pos, float angle, ObjectType type, float power, Gfx::COldModelManager* modelManager) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
bool SetParam(int rank, float value);
|
bool SetParam(int rank, float value) override;
|
||||||
float GetParam(int rank);
|
float GetParam(int rank) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void CreatePhysics();
|
void CreatePhysics();
|
||||||
|
|
|
@ -99,7 +99,7 @@ public:
|
||||||
CForegroundTask(COldObject* object) : CTask(object) {}
|
CForegroundTask(COldObject* object) : CTask(object) {}
|
||||||
|
|
||||||
bool IsBackground() final { return false; }
|
bool IsBackground() final { return false; }
|
||||||
virtual bool IsPilot() { return false; }
|
bool IsPilot() override { return false; }
|
||||||
};
|
};
|
||||||
|
|
||||||
class CBackgroundTask : public CTask
|
class CBackgroundTask : public CTask
|
||||||
|
|
|
@ -32,10 +32,10 @@ public:
|
||||||
CTaskAdvance(COldObject* object);
|
CTaskAdvance(COldObject* object);
|
||||||
~CTaskAdvance();
|
~CTaskAdvance();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(float length);
|
Error Start(float length);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_totalLength = 0.0f;
|
float m_totalLength = 0.0f;
|
||||||
|
|
|
@ -53,11 +53,11 @@ public:
|
||||||
CTaskBuild(COldObject* object);
|
CTaskBuild(COldObject* object);
|
||||||
~CTaskBuild();
|
~CTaskBuild();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(ObjectType type);
|
Error Start(ObjectType type);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
Error FlatFloor();
|
Error FlatFloor();
|
||||||
|
|
|
@ -29,11 +29,11 @@ public:
|
||||||
CTaskDeleteMark(COldObject* object);
|
CTaskDeleteMark(COldObject* object);
|
||||||
~CTaskDeleteMark();
|
~CTaskDeleteMark();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start();
|
Error Start();
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void DeleteMark();
|
void DeleteMark();
|
||||||
|
|
|
@ -30,12 +30,12 @@ public:
|
||||||
CTaskFire(COldObject* object);
|
CTaskFire(COldObject* object);
|
||||||
~CTaskFire();
|
~CTaskFire();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(float delay);
|
Error Start(float delay);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
bool IsPilot();
|
bool IsPilot() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_delay = 0.0f;
|
float m_delay = 0.0f;
|
||||||
|
|
|
@ -42,11 +42,11 @@ public:
|
||||||
CTaskFireAnt(COldObject* object);
|
CTaskFireAnt(COldObject* object);
|
||||||
~CTaskFireAnt();
|
~CTaskFireAnt();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(Math::Vector impact);
|
Error Start(Math::Vector impact);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
|
|
|
@ -42,11 +42,11 @@ public:
|
||||||
CTaskFlag(COldObject* object);
|
CTaskFlag(COldObject* object);
|
||||||
~CTaskFlag();
|
~CTaskFlag();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(TaskFlagOrder order, int rank);
|
Error Start(TaskFlagOrder order, int rank);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
Error CreateFlag(int rank);
|
Error CreateFlag(int rank);
|
||||||
|
|
|
@ -79,10 +79,10 @@ public:
|
||||||
CTaskGoto(COldObject* object);
|
CTaskGoto(COldObject* object);
|
||||||
~CTaskGoto();
|
~CTaskGoto();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(Math::Vector goal, float altitude, TaskGotoGoal goalMode, TaskGotoCrash crashMode);
|
Error Start(Math::Vector goal, float altitude, TaskGotoGoal goalMode, TaskGotoCrash crashMode);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* WormSearch(Math::Vector &impact);
|
CObject* WormSearch(Math::Vector &impact);
|
||||||
|
|
|
@ -30,11 +30,11 @@ public:
|
||||||
CTaskGunGoal(COldObject* object);
|
CTaskGunGoal(COldObject* object);
|
||||||
~CTaskGunGoal();
|
~CTaskGunGoal();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(float dirV, float dirH);
|
Error Start(float dirV, float dirH);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_progress = 0.0f;
|
float m_progress = 0.0f;
|
||||||
|
|
|
@ -62,11 +62,11 @@ public:
|
||||||
CTaskManip(COldObject* object);
|
CTaskManip(COldObject* object);
|
||||||
~CTaskManip();
|
~CTaskManip();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(TaskManipOrder order, TaskManipArm arm);
|
Error Start(TaskManipOrder order, TaskManipArm arm);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void InitAngle();
|
void InitAngle();
|
||||||
|
|
|
@ -42,11 +42,11 @@ public:
|
||||||
CTaskPen(COldObject* object);
|
CTaskPen(COldObject* object);
|
||||||
~CTaskPen();
|
~CTaskPen();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(bool bDown, TraceColor color);
|
Error Start(bool bDown, TraceColor color);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void SoundManip(float time, float amplitude, float frequency);
|
void SoundManip(float time, float amplitude, float frequency);
|
||||||
|
|
|
@ -43,11 +43,11 @@ public:
|
||||||
CTaskRecover(COldObject* object);
|
CTaskRecover(COldObject* object);
|
||||||
~CTaskRecover();
|
~CTaskRecover();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start();
|
Error Start();
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* SearchRuin();
|
CObject* SearchRuin();
|
||||||
|
|
|
@ -47,11 +47,11 @@ public:
|
||||||
CTaskSearch(COldObject* object);
|
CTaskSearch(COldObject* object);
|
||||||
~CTaskSearch();
|
~CTaskSearch();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start();
|
Error Start();
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void InitAngle();
|
void InitAngle();
|
||||||
|
|
|
@ -57,12 +57,12 @@ public:
|
||||||
CTaskShield(COldObject* object);
|
CTaskShield(COldObject* object);
|
||||||
~CTaskShield();
|
~CTaskShield();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(TaskShieldMode mode, float delay);
|
Error Start(TaskShieldMode mode, float delay);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool IsBusy();
|
bool IsBusy() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
float GetActiveRadius();
|
float GetActiveRadius();
|
||||||
|
|
||||||
|
|
|
@ -30,11 +30,11 @@ public:
|
||||||
CTaskSpiderExplo(COldObject* object);
|
CTaskSpiderExplo(COldObject* object);
|
||||||
~CTaskSpiderExplo();
|
~CTaskSpiderExplo();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start();
|
Error Start();
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_time = 0.0f;
|
float m_time = 0.0f;
|
||||||
|
|
|
@ -48,11 +48,11 @@ public:
|
||||||
CTaskTake(COldObject* object);
|
CTaskTake(COldObject* object);
|
||||||
~CTaskTake();
|
~CTaskTake();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start();
|
Error Start();
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* SearchTakeObject(float &angle, float dLimit, float aLimit);
|
CObject* SearchTakeObject(float &angle, float dLimit, float aLimit);
|
||||||
|
|
|
@ -41,11 +41,11 @@ public:
|
||||||
CTaskTerraform(COldObject* object);
|
CTaskTerraform(COldObject* object);
|
||||||
~CTaskTerraform();
|
~CTaskTerraform();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start();
|
Error Start();
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
bool Abort();
|
bool Abort() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
bool Terraform();
|
bool Terraform();
|
||||||
|
|
|
@ -30,10 +30,10 @@ public:
|
||||||
CTaskTurn(COldObject* object);
|
CTaskTurn(COldObject* object);
|
||||||
~CTaskTurn();
|
~CTaskTurn();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(float angle);
|
Error Start(float angle);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_angle = 0.0f;
|
float m_angle = 0.0f;
|
||||||
|
|
|
@ -30,10 +30,10 @@ public:
|
||||||
CTaskWait(COldObject* object);
|
CTaskWait(COldObject* object);
|
||||||
~CTaskWait();
|
~CTaskWait();
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
Error Start(float time);
|
Error Start(float time);
|
||||||
Error IsEnded();
|
Error IsEnded() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_waitTime = 0.0f;
|
float m_waitTime = 0.0f;
|
||||||
|
|
|
@ -32,11 +32,11 @@ public:
|
||||||
CButton();
|
CButton();
|
||||||
virtual ~CButton();
|
virtual ~CButton();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetImmediat(bool bRepeat);
|
void SetImmediat(bool bRepeat);
|
||||||
bool GetImmediat();
|
bool GetImmediat();
|
||||||
|
|
|
@ -36,11 +36,11 @@ public:
|
||||||
CCheck();
|
CCheck();
|
||||||
virtual ~CCheck();
|
virtual ~CCheck();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,11 +37,11 @@ public:
|
||||||
CColor();
|
CColor();
|
||||||
virtual ~CColor();
|
virtual ~CColor();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetRepeat(bool bRepeat);
|
void SetRepeat(bool bRepeat);
|
||||||
bool GetRepeat();
|
bool GetRepeat();
|
||||||
|
|
|
@ -116,13 +116,13 @@ public:
|
||||||
|
|
||||||
virtual ~CEdit();
|
virtual ~CEdit();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
void SetPos(Math::Point pos);
|
void SetPos(Math::Point pos) override;
|
||||||
void SetDim(Math::Point dim);
|
void SetDim(Math::Point dim) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetText(const char *text, bool bNew=true);
|
void SetText(const char *text, bool bNew=true);
|
||||||
void GetText(char *buffer, int max);
|
void GetText(char *buffer, int max);
|
||||||
|
@ -176,7 +176,7 @@ public:
|
||||||
bool HyperTest(EventType event);
|
bool HyperTest(EventType event);
|
||||||
bool HyperGo(EventType event);
|
bool HyperGo(EventType event);
|
||||||
|
|
||||||
void SetFontSize(float size);
|
void SetFontSize(float size) override;
|
||||||
|
|
||||||
bool ClearFormat();
|
bool ClearFormat();
|
||||||
bool SetFormat(int cursor1, int cursor2, int format);
|
bool SetFormat(int cursor1, int cursor2, int format);
|
||||||
|
|
|
@ -51,13 +51,13 @@ public:
|
||||||
CEditValue();
|
CEditValue();
|
||||||
virtual ~CEditValue();
|
virtual ~CEditValue();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
void SetPos(Math::Point pos);
|
void SetPos(Math::Point pos) override;
|
||||||
void SetDim(Math::Point dim);
|
void SetDim(Math::Point dim) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetType(EditValueType type);
|
void SetType(EditValueType type);
|
||||||
EditValueType GetType();
|
EditValueType GetType();
|
||||||
|
|
|
@ -39,7 +39,7 @@ public:
|
||||||
unsigned int GetVisibleValueIndex();
|
unsigned int GetVisibleValueIndex();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
std::string GetLabel();
|
std::string GetLabel() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
std::vector<float> m_values;
|
std::vector<float> m_values;
|
||||||
|
|
|
@ -30,11 +30,11 @@ public:
|
||||||
CGauge();
|
CGauge();
|
||||||
virtual ~CGauge();
|
virtual ~CGauge();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetLevel(float level);
|
void SetLevel(float level);
|
||||||
float GetLevel();
|
float GetLevel();
|
||||||
|
|
|
@ -36,11 +36,11 @@ public:
|
||||||
CGroup();
|
CGroup();
|
||||||
virtual ~CGroup();
|
virtual ~CGroup();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
|
|
|
@ -37,11 +37,11 @@ public:
|
||||||
CImage ();
|
CImage ();
|
||||||
virtual ~CImage();
|
virtual ~CImage();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetFilenameImage(const std::string& name);
|
void SetFilenameImage(const std::string& name);
|
||||||
|
|
||||||
|
|
|
@ -43,12 +43,12 @@ public:
|
||||||
virtual ~CKey();
|
virtual ~CKey();
|
||||||
|
|
||||||
//! Creates a new key slot button
|
//! Creates a new key slot button
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) override;
|
||||||
//! Management of an event
|
//! Management of an event
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
//! Draws button
|
//! Draws button
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
//! Management of binding
|
//! Management of binding
|
||||||
//@{
|
//@{
|
||||||
|
|
|
@ -34,10 +34,10 @@ public:
|
||||||
CLabel();
|
CLabel();
|
||||||
virtual ~CLabel();
|
virtual ~CLabel();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -99,7 +99,7 @@ protected:
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// Overridden to avoid warning about hiding the virtual function
|
// Overridden to avoid warning about hiding the virtual function
|
||||||
virtual bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
std::array<std::unique_ptr<CButton>, LISTMAXDISPLAY> m_buttons;
|
std::array<std::unique_ptr<CButton>, LISTMAXDISPLAY> m_buttons;
|
||||||
|
|
|
@ -72,9 +72,9 @@ public:
|
||||||
CMap();
|
CMap();
|
||||||
~CMap();
|
~CMap();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) override;
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void UpdateTerrain();
|
void UpdateTerrain();
|
||||||
void UpdateTerrain(int bx, int by, int ex, int ey);
|
void UpdateTerrain(int bx, int by, int ex, int ey);
|
||||||
|
|
|
@ -41,17 +41,17 @@ public:
|
||||||
CScroll();
|
CScroll();
|
||||||
~CScroll();
|
~CScroll();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) override;
|
||||||
|
|
||||||
void SetPos(Math::Point pos);
|
void SetPos(Math::Point pos) override;
|
||||||
void SetDim(Math::Point dim);
|
void SetDim(Math::Point dim) override;
|
||||||
|
|
||||||
bool SetState(int state, bool bState);
|
bool SetState(int state, bool bState) override;
|
||||||
bool SetState(int state);
|
bool SetState(int state) override;
|
||||||
bool ClearState(int state);
|
bool ClearState(int state) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetVisibleValue(float value);
|
void SetVisibleValue(float value);
|
||||||
float GetVisibleValue();
|
float GetVisibleValue();
|
||||||
|
|
|
@ -32,11 +32,11 @@ public:
|
||||||
CShortcut();
|
CShortcut();
|
||||||
~CShortcut();
|
~CShortcut();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void DrawVertex(int icon, float zoom);
|
void DrawVertex(int icon, float zoom);
|
||||||
|
|
|
@ -34,17 +34,17 @@ public:
|
||||||
CSlider();
|
CSlider();
|
||||||
~CSlider();
|
~CSlider();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) override;
|
||||||
|
|
||||||
void SetPos(Math::Point pos);
|
void SetPos(Math::Point pos) override;
|
||||||
void SetDim(Math::Point dim);
|
void SetDim(Math::Point dim) override;
|
||||||
|
|
||||||
bool SetState(int state, bool bState);
|
bool SetState(int state, bool bState) override;
|
||||||
bool SetState(int state);
|
bool SetState(int state) override;
|
||||||
bool ClearState(int state);
|
bool ClearState(int state) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
void Draw();
|
void Draw() override;
|
||||||
|
|
||||||
void SetLimit(float min, float max);
|
void SetLimit(float min, float max);
|
||||||
|
|
||||||
|
|
|
@ -39,11 +39,11 @@ public:
|
||||||
CTarget();
|
CTarget();
|
||||||
~CTarget();
|
~CTarget();
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event);
|
bool EventProcess(const Event &event) override;
|
||||||
void Draw();
|
void Draw() override;
|
||||||
bool GetTooltip(Math::Point pos, std::string &name);
|
bool GetTooltip(Math::Point pos, std::string &name) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CObject* DetectFriendObject(Math::Point pos);
|
CObject* DetectFriendObject(Math::Point pos);
|
||||||
|
|
|
@ -79,7 +79,7 @@ public:
|
||||||
EventType GetEventTypeFull();
|
EventType GetEventTypeFull();
|
||||||
EventType GetEventTypeClose();
|
EventType GetEventTypeClose();
|
||||||
|
|
||||||
virtual void SetName(std::string name, bool tooltip = true) override;
|
void SetName(std::string name, bool tooltip = true) override;
|
||||||
|
|
||||||
void SetTrashEvent(bool bTrash);
|
void SetTrashEvent(bool bTrash);
|
||||||
bool GetTrashEvent();
|
bool GetTrashEvent();
|
||||||
|
|
Loading…
Reference in New Issue