From fe21cb61e3eba9e100450490b692af6cd26cd98f Mon Sep 17 00:00:00 2001 From: 0x81c Date: Thu, 12 Mar 2015 05:21:24 -0400 Subject: [PATCH] basic stuff w movemet n collision done --- room.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/room.lua b/room.lua index 70ccb3c..1340adf 100644 --- a/room.lua +++ b/room.lua @@ -137,6 +137,8 @@ function Room:getAdjacentEntities(entities, pos, axis, direction) end end) + shallowTablePrint(t) + return t end @@ -164,10 +166,11 @@ function Room:tryPlayerMove(entities, pos, axis, direction) for _, entity in ipairs(entities) do pos[axis] = pos[axis] + direction if entity:atGridPos(pos.x, pos.y) then - print("HOW????") + print("HOW????" .. entity) if entity:canMove() then table.insert(entitiesToMove, entity) else + print(entity) return false end else