private void ApplyAnimation(Item sItem)
{
if (sItem.melee)
{
this.itemAnimation = (int)((double)sItem.useAnimation * (double)this.meleeSpeed);
this.itemAnimationMax = (int)((double)sItem.useAnimation * (double)this.meleeSpeed);
}
else if (sItem.createTile >= 0)
{
this.itemAnimation = (int)((double)sItem.useAnimation * (double)this.tileSpeed);
this.itemAnimationMax = (int)((double)sItem.useAnimation * (double)this.tileSpeed);
}
else if (sItem.createWall >= 0)
{
this.itemAnimation = (int)((double)sItem.useAnimation * (double)this.wallSpeed);
this.itemAnimationMax = (int)((double)sItem.useAnimation * (double)this.wallSpeed);
}
else
{
this.itemAnimation = sItem.useAnimation;
this.itemAnimationMax = sItem.useAnimation;
this.reuseDelay = sItem.reuseDelay;
}
}