From 86d33a7fc57bbbd1397d216520eba6e38a8ffd73 Mon Sep 17 00:00:00 2001 From: Simon Kellet Date: Tue, 6 Aug 2024 18:16:14 +0100 Subject: [PATCH] nearly there --- Game/DrawGame.lua | 16 +++++++-- Game/GameKeyPressed.lua | 10 ++++-- Game/UpdateGame.lua | 14 ++++++++ conf.lua | 8 +++-- constants.lua | 11 +++++-- game.love | Bin 9407825 -> 9416366 bytes main.lua | 20 ++++++------ player.lua | 38 +++++++++++++++++++--- powerups/powerup.lua | 70 ++++++++++++++++++++++++++++++++++++++++ restart.lua | 9 ++++++ 10 files changed, 172 insertions(+), 24 deletions(-) create mode 100644 powerups/powerup.lua diff --git a/Game/DrawGame.lua b/Game/DrawGame.lua index 3ac0f09..85f82ea 100644 --- a/Game/DrawGame.lua +++ b/Game/DrawGame.lua @@ -6,16 +6,16 @@ end local function drawHealth() love.graphics.setFont(GameFont) - local height = love.graphics.getHeight() - local width = love.graphics.getWidth() + local height = love.graphics.getHeight() / _G.Y_SCALE + local width = love.graphics.getWidth() / _G.X_SCALE love.graphics.print("P1:" .. UserPlayer1.health, 5, 5) love.graphics.print("P2:" .. UserPlayer2.health, width - 200, height - 95) end function DrawGame() local curWidth, curHeight = love.graphics.getDimensions() - --STI love.graphics.scale(_G.X_SCALE, _G.Y_SCALE) + GameMap:draw(0, 0, _G.X_SCALE, _G.Y_SCALE) GameMap:resize(curWidth / _G.X_SCALE, curHeight / _G.Y_SCALE) @@ -25,6 +25,7 @@ function DrawGame() drawFPS() end + -- Bullets for _, v in ipairs(Bullets1) do v:draw() end @@ -32,9 +33,18 @@ function DrawGame() v:draw() end + -- PowerUps + for _, v in ipairs(PowerUps) do + v:draw() + end + UserPlayer1:draw() UserPlayer2:draw() --Draw Health + --TODO: make this nicer looking drawHealth() + + --TODO: draw running score + --drawScore() end diff --git a/Game/GameKeyPressed.lua b/Game/GameKeyPressed.lua index 3691f34..6ff73eb 100644 --- a/Game/GameKeyPressed.lua +++ b/Game/GameKeyPressed.lua @@ -34,9 +34,10 @@ function GameKeyPressed(key) end if DebugFlag and key == "1" then - UserPlayer1.speed = 50000 - print("player1 speed increased!") + --UserPlayer1.speed = 50000 + --print("player1 speed increased!") end + if DebugFlag and key == "2" then _G.CUR_LEVEL = 2 RestartGame() @@ -47,4 +48,9 @@ function GameKeyPressed(key) RestartGame() love.load() end + + if key == "p" then + testP = PowerUp("speed", 300, 300, "assets/powerup.jpeg", 10) + table.insert(PowerUps, testP) + end end diff --git a/Game/UpdateGame.lua b/Game/UpdateGame.lua index 0b9f9fc..7cdb970 100644 --- a/Game/UpdateGame.lua +++ b/Game/UpdateGame.lua @@ -37,6 +37,7 @@ function UpdateGame(dt) EnableKeyPress2 = true end + -- Update Bullets1 for i, v in ipairs(Bullets1) do v:update(dt) @@ -82,6 +83,7 @@ function UpdateGame(dt) end end + -- Update Bullets2 for i, v in ipairs(Bullets2) do v:update(dt) @@ -144,6 +146,18 @@ function UpdateGame(dt) end end + --PowerUp timer to place + PUTimeToPlace = PUTimeToPlace - dt + --print(PUTimeToPlace) + if PUTimeToPlace <= 0 then + local w, h = love.graphics.getDimensions() + local ranx = love.math.random(30, w) + local rany = love.math.random(100, h) + local newPU = PowerUp("speed", ranx, rany, "assets/powerup.jpeg", 10) + table.insert(PowerUps, newPU) + PUTimeToPlace = _G.PU_TIMER --reset + end + UserPlayer1:handleKeys("w", "s", "a", "d", dt) UserPlayer2:handleKeys("up", "down", "left", "right", dt) UserPlayer1:updateCol() diff --git a/conf.lua b/conf.lua index fa210de..b0eb973 100644 --- a/conf.lua +++ b/conf.lua @@ -1,7 +1,11 @@ --Config file for the game function love.conf(t) - t.window.width = 1366 - t.window.height = 768 + --t.window.width = 1366 + --t.window.height = 768 + + t.window.width = 1600 + t.window.height = 960 + t.window.title = "Tanks-A-Lot" t.window.resizable = true t.version = "11.5" diff --git a/constants.lua b/constants.lua index eca2a7f..76dd5ec 100644 --- a/constants.lua +++ b/constants.lua @@ -32,13 +32,20 @@ PAUSE_POS = 0 PAUSE_MAX = 2 -- 0 resume, 1 menu, 2 quit BULLETS_MAX = 10 -- MAX amount of bullets a player can shoot -BULLETS_BOUNCE_MAX = 7 -- MAX amount of bounces before exploding! -BULLETS_LIFETIME = 50 +BULLETS_BOUNCE_MAX = 10 -- MAX amount of bounces before exploding! +BULLETS_LIFETIME = 50 --TODO: impl. lifetime for a bullet! + +-- Power up timer +PU_TIMER = 10 -- WIN flags for P1 and P2 P1_WIN = false P2_WIN = false +-- Default speeds for bullets and player +DEFAULT_P_SPEED = 12000 +DEFAULT_B_SPEED = 22000 + -- WIN counts! P1_COUNT = 0 P2_COUNT = 0 diff --git a/game.love b/game.love index 4ce0312c04c664c20353002245c031178809afac..45e2c7cd845d87dae37b380c45eff2584810d32b 100644 GIT binary patch delta 22024 zcmZ_V1zc6zx;X4bcZzg(cZYO$N_V%E^g_D3yCjtEl1}N8ZUmI>hHq~7|L$|{J?F#U zgM-CH8EcL)-gm^D&g_J)TI+-ctH?t^V}U>*c#v+wtF|~>q2M+Y2(*I?0wID3L8k8Z z_7-l;_U2CC=lZ{g@k zHA1jID%Q)qW>q{QlY?OZRTEwIU1gLbN8biLiw|4^laHWc4h;NkKHMhSf9w~8jo$Ot1e~M;;E{#y`2eZz0Ga7pm5B>EOjy0ll= zcAXL!cxTkfQN|ryQRl~n$k>|(-)nmi+h#|b)iu4iX@eKWe>^tVtYa5z>2EX9D99!Ms@q+vNx>9mr5pH3!)uZpsgYAuFKl9?cVK< zewpvCIKmjQG10LPx?3T)32|}dStN7MifQmUzU;jmOpov*odu!ob zNt;Ex{Tv+a;QW&x1h!lZU4U9r8mn7++L}aYDgoD%O!_9yX1qU+sSRq2Jx&&u_${+3 z9sX^Kgqc?VYq>!Son6HfXUp}pA_mU-@V65DM)J)-)OKc^Xa;BTVT8P9HgBBw(3G0V zALy^$KIo&A_D_XF^3r&y?zGg}2A!=>V)am|%o~84m)(kBt%im#?)zkep^LfM#wv4} z8yYv1zYPseOL#}d1zJXTNYuG{a6d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NsZ zkmxOdnSu#7K=A2%z{0p)eem`|7&6?U5Jm?6do!3^i~t|HO^9kC!0F3iLJ$8o;s2B_-y8w-r$G<2H|O|UPQ^4pPERWYxP2Pz z5x5#i)TRN`G!Oa!j-C!Q&R#AIw@3#*!A*t0YtvyYgvdYu9|V#De$0tLps#)~;J^O| Dvz)`4 diff --git a/main.lua b/main.lua index 75141ef..2c01a0e 100644 --- a/main.lua +++ b/main.lua @@ -11,9 +11,11 @@ World:addCollisionClass("Bullet1") World:addCollisionClass("Player2") World:addCollisionClass("Bullet2") World:addCollisionClass("Wall") +World:addCollisionClass("PowerUp") require("gui") - +require("powerups/powerup") +require("powerups/speed") require("restart") require("truncate") require("player") @@ -114,17 +116,10 @@ end function love.load() -- Set a random seed love.math.setRandomSeed(love.timer.getTime()) - -- Figure out the X_SCALE and Y_SCALE local curWidth, curHeight = love.graphics.getDimensions() - - print("------") - print(love.graphics.getDimensions()) - _G.X_SCALE = truncate(curWidth / GAME_WORLD_DIM_WIDTH, 3) _G.Y_SCALE = truncate(curHeight / GAME_WORLD_DIM_HEIGHT, 3) - print("x scale:" .. _G.X_SCALE) - print("y scale:" .. _G.Y_SCALE) --Game values (reset after each load) HEALTH = 3 @@ -135,6 +130,10 @@ function love.load() Bullets1 = {} Bullets2 = {} + --PowerUp stuff + PowerUps = {} + PUTimeToPlace = _G.PU_TIMER + DebugFlag = false EnableKeyPress1 = true KeyPressTime1 = 0 @@ -144,10 +143,9 @@ function love.load() KeyPressTime2 = 0 KeyDelay2 = P2_DELAY - local playerSpeed = 12000 --TODO: two player speeds for upgrades - UserPlayer1 = Player(1, 1000, 100, HEALTH, "assets/player1.png", playerSpeed) - UserPlayer2 = Player(2, 200, 300, HEALTH, "assets/player2.png", playerSpeed) + UserPlayer1 = Player(1, 1000, 100, HEALTH, "assets/player1.png", 12000) + UserPlayer2 = Player(2, 200, 300, HEALTH, "assets/player2.png", 12000) --STI Map loading LoadMap(_G.CUR_LEVEL) diff --git a/player.lua b/player.lua index f88ec4d..079efe9 100644 --- a/player.lua +++ b/player.lua @@ -1,6 +1,7 @@ Player = Object:extend() local cos = math.cos local sin = math.sin --optimisation +local max = math.max --optimisation -- Constructor for the Player class function Player:new(p, x, y, health, image, speed) @@ -10,9 +11,15 @@ function Player:new(p, x, y, health, image, speed) self.y = y self.health = health self.speed = speed + self.bulletSpeed = _G.DEFAULT_B_SPEED self.width = self.image:getWidth() self.height = self.image:getHeight() + --Power up flag + self.PUName = "" + self.PUTime = 0 + self.PUOn = false + -- Collision Stuff --self.collider = World:newRectangleCollider(x, y, 50, 62) self.collider = World:newCircleCollider(x, y, 24 * X_SCALE) @@ -26,7 +33,7 @@ function Player:new(p, x, y, health, image, speed) -- Rotation Stuff self.rotation = math.rad(90) - self.rotSpeed = 2 + self.rotSpeed = 3 --self.scaleX = 1 * _G.X_SCALE --self.scaleY = 1 * _G.Y_SCALE self.scaleX = 1 @@ -86,13 +93,36 @@ function Player:updateCol() end end +function Player:getPowerUp(powerup) + self.PUName = powerup.name + self.PUTime = powerup.time +end + +function Player:powerup() + self.PUOn = true + if self.PUName == "speed" then + --print("" .. self.PUName .. " for " .. self.PUTime) + self.speed = self.speed * 2.5 + self.rotSpeed = self.rotSpeed * 1.5 + end +end + -- Update method for the Player class function Player:update(dt) - local bulletSpeed = 20000 + if self.PUOn then + self.PUTime = self.PUTime - dt + if max(0, self.PUTime) <= 0 then + -- Reset the player + self.PUName = "none" + self.PUTime = 0 + self.PUOn = false + self.speed = _G.DEFAULT_P_SPEED + end + end if EnableKeyPress1 == true and self.p == 1 then if love.keyboard.isDown("space") then - local newBullet = self:shoot(bulletSpeed) + local newBullet = self:shoot(self.bulletSpeed) table.insert(Bullets1, newBullet) KeyPressTime1 = KeyDelay1 EnableKeyPress1 = false @@ -101,7 +131,7 @@ function Player:update(dt) if EnableKeyPress2 == true and self.p == 2 then if love.keyboard.isDown("return") then - local newBullet = self:shoot(bulletSpeed) + local newBullet = self:shoot(self.bulletSpeed) table.insert(Bullets2, newBullet) KeyPressTime2 = KeyDelay2 EnableKeyPress2 = false diff --git a/powerups/powerup.lua b/powerups/powerup.lua new file mode 100644 index 0000000..d510824 --- /dev/null +++ b/powerups/powerup.lua @@ -0,0 +1,70 @@ +PowerUp = Object:extend() + +-- PowerUp is the super class for all power-ups +-- found in the game + +function PowerUp:new(name, x, y, image, time, lifetime) + self.name = name + self.x = x + self.y = y + self.image = love.graphics.newImage(image) + self.time = time + self.lifetime = lifetime + + self.width = self.image:getWidth() + self.height = self.image:getHeight() + + self.rotation = 1 + self.scaleX = 1 + self.scaleY = 1 + self.originX = self.width / 2 + self.originY = self.height / 2 + + -- Collider + self.collider = World:newRectangleCollider(x, y, 20, 20) + self.collider:setCollisionClass("PowerUp") + self.collider:setType("static") + self.collider:setPosition(self.x, self.y) +end +-- TODO: clean up colliosn on reset +-- make image draw +-- more stuff +-- see you later + +function PowerUp:apply(player) end + +function PowerUp:remove(player) end + +function PowerUp:update(dt) + --check if the power up is past its lifetime + + --spinnnnnn + self.rotation = self.rotation + 1.5 * dt + + --grown and shrink + --[[ + if self.scaleX >= 1.0 then + self.scaleX = self.scaleX - 0.2 * dt + elseif self.scaleX <= 1.8 then + self.scaleX = self.scaleX + 0.2 * dt + end + ]] + + self.x = self.collider:getX() + self.y = self.collider:getY() +end + +function PowerUp:draw() + for _, _ in ipairs(PowerUps) do + love.graphics.draw( + self.image, + self.x, + self.y, + self.rotation, + self.scaleX, + self.scaleY, + self.originX, + self.originY + ) + end +end diff --git a/restart.lua b/restart.lua index 4b5cc24..75308e6 100644 --- a/restart.lua +++ b/restart.lua @@ -8,6 +8,12 @@ function ClearWalls(walls) end end +function ClearPowerUps(powerup) + for i, v in ipairs(powerup) do + v.collider:destroy() + end +end + function StopAllMusic() -- TODO: maybe find a way -- to find all 'streaming' @@ -68,5 +74,8 @@ function RestartGame() --Clear Walls ClearWalls(Walls) + --ClearPowerUps + ClearPowerUps(PowerUps) + -- Done! end