Move machine destruction to external function

This commit is contained in:
2022-07-14 12:48:52 +01:00
parent 79791d0df2
commit f05d284312
7 changed files with 57 additions and 23 deletions
+1 -2
View File
@@ -181,7 +181,6 @@ defaultMachine = Machine
{ _mcID = 0
, _mcWallIDs = mempty
, _mcUpdate = defaultMachineUpdate
, _mcDeath = const id
, _mcApplyDamage = \_ _ -> id
, _mcDraw = const mempty
, _mcColor = white
@@ -193,7 +192,7 @@ defaultMachine = Machine
, _mcLSs = []
, _mcType = StaticMachine
, _mcName = ""
, _mcTermMID = Nothing
, _mcMounts = mempty
}
defaultMachineUpdate :: Machine -> World -> World
defaultMachineUpdate mc