What I want to do is have a player sprite be able to freely move around specifically on this platform in a top-down game. However, it would have no way of escaping the platform or moving off of it.
What I have so far is code that enables the sprite to be controlled via the 8-direction arrow keys as long as its on the platform. If it tries to move off, some other code is supposed to reverse its movement the moment the sprite isn't colliding with the platform.
However, I came across the problem of the sprite still slowly moving off of the platform anyway.
Can anyone give me some pointers?