Ejemplo n.º 1
0
 ///Enter each field, -1 sets the stat to its default value
 public Monster(int size, int jump_dist, float base_accel, float accel_incr, int accel_delay, int delay, Monster_Type m)
 {
     if (size != -1)
     {
         this.size = size;
     }
     if (jump_dist != -1)
     {
         this.jump_distance = jump_dist;
     }
     if (base_accel != -1)
     {
         this.base_acceleration  = base_accel;
         this.total_acceleration = base_accel;
     }
     if (accel_delay != -1)
     {
         this.acceleration_delay        = accel_delay;
         this.acceleration_delay_backup = accel_delay;
     }
     if (accel_incr != -1)
     {
         this.acceleration_increment = accel_incr;
     }
     if (delay != -1)
     {
         this.delay        = delay;
         this.delay_backup = delay;
     }
     type = m;
     if (type != Monster_Type.Normal)
     {
         special = true;
     }
 }
Ejemplo n.º 2
0
 public Monster(Monster_Type m)
 {
     type = m;
     if (type != Monster_Type.Normal)
     {
         special = true;
     }
 }
Ejemplo n.º 3
0
 public Electric(string name, int hP, int damage, int lvl, Monster_Type type, int gold)
 {
     this.name   = name;
     this.hP     = hP;
     this.damage = damage;
     this.lvl    = lvl;
     this.type   = type;
     CurrentHP   = HP;
     this.gold   = gold;
 }
Ejemplo n.º 4
0
    public void Set_Monster(Monster_Type _Type, BigInteger m_hp)
    {
        monster_Type = _Type;

        transform.localScale = _Type == Monster_Type.Basic ? Vector3.one : Vector3.one * 1.3f;

        total_Hp = hp = m_hp;

        slider_Hp.value = 1;
    }
 private bool monster_in_family(Monster_Family m_family, Monster_Type m_type)
 {
     for (int i = 0; i < monster_family_assocs.Count; i++)
         if (monster_family_assocs[i].Key == m_family &&
            monster_family_assocs[i].Value == m_type)
             return true;
     return false;
 }