Exemple #1
0
		internal void BuyBuild(SlotAddr addr, Build build)
		{
			Islands[addr.islandID].BuyBuild(addr.slotID, build);

			if (OnBuyBuild != null)
				OnBuyBuild(addr, build);
		}
Exemple #2
0
		internal void DestroyBuild(SlotAddr addr, bool gigant = false)
		{
			Islands[addr.islandID].BuyBuild(addr.slotID, Build.None);

			if (OnDestroyBuild != null)
				OnDestroyBuild(addr, gigant);
		}
Exemple #3
0
		public bool IsAddrExist(SlotAddr addr)
		{
			if (addr.islandID < 0 || addr.islandID >= Islands.Count)
				return false;

			IslandCM island = Islands[addr.islandID];
			if (addr.slotID < 0 || addr.slotID >= island.Size)
				return false;

			if (island.HasMetro && addr.slotID < IslandCM.IslandMetroSizeByIslandSize(island.Size))
				return false;

			return true;
		}
Exemple #4
0
		public Build GetBuild(SlotAddr addr)
		{
			return Islands[addr.islandID].Slots[addr.slotID];
		}
Exemple #5
0
		public UseCardGig() : base() { } //JSON Constructor

		public UseCardGig(SlotAddr addr) 
			: base() 
		{
			this.addr = addr;
		}
Exemple #6
0
		public BuyBuild() : base() { } //JSON Constructor

		public BuyBuild(SlotAddr addr) 
			: base()
		{
			this.addr = addr;
		}
Exemple #7
0
		public UseCardCyc() : base() { } //JSON Constructor

		public UseCardCyc(SlotAddr addr, Build build) 
			: base() 
		{
			this.addr = addr;
			this.build = build;
		}