bump chec~~
This commit is contained in:
parent
0009355d04
commit
1c1ec291a7
153 changed files with 27 additions and 8 deletions
13
room.lua
13
room.lua
|
|
@ -62,7 +62,7 @@ function Room:initialize(t)
|
|||
-- if active then self.collideables[color]["n: " .. x .. ", " .. y] = Ass:new(x, y, color, "animals/processed/", "me_rach") end
|
||||
|
||||
local x, y = 1, 1
|
||||
if active then self.collideables[color]["n: " .. x .. ", " .. y] = Ass:new(x, y, color, "tech/processed/", "mac_smaller") end
|
||||
if active then self.collideables[color]["n: " .. x .. ", " .. y] = Ass:new(x, y, color, "nature/", "palm_scaled_reduced") end
|
||||
self.collideables[color]["n: " .. x .. ", " .. y]:getOccupiedCells()
|
||||
|
||||
-- local x, y = 7, 7
|
||||
|
|
@ -168,9 +168,18 @@ function Room:movePlayer(key)
|
|||
x = pos.x + dir.x, y = pos.y + dir.y
|
||||
} -- this is for reference for each color as we change the targetCells table
|
||||
|
||||
local initialTargetEntities = {}
|
||||
|
||||
for _, color in pairs(self:getActiveColors()) do
|
||||
initialTargetEntities[color] = self:getCellInMatrix(self.collidableMatrices[color], initialTargetCell)
|
||||
if initialTargetEntities[color] then initialTargetEntities[color]:bump() print(bump) end
|
||||
end
|
||||
|
||||
if not self:isInBounds(initialTargetCell) then
|
||||
-- let's us move out of bounds to Change Rooms without pulling a bloc_
|
||||
move = true
|
||||
elseif self:getCellInMatrix(self.collidableMatrices["red"], initialTargetCell) and self:getCellInMatrix(self.collidableMatrices["red"], initialTargetCell):canPassOver() then
|
||||
elseif initialTargetEntities["red"] and initialTargetEntities["red"]:canPassOver() then
|
||||
--we should put this in the else statement actually
|
||||
move = true
|
||||
else
|
||||
local targetCells
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue