예제 #1
0
 public void UpdateResource(UserResInfo newInfo)
 {
     this.oil = newInfo.oil;
     this.steel = newInfo.steel;
     this.ammo = newInfo.ammo;
     this.aluminium = newInfo.aluminium;
     this.gold = newInfo.gold;
 }
 public UserResInfo GetResourceChange(UserResInfo newInfo)
 {
     UserResInfo info = new UserResInfo();
     info.oil = newInfo.oil - this.oil;
     info.ammo = newInfo.ammo - this.ammo;
     info.steel = newInfo.steel - this.steel;
     info.aluminium = newInfo.aluminium - this.aluminium;
     info.gold = newInfo.gold - this.gold;
     return info;
 }
예제 #3
0
 public void UpdateResource(UserResInfo newInfo)
 {
     this.oil = newInfo.oil;
     this.steel = newInfo.steel;
     this.ammo = newInfo.ammo;
     this.aluminium = newInfo.aluminium;
     this.gold = newInfo.gold;
 }
예제 #4
0
 public UserResInfo GetResourceChange(UserResInfo newInfo)
 {
     return new UserResInfo { oil = newInfo.oil - this.oil, ammo = newInfo.ammo - this.ammo, steel = newInfo.steel - this.steel, aluminium = newInfo.aluminium - this.aluminium, gold = newInfo.gold - this.gold };
 }
예제 #5
0
 public UserResInfo GetResourceChange(UserResInfo newInfo)
 {
     return new UserResInfo { oil = newInfo.oil - this.oil, ammo = newInfo.ammo - this.ammo, steel = newInfo.steel - this.steel, aluminium = newInfo.aluminium - this.aluminium, gold = newInfo.gold - this.gold };
 }