Simulating rotating gravity and perimeter based movement like in “Be Brave, Barb” game with Phaser, without any physics engine

HTML5 platformer engine inspired by Be Brave, Barb, built without physics. Hero walks along a dynamically generated perimeter, switches between four gravity directions, and reattaches to surfaces using continuous collision detection. Everything is driven by pure geometry, vector math, and segment intersection.