Remove wall corner collision test for creatures
This commit is contained in:
+1
-2
@@ -34,7 +34,6 @@ import qualified Data.Map as M
|
||||
import Control.Lens
|
||||
import Data.Monoid
|
||||
import System.Random
|
||||
--import Data.Bifunctor
|
||||
|
||||
update :: World -> World
|
||||
update = (frameClock +~ 1) . functionalUpdate
|
||||
@@ -200,7 +199,7 @@ updateCloud w c
|
||||
newPos@(V3 _ _ npz) = oldPos +.+.+ newVel
|
||||
newPos2 = stripZ newPos
|
||||
-- the following only tests for the first collision with a wall
|
||||
hitWl = collidePointAnyWalls oldPos2 newPos2 $ wallsNearPoint newPos2 w
|
||||
hitWl = collidePointAnyWallsReflect oldPos2 newPos2 $ wallsNearPoint newPos2 w
|
||||
finalPos = addZ npz $ maybe newPos2 fst hitWl
|
||||
finalVel = addZ nvz $ maybe newVel2 snd hitWl
|
||||
|
||||
|
||||
Reference in New Issue
Block a user