Module

Emo8.Game.Draw

Package
purescript-emo8
Repository
opyapeus/purescript-emo8

#Draw Source

type Draw = DrawR DrawContext

Emo8 draw monad which runs some draw operations.

#DrawContext Source

type DrawContext = { canvasSize :: Rect, ctx :: Context2D }

#cls Source

cls :: Color -> Draw Unit

Fill the entire canvas with the specified color.

#emo Source

emo :: Emoji -> Size -> X -> Y -> Draw Unit

Draw the emoji with the specified emoji, size, x and y.

The origin of x and y is the bottom left.

#emo' Source

emo' :: Emoji -> Size -> X -> Y -> Draw Unit

The mirror version of emo.

#emor Source

emor :: Angle -> Emoji -> Size -> X -> Y -> Draw Unit

The rotation version of emo.

#emor' Source

emor' :: Angle -> Emoji -> Size -> X -> Y -> Draw Unit

The mirror version of emor.

#emap Source

emap :: EmojiMap -> Size -> X -> Y -> Draw Unit

Draw the emoji map with the specified emoji map, size, x and y.

The size is one of the emojis'.