Work on terminals and machines
This commit is contained in:
@@ -23,7 +23,7 @@ damageSensor
|
||||
-> PlacementSpot -> Placement
|
||||
damageSensor dt wdth upf ps = pContID ps (PutLS $ lsPosCol (V3 0 0 30) 0.1)
|
||||
$ \lsid -> Just $ spNoID ps $ PutUsingGenParams
|
||||
$ \gw -> (,) gw $ PutMachine yellow (reverse $ square wdth) defaultMachine
|
||||
$ \gw -> (,) gw $ PutMachine (reverse $ square wdth) (defaultMachine & mcColor .~ yellow)
|
||||
{ _mcDraw = sensorSPic wdth $ _sensorCoding (_genParams gw) M.! dt
|
||||
, _mcUpdate = \mc -> upf mc . sensorUpdate dt mc
|
||||
, _mcSensor = SensorToggleAmount False 0
|
||||
@@ -54,8 +54,8 @@ damageUsing dt dm
|
||||
| otherwise = Right 0
|
||||
|
||||
sensorSPic :: Float -> (PaletteColor,DecorationShape) -> Machine -> SPic
|
||||
sensorSPic wdth (pc,ds) _ = noPic
|
||||
$ colorSH yellow (upperPrismPoly 25 (square wdth))
|
||||
sensorSPic wdth (pc,ds) mc = noPic
|
||||
$ colorSH (_mcColor mc) (upperPrismPoly 25 (square wdth))
|
||||
<> decorationToShape ds wdth wdth 25 col col
|
||||
where
|
||||
col = paletteToColor pc
|
||||
|
||||
Reference in New Issue
Block a user