Simplifying(?) some of the render stuff.

This commit is contained in:
Bob
2009-12-22 02:14:42 +13:00
parent 0413de89db
commit 86dc6d53e7
10 changed files with 114 additions and 93 deletions

View File

@@ -1,13 +1,17 @@

using System;
namespace OpenRa.Game.Traits
{
class RenderBuildingOre : RenderBuilding
class RenderBuildingOre : RenderBuilding, INotifyBuildComplete
{
public RenderBuildingOre(Actor self)
: base(self)
{
Make( () => anim.PlayFetchIndex("idle",
() => (int)(4.9 * self.Owner.GetSiloFullness())), self); /* hack */
}
public void BuildingComplete( Actor self )
{
anim.PlayFetchIndex( "idle", () => (int)( 4.9 * self.Owner.GetSiloFullness() ) );
}
}
}