public bool CheckSkills(Mobile from, Type typeRes, CraftSystem craftSystem, ref int mark, ref double quality, ref int craftSkill, ref bool allRequiredSkills, bool gainSkills) { var craftSkillRequired = GetCraftSkillRequired(from, typeRes, craftSystem); var exceptionalDifficulty = craftSkillRequired; var points = gainSkills ? GetCraftPoints(from, typeRes, craftSystem) : 0; var exceptionalChance = GetExceptionalChance(from, craftSystem, ref exceptionalDifficulty); var resource = CraftResources.GetFromType(typeRes); var resQuality = CraftResources.GetQuality(resource); craftSkill = craftSkillRequired; quality = resQuality; if (exceptionalChance > Utility.Random(100) && from.ShilCheckSkill(craftSystem.MainSkill, exceptionalDifficulty, 0)) { mark = 2; quality = (double)(int)(quality * GetQualityBonus(from)) / 100; } return(from.ShilCheckSkill(craftSystem.MainSkill, craftSkillRequired, points)); }