pr 55
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
declare struct Color(raw: bounded)
|
||||
pub declare struct Color(raw: bounded)
|
||||
[[
|
||||
BLACK: Color(0b),
|
||||
WHITE: Color(65535b),
|
||||
@@ -7,6 +7,6 @@ declare struct Color(raw: bounded)
|
||||
BLUE: Color(31b)
|
||||
]]
|
||||
|
||||
declare contract Gfx host {
|
||||
pub declare contract Gfx host {
|
||||
fn clear(color: Color): void;
|
||||
}
|
||||
@@ -1,11 +1,11 @@
|
||||
declare struct ButtonState(
|
||||
pub declare struct ButtonState(
|
||||
pressed: bool,
|
||||
released: bool,
|
||||
down: bool,
|
||||
hold_frames: bounded
|
||||
)
|
||||
|
||||
declare struct Pad(
|
||||
pub declare struct Pad(
|
||||
up: ButtonState,
|
||||
down: ButtonState,
|
||||
left: ButtonState,
|
||||
@@ -20,10 +20,6 @@ declare struct Pad(
|
||||
select: ButtonState
|
||||
)
|
||||
|
||||
declare contract Input host {
|
||||
pub declare contract Input host {
|
||||
fn pad(): Pad;
|
||||
}
|
||||
|
||||
fn add(a: int, b: int): int {
|
||||
return a + b;
|
||||
}
|
||||
Reference in New Issue
Block a user