Documentation
¶
Index ¶
- func GetAnimationFrame(sheet coldbrew.Sprite, anim blueprintclient.AnimationData, frameIndex int, ...) *ebiten.Image
- func RenderBackground(backgroundSprite coldbrew.Sprite, position vector.Two, ...)
- func RenderEntity(position vector.Two, rotation float64, scale vector.Two, ...)
- func RenderEntityFromCursor(cursor *warehouse.Cursor, cam coldbrew.Camera, currentTick int)
- func RenderSprite(sprite coldbrew.Sprite, position vector.Two, rotation float64, ...)
- func RenderSpriteSheetAnimation(sheet coldbrew.Sprite, spriteBlueprint *blueprintclient.SpriteBlueprint, ...)
- func RenderTiles(sprite coldbrew.Sprite, blueprint *blueprintclient.SpriteBlueprint, ...)
- type DebugRenderer
- type GlobalRenderer
- type RenderItem
- type ShapeInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAnimationFrame ¶
func GetAnimationFrame(sheet coldbrew.Sprite, anim blueprintclient.AnimationData, frameIndex int, logger *slog.Logger) *ebiten.Image
GetAnimationFrame extracts a single frame from a sprite sheet based on animation data
func RenderBackground ¶
func RenderBackground( backgroundSprite coldbrew.Sprite, position vector.Two, bgConfig *blueprintclient.ParallaxBackground, cam coldbrew.Camera, sceneWidth int, )
RenderBackground draws a parallax background with proper scrolling behavior
func RenderEntity ¶
func RenderEntity( position vector.Two, rotation float64, scale vector.Two, direction blueprintspatial.Direction, spr coldbrew.Sprite, blueprint *blueprintclient.SpriteBlueprint, cam coldbrew.Camera, currentTick int, )
RenderEntity draws a single entity with all its transformations applied
func RenderEntityFromCursor ¶
RenderEntityFromCursor renders an entity directly from a warehouse cursor
func RenderSprite ¶
func RenderSprite( sprite coldbrew.Sprite, position vector.Two, rotation float64, scale vector.Two, offset vector.Two, direction blueprintspatial.Direction, static bool, cam coldbrew.Camera, )
RenderSprite draws a static sprite with transformations applied
func RenderSpriteSheetAnimation ¶
func RenderSpriteSheetAnimation( sheet coldbrew.Sprite, spriteBlueprint *blueprintclient.SpriteBlueprint, index int, position vector.Two, rotation float64, scale vector.Two, direction blueprintspatial.Direction, offset vector.Two, static bool, cam coldbrew.Camera, tick int, logger *slog.Logger, )
RenderSpriteSheetAnimation draws an animated sprite with proper frame selection
func RenderTiles ¶
func RenderTiles( sprite coldbrew.Sprite, blueprint *blueprintclient.SpriteBlueprint, entityPosition vector.Two, direction blueprintspatial.Direction, rotation blueprintspatial.Rotation, scale vector.Two, cam coldbrew.Camera, )
RenderTiles draws tiles from a tileset
Types ¶
type DebugRenderer ¶
type DebugRenderer struct{}
DebugRenderer visualizes physics and collisions for debugging purposes It operates independently from actual collision processing systems A messy expensive system...a temporary solution for now
type GlobalRenderer ¶
type GlobalRenderer struct {
// contains filtered or unexported fields
}
GlobalRenderer is the default render system for the coldbrew package It automatically handles sprites, sprite sheets, tiles, and parallax backgrounds
type RenderItem ¶
type RenderItem struct {
// contains filtered or unexported fields
}
RenderItem contains all state needed for rendering an entity