mirror of https://github.com/OpenTTD/OpenTTD.git
(svn r4649) - NewGRF: limit helicopter rotor animation frames to the number of sprites in the set.
This commit is contained in:
parent
9482534f5e
commit
8d5d386e77
|
@ -729,7 +729,7 @@ SpriteID GetRotorOverrideSprite(EngineID engine, const Vehicle *v)
|
||||||
|
|
||||||
if (v == NULL) return group->g.result.sprite;
|
if (v == NULL) return group->g.result.sprite;
|
||||||
|
|
||||||
return group->g.result.sprite + v->next->next->u.air.state;
|
return group->g.result.sprite + (v->next->next->u.air.state % group->g.result.num_sprites);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue