disable collision to fix pathfinding phasing through walls
This commit is contained in:
@@ -52,6 +52,14 @@ app.listen(port, () => {
|
||||
entity2.radius = 50
|
||||
game.spawn_entity(entity2)
|
||||
|
||||
// const triangle = new Terrain([
|
||||
// { x: 400, y: 200 },
|
||||
// { x: 400, y: 600 },
|
||||
// { x: 600, y: 300 },
|
||||
// ])
|
||||
// triangle.id = 'triangle'
|
||||
// game.add_terrain(triangle)
|
||||
|
||||
const horseshoe = new Terrain([
|
||||
{ x: 400, y: 200 },
|
||||
{ x: 600, y: 200 },
|
||||
@@ -107,5 +115,7 @@ app.listen(port, () => {
|
||||
pole.id = 'pole'
|
||||
game.add_terrain(pole)
|
||||
|
||||
entity1.moveAction(entity1.x + 600, entity1.y)
|
||||
|
||||
game.start()
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user