public static Rectangle GetSprite(int cmdcount, GameData.Owner color) { SpriteSheetCommandSlot result = SpriteSheetCommandSlot.oneslotblue; if (color == GameData.Owner.Red) { switch (cmdcount) { case 1: result = SpriteSheetCommandSlot.oneslotblue; break; case 2: result = SpriteSheetCommandSlot.twoslotblue; break; case 3: result = SpriteSheetCommandSlot.threeslotblue; break; default: break; } } if (color == GameData.Owner.Blue) { switch (cmdcount) { case 1: result = SpriteSheetCommandSlot.oneslotred; break; case 2: result = SpriteSheetCommandSlot.twoslotred; break; case 3: result = SpriteSheetCommandSlot.threeslotred; break; default: break; } } return(CommandSlotSprite[result]); }
public static Rectangle GetSprite(SpriteSheetCommandSlot t) { return(CommandSlotSprite[t]); }