Logic unit control
This commit is contained in:
@@ -21,8 +21,12 @@ public class LAssembler{
|
||||
LInstruction[] instructions;
|
||||
|
||||
public LAssembler(){
|
||||
//instruction counter
|
||||
putVar("@counter").value = 0;
|
||||
//unix timestamp
|
||||
putConst("@time", 0);
|
||||
//currently controlled unit
|
||||
putConst("@unit", null);
|
||||
|
||||
//add default constants
|
||||
putConst("false", 0);
|
||||
@@ -45,6 +49,10 @@ public class LAssembler{
|
||||
}
|
||||
}
|
||||
|
||||
for(UnitType type : Vars.content.units()){
|
||||
putConst("@" + type.name, type);
|
||||
}
|
||||
|
||||
//store sensor constants
|
||||
|
||||
for(LAccess sensor : LAccess.all){
|
||||
|
||||
Reference in New Issue
Block a user