Misc
This commit is contained in:
@@ -61,6 +61,9 @@ Add :: (a: *Array($T), item: T)
|
||||
a.data = realloc(a.data, SizeOf(T) * a.cap->U64)
|
||||
a.data[a.len++] = item
|
||||
|
||||
Memes :: (a: S32, ...)
|
||||
pass
|
||||
|
||||
main :: (): int
|
||||
guys: Array(Guy)
|
||||
Add(&guys, {pos = {100, 100}})
|
||||
@@ -69,6 +72,7 @@ main :: (): int
|
||||
SetTargetFPS(60)
|
||||
for !WindowShouldClose()
|
||||
|
||||
Y := GetScreenHeight()
|
||||
g := guys.data
|
||||
if IsKeyDown(KEY_W);; g.pos.y -= 2
|
||||
if IsKeyDown(KEY_S);; g.pos.y += 2
|
||||
@@ -77,8 +81,10 @@ main :: (): int
|
||||
|
||||
|
||||
BeginDrawing()
|
||||
ClearBackground({100})
|
||||
ClearBackground(RAYWHITE)
|
||||
DrawFPS(0, 0)
|
||||
DrawText("Testing and stuff", 100, 100, 20, RAYWHITE)
|
||||
DrawCube({0,0,0}, 10, 10, 10, BLACK)
|
||||
for i := 0, i < guys.len, i += 1
|
||||
it := guys.data + i
|
||||
DrawCircleV(it.pos, 16, MAROON)
|
||||
|
||||
Reference in New Issue
Block a user