mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-24 10:48:53 +01:00
examples/sprites: Update only shown sprites
This commit is contained in:
parent
12287a8382
commit
5680ce7f46
@ -79,8 +79,8 @@ type Sprites struct {
|
||||
}
|
||||
|
||||
func (s *Sprites) Update() {
|
||||
for _, sprite := range s.sprites {
|
||||
sprite.Update()
|
||||
for i := 0; i < s.num; i++ {
|
||||
s.sprites[i].Update()
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user