Change animations to use the proper SequenceProvider
Remove references to the global "Game" and use the SequenceProvider of the current world/map.
This commit is contained in:
@@ -40,7 +40,7 @@ namespace OpenRA.Mods.RA.Effects
|
||||
pos = args.Source;
|
||||
velocity = new WVec(WRange.Zero, WRange.Zero, -info.Velocity);
|
||||
|
||||
anim = new Animation(info.Image);
|
||||
anim = new Animation(args.SourceActor.World, info.Image);
|
||||
if (anim.HasSequence("open"))
|
||||
anim.PlayThen("open", () => anim.PlayRepeating("idle"));
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user