From cc1dd4fec213dcb72839d8720d760d9545278288 Mon Sep 17 00:00:00 2001 From: Top Cat Date: Mon, 16 Dec 2013 04:24:01 +0000 Subject: [PATCH 1/2] Remove TODO, update backstory to explain the lack of mech --- README.md | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/README.md b/README.md index ba92d46..2cb7c17 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ You Only Get Juan =========== -You play as Juan, a mech soldier person thing. You find yourself in a time loop that forces you to cross your own time line. +You play as Juan, a owl ninja person thing. You find yourself in a time loop that forces you to cross your own time line. You must protect your past self in order to survive to the present. @@ -11,12 +11,3 @@ YOGJ uses the [love2d](http://love2d.org/) library for drawing. Once installed simply run: > love path/to/game - -## TODO -* Health Bar / Text -* Time Bar / Text -* Victory Screen -* Balance - * Enemy spawning - * Time travel period -* Levels? From 47920e58f61c7f8735aa7d0d757d33d03edaf966 Mon Sep 17 00:00:00 2001 From: Michael Walker Date: Mon, 16 Dec 2013 04:27:41 +0000 Subject: [PATCH 2/2] Debug mode --- constants.lua | 3 +++ entity/entity.lua | 4 +--- entity/player.lua | 6 ++++++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/constants.lua b/constants.lua index 60d9995..4fb2984 100755 --- a/constants.lua +++ b/constants.lua @@ -1,5 +1,8 @@ constants = {} +-- Debug mode: show hitboxes, and have lots of health +constants.debug = true + constants.playTime = 160 constants.jumpTime = 100 constants.framerate = 30 diff --git a/entity/entity.lua b/entity/entity.lua index e7c9cef..d322b1b 100755 --- a/entity/entity.lua +++ b/entity/entity.lua @@ -18,8 +18,6 @@ Entity.dy = 0 Entity.ghosted = false Entity.orientation = 1 -Entity.static.debugHitboxes = false - function Entity:initialize(id, x, y, sprite, collider) self.id = id self.x = x @@ -63,7 +61,7 @@ end function Entity:draw(vx, vy) self.sprite:draw(self.x - vx, self.y - vy, self.orientation) - if self.class.debugHitboxes then + if constants.debug then x1, y1, x2, y2 = self.hitbox:bbox() x1 = x1 - vx diff --git a/entity/player.lua b/entity/player.lua index 4116cde..c973d34 100755 --- a/entity/player.lua +++ b/entity/player.lua @@ -3,6 +3,7 @@ local class = require 'middleclass.middleclass' require 'entity.mob' require 'drawable.drawable' require 'utils' +require 'constants' local highestiteration = 0 @@ -18,6 +19,11 @@ function Player:initialize(id, x, y, collider, orientation) self.iteration = highestiteration self.orientation = orientation self.canJump = true + + if constants.debug then + self.maxHealth = 999999999999999999999999999 + self.health = self.maxHealth + end end function Player:isCurrentPlayer()