From de22c2fffec714faf58a77711d37547b338aad61 Mon Sep 17 00:00:00 2001 From: nek0 Date: Wed, 20 Jan 2021 05:20:56 +0100 Subject: [PATCH] zero allmovement in collision direction --- src/Types/Player.hs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/Types/Player.hs b/src/Types/Player.hs index 1bad130..1868780 100644 --- a/src/Types/Player.hs +++ b/src/Types/Player.hs @@ -166,5 +166,13 @@ instance Collidible Pituicat where if dirx /= 0 then V2 0 1 else V2 1 1 + , pcTMoveVel = pcTMoveVel ncat * + if dirx /= 0 + then V2 0 1 + else V2 1 1 + , pcVel = pcVel ncat * + if dirx /= 0 + then V2 0 1 + else V2 1 1 } )