예제 #1
0
 public StackButton(Texture2D texture, Player p, SpriteBatch sBatch, Thing t, Tile hex, int width, int height, int x, int y)
     : base(texture, sBatch, width, height, x, y)
 {
     image = texture;
     thingsInStack = new List<Thing>(10);
     thingsInStack.Add(t);
     hexStackIsOn = hex;
     owner = p;
 }
예제 #2
0
 public ThingButton(Texture2D texture, Player p, SpriteBatch sBatch, Thing t, int width, int height, int x, int y)
     : base(texture, sBatch, width, height, x, y)
 {
     owner = p;
     buttonID = t.getID();
     thingOnButton = t;
     thingOnButton.setOwned();
     owner.AddThingToRack(buttonID, t);
     thingSelected = false;
     isInPlay = false;
     originalPosition = location;
 }
예제 #3
0
 public void addThings(Thing t)
 {
     if ( canAddToStack() )
         thingsInStack.Add(t);
 }
예제 #4
0
 private void removeFromCup(Thing t)
 {
     cup.Remove(t);
 }
예제 #5
0
 private void removeFromBank(string type, Thing t)
 {
     bank[type].Remove(t);
 }
예제 #6
0
파일: Player.cs 프로젝트: ZEP-Arter/KNT
 public void AddThingToRack(int id, Thing thing)
 {
     rack.Add(id, thing);
 }
예제 #7
0
파일: KNT_Game.cs 프로젝트: ZEP-Arter/KNT
 public static StackButton createStack(Tile hex, Thing t, SpriteBatch s)
 {
     StackButton stackB = new StackButton(stackTexture, me, s, t, hex, 30, 30, 0, 0);
     StackButtons.Add(stackB);
     return stackB;
 }
예제 #8
0
파일: Tile.cs 프로젝트: ZEP-Arter/KNT
 public void addToPlayerStack(int i, Thing thing)
 {
     if (stacks.ContainsKey(i))
         stacks[i].Add(thing);
     else
     {
         List<Thing> temp = new List<Thing>();
         temp.Add(thing);
         stacks.Add(i, temp);
     }
 }