スキル一括取得

/L2J_JP/java/net/sf/l2j/gameserver/model/actor/instance/L2FolkInstance.java

 

public void onBypassFeedback(L2PcInstance player, String command)内に追加

 

最後の方に追加(226行)
//[ALL Skill get start]-------------------ここから
else if (command.startsWith("AlumpSkill"))
{
player.setSkillLearningClassId(player.getClassId());
getAlumpSkill(player);
}
// [ALL Skill get end]--------------------ここまで追加
else 
{
// this class dont know any other commands, let forward
// the command to the parent class
super.onBypassFeedback(player, command);
}
}

 

適当な場所に下記内容追加(GMコマンドの応用)
//----------------------------------------------------------------
// [ALL Skill get start] GM comand
public void getAlumpSkill(L2PcInstance player)
{
boolean countUnlearnable = true;
int unLearnable = 0;
int skillCounter = 0;
L2SkillLearn[] skills = SkillTreeTable.getInstance().getAvailableSkills(player, player.getClassId());
while(skills.length > unLearnable)
{
for (L2SkillLearn s : skills)
{
L2Skill sk = SkillTable.getInstance().getInfo(s.getId(), s.getLevel());
if (sk == null || !sk.getCanLearn(player.getClassId()))
{
if(countUnlearnable)
unLearnable++;
continue;
}
if(player.getSkillLevel(sk.getId()) == -1)
{
skillCounter++;
}
player.addSkill(sk);
}
countUnlearnable = false;
skills = SkillTreeTable.getInstance().getAvailableSkills(player, player.getClassId());
}
player.sendMessage("You get " + skillCounter + " skills.");
}
// [ALL Skill get end]
//------------------------------------------------------------------

 

スキルトレナーのHTMに追加
最終更新:2008年11月03日 00:14
ツールボックス

下から選んでください:

新しいページを作成する
ヘルプ / FAQ もご覧ください。