linter stuff
parent
06bd0cfd12
commit
2e0ac84163
|
@ -17,10 +17,9 @@ type PhysicalObject interface {
|
||||||
// the viewport for the part of the screen to draw to (splitscreen support),
|
// the viewport for the part of the screen to draw to (splitscreen support),
|
||||||
// as well as the entity the player is currently controlling.
|
// as well as the entity the player is currently controlling.
|
||||||
type player struct {
|
type player struct {
|
||||||
ctx context.Context
|
|
||||||
timeout time.Duration
|
|
||||||
|
|
||||||
controlledObject PhysicalObject
|
controlledObject PhysicalObject
|
||||||
|
ctx context.Context
|
||||||
|
timeout time.Duration
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewPlayer(ctx context.Context) *player {
|
func NewPlayer(ctx context.Context) *player {
|
||||||
|
|
|
@ -39,14 +39,10 @@ func (s *spritesheet) Draw(
|
||||||
color rl.Color,
|
color rl.Color,
|
||||||
) error {
|
) error {
|
||||||
|
|
||||||
var err error
|
|
||||||
channels.RL.Do(func() {
|
channels.RL.Do(func() {
|
||||||
origin := rl.Vector2{}
|
origin := rl.Vector2{}
|
||||||
rl.DrawTexturePro(s.texture, section, placement, origin, angle, color)
|
rl.DrawTexturePro(s.texture, section, placement, origin, angle, color)
|
||||||
})
|
})
|
||||||
if err != nil {
|
|
||||||
return err
|
|
||||||
}
|
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue