public static int TargetWeight(this WoWUnit unit) { if (unit.IsPlayer) { WoWPlayer player = (WoWPlayer)unit; string cs = player.ClassAndSpec(); if (killweights.ContainsKey(cs)) { return(killweights[cs]); } else { return(1); } } if (!FTWProps.MobWeights.ContainsKey(unit.Name)) { return(0); } else { return(FTWProps.MobWeights[unit.Name]); } }