i know we can,t use pathfind in a infinite map ,but how to use pathfind in a rect outside layout
Develop games in your browser. Powerful, performant & highly capable.
One workaround would be to move your object positions of interest into the layout bounds.
Basically move the world around the player, rather than moving the player.