Beispiel #1
0
 public BattlePokemon(Pokemon p)
 {
     this.mon      = p;
     maxHealth     = mon.getRealStat("hp");
     currentHealth = maxHealth;
     status        = Status.STATE_HEALTHY;
     currentBoosts = new Boosts();
     type1         = mon.type1;
     type2         = mon.type2;
     item          = mon.item;
     level         = 100; //Assume max level
     initBoosts();
     canUseFakeout = true;
     hasUsedHazard = false;
 }
Beispiel #2
0
 public Move(MoveJSONObj obj)
 {
     name         = obj.name;
     type         = Global.types[obj.type.ToLower()];
     bp           = obj.basePower;
     accuracy     = ((float)obj.accuracy / 100f);
     group        = obj.category.ToLower();
     priority     = obj.priority;
     boosts       = obj.boosts;
     desc         = obj.desc;
     statuseffect = obj.status;
     secondary    = obj.secondary;
     if (obj.sideCondition != "none")
     {
         field = true;                              //Hazard moves
     }
     if (obj.isZ != "false")
     {
         isZ = true;
         bp  = 100; //for now just set bp to a high value to encourage usage --otherwise endlessly switches.
     }
     if (statuseffect != "none")
     {
         status = true;
     }
     if (hasBoosts())
     {
         isBoost = true;
     }
     if (Convert.ToBoolean(obj.flags.heal))
     {
         heal = true;
     }
     if (!Object.Equals(obj.flags, null))
     {
         flags = obj.flags;
     }
 }