Draw barrels properly
This commit is contained in:
@@ -37,21 +37,26 @@ worldSPic cfig u =
|
||||
pointIsClose = cullPoint cfig w
|
||||
|
||||
drawCreature :: Creature -> SPic
|
||||
drawCreature cr = case _crType cr of
|
||||
BarrelCrit{} ->
|
||||
picAtCrPos1
|
||||
( setDepth 20 $
|
||||
fold
|
||||
[ color orange $ circleSolid 10
|
||||
, setDepth 0.049 . color (greyN 0.5) $ circleSolid 8
|
||||
, color (greyN 0.5) $ circleSolid 8
|
||||
]
|
||||
)
|
||||
cr
|
||||
drawCreature cr = case cr ^. crType of
|
||||
BarrelCrit{} ->
|
||||
uncurryV translateSPxy (_crPos cr) $ rotateSP (_crDir cr)
|
||||
$ barrelShape
|
||||
-- picAtCrPos1
|
||||
-- ( setDepth 20 $
|
||||
-- fold
|
||||
-- [ color orange $ circleSolid 10
|
||||
-- , setDepth 0.049 . color (greyN 0.5) $ circleSolid 8
|
||||
-- , color (greyN 0.5) $ circleSolid 8
|
||||
-- ]
|
||||
-- )
|
||||
-- cr
|
||||
LampCrit{_lampHeight = h} -> uncurryV translateSPxy (_crPos cr) $ lampCrSPic h
|
||||
_ -> basicCrPict cr
|
||||
-- NonDrawnCreature -> mempty
|
||||
|
||||
barrelShape :: SPic
|
||||
barrelShape = noPic $ upperPrismPoly Medium Important 20 $ polyCirc 3 10
|
||||
|
||||
lampCrSPic :: Float -> SPic
|
||||
lampCrSPic h =
|
||||
colorSH blue (upperBox Small Typical h $ rectWH 5 5)
|
||||
|
||||
Reference in New Issue
Block a user