Separate out concrete part of world

This commit is contained in:
2022-07-25 12:10:50 +01:00
parent 3354d108be
commit b2efbd2b3e
134 changed files with 933 additions and 930 deletions
+2 -2
View File
@@ -92,7 +92,7 @@ chooseMovementSpreadGun cr w
where
d = dist cpos p
cpos = _crPos cr
tcr = _creatures w IM.! 0
tcr = _creatures (_cWorld w) IM.! 0
p = _crPos tcr
chooseMovementLtAuto :: Creature -> World -> Action
@@ -105,7 +105,7 @@ chooseMovementLtAuto cr w
= DoImpulses [UseItem,TurnToward p' 0.05, Move (V2 0 3)]
where
cpos = _crPos cr
tcr = _creatures w IM.! 0
tcr = _creatures (_cWorld w) IM.! 0
p = _crPos tcr
v = vNormal $ p -.- cpos
p' = p +.+ 0.5 *.* (v -.- 20 *.* normalizeV v)