Fix LOCATE
This commit is contained in:
@@ -235,15 +235,21 @@ class BuiltinFunction
|
|||||||
return std.math.PI;
|
return std.math.PI;
|
||||||
}
|
}
|
||||||
//static ABS = function double(double x) => abs(this.result == ValueType.Double ? 1 : 0);
|
//static ABS = function double(double x) => abs(this.result == ValueType.Double ? 1 : 0);
|
||||||
static void LOCATE(PetitComputer p, DefaultValue!int x, DefaultValue!int y, DefaultValue!(int, false) z)
|
static void LOCATE(PetitComputer p, DefaultValue!int x, DefaultValue!int y, int z)
|
||||||
{
|
{
|
||||||
x.setDefaultValue(p.console.CSRX);
|
x.setDefaultValue(p.console.CSRX);
|
||||||
y.setDefaultValue(p.console.CSRY);
|
y.setDefaultValue(p.console.CSRY);
|
||||||
z.setDefaultValue(p.console.CSRZ);
|
|
||||||
p.console.CSRX = cast(int)x;
|
p.console.CSRX = cast(int)x;
|
||||||
p.console.CSRY = cast(int)y;
|
p.console.CSRY = cast(int)y;
|
||||||
p.console.CSRZ = cast(int)z;
|
p.console.CSRZ = cast(int)z;
|
||||||
}
|
}
|
||||||
|
static void LOCATE(PetitComputer p, DefaultValue!int x, DefaultValue!int y)
|
||||||
|
{
|
||||||
|
x.setDefaultValue(p.console.CSRX);
|
||||||
|
y.setDefaultValue(p.console.CSRY);
|
||||||
|
p.console.CSRX = cast(int)x;
|
||||||
|
p.console.CSRY = cast(int)y;
|
||||||
|
}
|
||||||
static void COLOR(PetitComputer p, DefaultValue!int fore, DefaultValue!(int, false) back)
|
static void COLOR(PetitComputer p, DefaultValue!int fore, DefaultValue!(int, false) back)
|
||||||
{
|
{
|
||||||
fore.setDefaultValue(p.console.foreColor);
|
fore.setDefaultValue(p.console.foreColor);
|
||||||
|
|||||||
Reference in New Issue
Block a user