我需要改进这段代码,很重,我没有找到另一种方法来创建
所有条件都需要验证,如果条件为真并不重要,必须继续寻找其他条件。
对不起我的英语谷歌翻译
if (skill.getId() == 233 && getActiveClassId() == 55 || getActiveClassId() == 46 || getActiveClassId() == 2 || getActiveClassId() == 3 || getActiveClassId() == 57 || getActiveClassId() == 117 || getActiveClassId() == 113 || getActiveClassId() == 88 || getActiveClassId() == 89 || getActiveClassId() == 118 || getActiveClassId() == 16 || getActiveClassId() == 30 || getActiveClassId() == 17 || getActiveClassId() == 43 || getActiveClassId() == 97 || getActiveClassId() == 105 || getActiveClassId() == 98 || getActiveClassId() == 112 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 116 || getActiveClassId() == 116 || getActiveClassId() == 28 || getActiveClassId() == 41 || getActiveClassId() == 14 || getActiveClassId() == 104 || getActiveClassId() == 111 || getActiveClassId() == 96) {
removeSkillById(233); // Light Armor
} else {
// Nothing...
}
if (skill.getId() == 227 && getActiveClassId() == 36 || getActiveClassId() == 9 || getActiveClassId() == 37 || getActiveClassId() == 23 || getActiveClassId() == 24 || getActiveClassId() == 8 || getActiveClassId() == 48 || getActiveClassId() == 108 || getActiveClassId() == 92 || getActiveClassId() == 109 || getActiveClassId() == 101 || getActiveClassId() == 102 || getActiveClassId() == 93 || getActiveClassId() == 114 || getActiveClassId() == 16 || getActiveClassId() == 30 || getActiveClassId() == 17 || getActiveClassId() == 43 || getActiveClassId() == 97 || getActiveClassId() == 105 || getActiveClassId() == 98 || getActiveClassId() == 112 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116 || getActiveClassId() == 28 || getActiveClassId() == 41 || getActiveClassId() == 14 || getActiveClassId() == 104 || getActiveClassId() == 111 || getActiveClassId() == 96) {
removeSkillById(227); // Light Armor
} else {
// Nothing...
}
if (skill.getId() == 236 && getActiveClassId() == 36 || getActiveClassId() == 9 || getActiveClassId() == 37 || getActiveClassId() == 23 || getActiveClassId() == 24 || getActiveClassId() == 8 || getActiveClassId() == 48 || getActiveClassId() == 108 || getActiveClassId() == 92 || getActiveClassId() == 109 || getActiveClassId() == 101 || getActiveClassId() == 102 || getActiveClassId() == 93 || getActiveClassId() == 114 || getActiveClassId() == 55 || getActiveClassId() == 46 || getActiveClassId() == 2 || getActiveClassId() == 3 || getActiveClassId() == 57 || getActiveClassId() == 117 || getActiveClassId() == 113 || getActiveClassId() == 88 || getActiveClassId() == 89 || getActiveClassId() == 118 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116 || getActiveClassId() == 28 || getActiveClassId() == 41 || getActiveClassId() == 14 || getActiveClassId() == 104 || getActiveClassId() == 111 || getActiveClassId() == 96) {
removeSkillById(236); // Light Armor
} else {
// Nothing...
}
if (skill.getId() == 252 && getActiveClassId() == 36 || getActiveClassId() == 9 || getActiveClassId() == 37 || getActiveClassId() == 23 || getActiveClassId() == 24 || getActiveClassId() == 8 || getActiveClassId() == 48 || getActiveClassId() == 108 || getActiveClassId() == 92 || getActiveClassId() == 109 || getActiveClassId() == 101 || getActiveClassId() == 102 || getActiveClassId() == 93 || getActiveClassId() == 114 || getActiveClassId() == 55 || getActiveClassId() == 46 || getActiveClassId() == 2 || getActiveClassId() == 3 || getActiveClassId() == 57 || getActiveClassId() == 117 || getActiveClassId() == 113 || getActiveClassId() == 88 || getActiveClassId() == 89 || getActiveClassId() == 118 || getActiveClassId() == 16 || getActiveClassId() == 30 || getActiveClassId() == 17 || getActiveClassId() == 43 || getActiveClassId() == 97 || getActiveClassId() == 105 || getActiveClassId() == 98 || getActiveClassId() == 112 || getActiveClassId() == 28 || getActiveClassId() == 41 || getActiveClassId() == 14 || getActiveClassId() == 104 || getActiveClassId() == 111 || getActiveClassId() == 96) {
removeSkillById(252); // Light Armor
} else {
// Nothing...
}
if (skill.getId() == 258 && getActiveClassId() == 36 || getActiveClassId() == 9 || getActiveClassId() == 37 || getActiveClassId() == 23 || getActiveClassId() == 24 || getActiveClassId() == 8 || getActiveClassId() == 48 || getActiveClassId() == 108 || getActiveClassId() == 92 || getActiveClassId() == 109 || getActiveClassId() == 101 || getActiveClassId() == 102 || getActiveClassId() == 93 || getActiveClassId() == 114 || getActiveClassId() == 55 || getActiveClassId() == 46 || getActiveClassId() == 2 || getActiveClassId() == 3 || getActiveClassId() == 57 || getActiveClassId() == 117 || getActiveClassId() == 113 || getActiveClassId() == 88 || getActiveClassId() == 89 || getActiveClassId() == 118 || getActiveClassId() == 16 || getActiveClassId() == 30 || getActiveClassId() == 17 || getActiveClassId() == 43 || getActiveClassId() == 97 || getActiveClassId() == 105 || getActiveClassId() == 98 || getActiveClassId() == 112 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116) {
removeSkillById(258); // Light Armor
} else {
// Nothing...
}
if (skill.getId() == 231 && getActiveClassId() == 6 || getActiveClassId() == 5 || getActiveClassId() == 33 || getActiveClassId() == 20 || getActiveClassId() == 91 || getActiveClassId() == 90 || getActiveClassId() == 106 || getActiveClassId() == 99 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116 || getActiveClassId() == 17 || getActiveClassId() == 98) {
removeSkillById(231); // Heavy Armor
} else {
// Nothing...
}
if (skill.getId() == 232 && getActiveClassId() == 55 || getActiveClassId() == 46 || getActiveClassId() == 2 || getActiveClassId() == 3 || getActiveClassId() == 57 || getActiveClassId() == 117 || getActiveClassId() == 113 || getActiveClassId() == 88 || getActiveClassId() == 89 || getActiveClassId() == 118 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116 || getActiveClassId() == 17 || getActiveClassId() == 98) {
removeSkillById(232); // Heavy Armor
} else {
// Nothing...
}
if (skill.getId() == 253 && getActiveClassId() == 55 || getActiveClassId() == 46 || getActiveClassId() == 2 || getActiveClassId() == 3 || getActiveClassId() == 57 || getActiveClassId() == 117 || getActiveClassId() == 113 || getActiveClassId() == 88 || getActiveClassId() == 89 || getActiveClassId() == 118 || getActiveClassId() == 6 || getActiveClassId() == 5 || getActiveClassId() == 33 || getActiveClassId() == 20 || getActiveClassId() == 91 || getActiveClassId() == 90 || getActiveClassId() == 106 || getActiveClassId() == 99 || getActiveClassId() == 17 || getActiveClassId() == 98) {
removeSkillById(253); // Heavy Armor
} else {
// Nothing...
}
if (skill.getId() == 259 && getActiveClassId() == 55 || getActiveClassId() == 46 || getActiveClassId() == 2 || getActiveClassId() == 3 || getActiveClassId() == 57 || getActiveClassId() == 117 || getActiveClassId() == 113 || getActiveClassId() == 88 || getActiveClassId() == 89 || getActiveClassId() == 118 || getActiveClassId() == 6 || getActiveClassId() == 5 || getActiveClassId() == 33 || getActiveClassId() == 20 || getActiveClassId() == 91 || getActiveClassId() == 90 || getActiveClassId() == 106 || getActiveClassId() == 99 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116) {
removeSkillById(259); // Heavy Armor
} else {
// Nothing...
}
if (skill.getId() == 234 && getActiveClassId() == 16 || getActiveClassId() == 17 || getActiveClassId() == 30 || getActiveClassId() == 43 || getActiveClassId() == 97 || getActiveClassId() == 98 || getActiveClassId() == 105 || getActiveClassId() == 112 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116) {
removeSkillById(234); // Robe Mastery
} else {
// Nothing...
}
if (skill.getId() == 235 && getActiveClassId() == 28 || getActiveClassId() == 13 || getActiveClassId() == 41 || getActiveClassId() == 12 || getActiveClassId() == 40 || getActiveClassId() == 27 || getActiveClassId() == 14 || getActiveClassId() == 104 || getActiveClassId() == 95 || getActiveClassId() == 111 || getActiveClassId() == 94 || getActiveClassId() == 110 || getActiveClassId() == 103 || getActiveClassId() == 96 || getActiveClassId() == 51 || getActiveClassId() == 52 || getActiveClassId() == 115 || getActiveClassId() == 116) {
removeSkillById(235); // Robe Mastery
} else {
// Nothing...
}
if (skill.getId() == 251 && getActiveClassId() == 28 || getActiveClassId() == 13 || getActiveClassId() == 41 || getActiveClassId() == 12 || getActiveClassId() == 40 || getActiveClassId() == 27 || getActiveClassId() == 14 || getActiveClassId() == 104 || getActiveClassId() == 95 || getActiveClassId() == 111 || getActiveClassId() == 94 || getActiveClassId() == 110 || getActiveClassId() == 103 || getActiveClassId() == 96 || getActiveClassId() == 16 || getActiveClassId() == 17 || getActiveClassId() == 30 || getActiveClassId() == 43 || getActiveClassId() == 97 || getActiveClassId() == 98 || getActiveClassId() == 105 || getActiveClassId() == 112) {
removeSkillById(251); // Robe Mastery
} else {
// Nothing...
}
有什么帮助我吗?谢谢!!