Documentation ¶
Index ¶
- Variables
- func AddImage(name, path string) *sdl.Texture
- func AddMusic(name, dir string) *mix.Music
- func AddSound(name, dir string) *mix.Chunk
- func ClearCanvas()
- func DrawCircle(x, y, r float64)
- func DrawImage(name string, x, y float64, rotation float32, sx, sy float32)
- func DrawLine(x1, y1, x2, y2 float64)
- func DrawRectangle(x, y, w, h float64)
- func EmptyKeyFunc(key string)
- func Float32If(statement bool, t, f float32) float32
- func GetMouseX() int
- func GetMouseY() int
- func GetPathType(p string) string
- func IntIf(statement bool, t, f int) int
- func IsKeyDown(key string) bool
- func IsMouseDown(button string) bool
- func LuaDraw()
- func LuaKeyPressed(key string)
- func LuaKeyReleased(key string)
- func LuaMousePressed(x, y int, button string, clicks int)
- func LuaMouseReleased(x, y int, button string, clicks int)
- func LuaStart()
- func LuaUpdate(dt float32)
- func MouseButtonString(button uint8) string
- func NewCanvas(name string, w, h int) *sdl.Texture
- func NewState(w, h int, name string) state
- func Origin()
- func PlayMusic(name string, loops int)
- func PlaySound(name string, repetitions int) int
- func SetCanvas(c string)
- func SetColor(r, g, b, a int)
- func Start(w, h int, name string)
- func StringIf(statement bool, t, f string) string
- type DrawFunc
- type DrawOperation
- type KeyPressed
- type KeyReleased
- type MousePressed
- type MouseReleased
- type Object
- type UpdateFunc
Constants ¶
This section is empty.
Variables ¶
View Source
var Canvases map[string]*sdl.Texture
Collections
View Source
var CurrentCanvas string
Graphical variables
View Source
var CurrentColor color
View Source
var Event events
View Source
var FPS float32
View Source
var Images map[string]*sdl.Texture
View Source
var KeyState []uint8
View Source
var LuaState *lua.State
View Source
var Music map[string]*mix.Music
View Source
var Renderer *sdl.Renderer
View Source
var Running bool
View Source
var ScaleX float32
View Source
var ScaleY float32
View Source
var Sounds map[string]*mix.Chunk
View Source
var State state
View Source
var TranslateX int
View Source
var TranslateY int
View Source
var Window *sdl.Window
Variables
Functions ¶
func ClearCanvas ¶
func ClearCanvas()
func DrawCircle ¶
func DrawCircle(x, y, r float64)
func DrawRectangle ¶
func DrawRectangle(x, y, w, h float64)
func EmptyKeyFunc ¶
func EmptyKeyFunc(key string)
func GetPathType ¶
func IsMouseDown ¶
func LuaKeyPressed ¶
func LuaKeyPressed(key string)
func LuaKeyReleased ¶
func LuaKeyReleased(key string)
func LuaMousePressed ¶
func LuaMouseReleased ¶
func MouseButtonString ¶
Types ¶
type DrawOperation ¶
type DrawOperation struct {
// contains filtered or unexported fields
}
type KeyPressed ¶
type KeyPressed func(string) // <---- Key
type KeyReleased ¶
type KeyReleased func(string) // <---- Key
type MousePressed ¶
type MouseReleased ¶
type UpdateFunc ¶
type UpdateFunc func(float32) // <----- dt (Time)
Declaring event function types, setting default functions and putting them in burrito.Event.EventName fashion...
Click to show internal directories.
Click to hide internal directories.