Documentation ¶
Index ¶
Constants ¶
View Source
const ( ErrorVersionNotSupported = "Version \"%s\" not supported" ErrorShapeTypeNotSupported = "Shape type \"%s\" is not supported" ErrorShapeDataNotValid = "Shape data of shape type \"%s\" is not valid" )
Returned errors
View Source
const ( AxisNone = iota AxisX = 1 AxisY = 2 AxisBoth = 3 )
Possible collision axis values
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BoundFile ¶
type BoundFile struct { Version string Bounds map[string]struct { Shapes []struct { Type string Values json.RawMessage } } }
BoundFile is the struct of the JSON file used to store an animated sprite with attached bounding boxes
type Box ¶
Box is a Rect with methods to resolve collisions
func (*Box) Draw ¶
Draw draws the bounding box surface on the passed target with the specified color for debugging purposes
Click to show internal directories.
Click to hide internal directories.