Improve visuals
This commit is contained in:
+13
-11
@@ -595,28 +595,30 @@ mvGenBullet' w bt
|
||||
wth = _btWidth' bt
|
||||
t = _btTimer' bt
|
||||
|
||||
bulLine :: Color -> Float -> [Point2] -> Drawing
|
||||
bulLine _ _ [] = blank
|
||||
bulLine _ _ (x:[]) = blank
|
||||
bulLine col width (a:b:[]) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures
|
||||
bulLine c w = setLayer 2 . bulLinea c w
|
||||
|
||||
bulLinea :: Color -> Float -> [Point2] -> Picture
|
||||
bulLinea _ _ [] = blank
|
||||
bulLinea _ _ (x:[]) = blank
|
||||
bulLinea col width (a:b:[]) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures $ reverse
|
||||
[polygonCol $ zip (wedgeGeom width b a) $ [white,withAlpha 0 white,withAlpha 0 white]
|
||||
,polygonCol $ zip (lineGeom (width+1.5) a b) $ [col,col,withAlpha 0 col,withAlpha 0 col]
|
||||
]
|
||||
bulLine col width (a:b:c:[]) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures
|
||||
bulLinea col width (a:b:c:[]) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures $ reverse
|
||||
[polygonCol $ zip (wedgeGeom width b a) $ repeat white
|
||||
,polygonCol $ zip (wedgeGeom width b c) $ [white,white,withAlpha 0 white]
|
||||
,polygonCol $ zip (lineGeom (width+1.5) a c) $ [col,col,withAlpha 0 col,withAlpha 0 col]
|
||||
]
|
||||
bulLine col width (a:b:_:c:[]) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures
|
||||
bulLinea col width (a:b:_:c:[]) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures $ reverse
|
||||
[polygonCol $ zip (wedgeGeom width b a) $ repeat white
|
||||
,polygonCol $ zip (wedgeGeom width b c) $ [white,white,withAlpha 0 white]
|
||||
,polygonCol $ zip (lineGeom (width+1.5) a c) $ [col,col,withAlpha 0 col,withAlpha 0 col]
|
||||
]
|
||||
bulLine col width (a:b:_:_:c:_) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures
|
||||
bulLinea col width (a:b:_:_:c:_) -- (a:b:[])
|
||||
= onLayer HPtLayer $ pictures $ reverse
|
||||
[polygonCol $ zip (wedgeGeom width b a) $ repeat white
|
||||
,polygonCol $ zip (wedgeGeom width b c) $ [white,white,withAlpha 0 white]
|
||||
,polygonCol $ zip (lineGeom (width+1.5) a c) $ [col,col,withAlpha 0 col,withAlpha 0 col]
|
||||
|
||||
Reference in New Issue
Block a user