Implements variable usage, tweaks and fixes for variable assignment
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
|
||||
class EvalValue{
|
||||
public:
|
||||
EvalValue() = default;
|
||||
virtual ~EvalValue() = default;
|
||||
virtual ScriptType* GetType() = 0;
|
||||
|
||||
@@ -18,6 +19,8 @@ public:
|
||||
return ! (this->operator==(b));
|
||||
}
|
||||
|
||||
virtual EvalValue* Clone() = 0;
|
||||
|
||||
virtual long EvaluateInteger(){
|
||||
throw EvaluationException("Can't evaluate this EvalValue as integer.");
|
||||
}
|
||||
@@ -41,6 +44,10 @@ public:
|
||||
_type = new ScriptType(TypeClass::Bool);
|
||||
}
|
||||
|
||||
EvalValue* Clone() final{
|
||||
return new BooleanEvalValue(_value);
|
||||
}
|
||||
|
||||
~BooleanEvalValue() final{
|
||||
delete _type;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user