Add system variable stubs

This commit is contained in:
otya128 committed 2017-07-09 23:39:07 +09:00
1 parent be5424a203
commit 98aed4f3dc
2 files changed
+13

No files matched your search

+5
View File
@@ -258,6 +258,11 @@ class Compiler
addSystemVariable("MILLISEC", new MilliSecond());
addSystemVariable("PRGSLOT", new ProgramSlot());
addSystemVariable("CALLIDX", new CallIndex());
addSystemVariable("MPCOUNT", new Zero());
addSystemVariable("MPHOST", new Zero());
addSystemVariable("MPLOCAL", new Zero());
addSystemVariable("MICPOS", new Zero());
addSystemVariable("MICSIIZE", new Zero());
}
void addSystemVariable(wstring name, SystemVariable var)
{
+8
View File
@@ -149,3 +149,11 @@ class CallIndex : SystemVariable
return Value(vm.petitcomputer.callidx);
}
}
class Zero : SystemVariable
{
@property override Value value()
{
return Value(0);
}
}