Skip to content

Commit 1581ad1

Browse files
committed
readme and example fix
1 parent 4a21e84 commit 1581ad1

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

main/main.script

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ local map_width = 5
22
local map_height = 4
33
local direction = astar.DIRECTION_EIGHT
44
local allocate = map_width * map_height
5-
local typical_adjacent = map_width * map_height
5+
local typical_adjacent = 8
66
local cache = true -- Optional. Default is true
77
local use_zero = false -- Optional. Default is false = 1 based
88
local map_vflip = false -- Optional. Default is false
@@ -30,8 +30,6 @@ local entities = {
3030
}
3131

3232
function init(self)
33-
local map_id = astar.new_map_id()
34-
3533
astar.setup(map_width, map_height, direction, allocate, typical_adjacent, cache, use_zero, map_vflip)
3634
astar.set_map(world)
3735
astar.set_costs(costs)

0 commit comments

Comments
 (0)