From 9e15cb6352c9afc771c41451dea86b93e35349e5 Mon Sep 17 00:00:00 2001 From: tslil clingman <> Date: Thu, 9 Sep 2021 23:47:24 -0400 Subject: Don't override the skycylinder! --- src/main.zig | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/main.zig') diff --git a/src/main.zig b/src/main.zig index 8f8753d..2dec9be 100644 --- a/src/main.zig +++ b/src/main.zig @@ -111,7 +111,7 @@ pub fn main() !void { var back_sprite = try sf.Sprite.createFromTexture(back_texture); defer back_sprite.destroy(); - back_sprite.setScale(.{ .x = 4.0 * constants.ScreenWidth / constants.BackTextureWidth, .y = constants.ScreenHeight / (2 * constants.BackTextureHeight) }); + back_sprite.setScale(.{ .x = 4.0 * constants.ScreenWidth / constants.BackTextureWidth, .y = constants.ScreenHeight / constants.BackTextureHeight }); // Load wall textures var wall_textures = try sf.Texture.createFromFile("walls.png"); @@ -180,8 +180,6 @@ pub fn main() !void { player.acc_y -= std.math.sin(player.ang) * acc_mag; } - window.clear(sf.Color.fromRGB(100, 100, 100)); - // First the background const back_scroll = @floatToInt(i32, -constants.BackTextureWidth * player.ang / (2 * PI)); back_sprite.setTextureRect(sf.IntRect{ -- cgit v1.3.1