[Help] [Weird] CCing and Sitting stucks you..
I have no idea wth is causing this problem, if I cc I get dced sometime but thats just what happens, the serious problem is that if you cc and sit you cant get up cuz ur stuck in this huge "lag" that wont leave you til you log off and back in. After logging off it says ur still in and you can fix this by waiting or using the website.
No bat errors wse..
Thanks in advance =\
[Request] Job Advance v97 XeonMs
[Help] XeonMs doesn't seem to have the teachSkill method..
I've seen that you don't get all your skills in XeonMs and they don't have the cm.teachSkill method. I've been trying to add myself using other sources but it didn't work so..
Is there a method for Xeon or a skill teacher npc with all v97 skills?
Thanks in advance =]
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
You should be able to take it from other sources just look whats missing. There could be a variable or a method just not implemented. Post your error please. Thanks
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Thats what I'm trying to add in NPCConversationManager.java:
PHP Code:
public void teachSkill(int id, int level, int masterlevel) {
getPlayer().changeSkillLevel(SkillFactory.getSkill(id), level, masterlevel);
}
That's my changeSkillLevel:
PHP Code:
public void changeSkillLevel(ISkill skill, byte newLevel, int newMasterlevel, long expiration) {
if (newLevel > -1) {
skills.put(skill, new SkillEntry(newLevel, newMasterlevel, -1));
this.client.announce(MaplePacketCreator.updateSkill(skill.getId(), newLevel, newMasterlevel));
} else {
skills.remove(skill);
this.client.announce(MaplePacketCreator.updateSkill(skill.getId(), newLevel, newMasterlevel)); //Shouldn't use expiration anymore :)
try {
Connection con = DatabaseConnection.getConnection();
PreparedStatement ps = con.prepareStatement("DELETE FROM skills WHERE skillid = ? AND characterid = ?");
ps.setInt(1, skill.getId());
ps.setInt(2, id);
ps.execute();
ps.close();
} catch (SQLException ex) {
System.out.print("Error deleting skill: " + ex);
}
}
}
And since it's not the same changeSkillLevel it cannot by applied and I don't know how to change the teachSkill method correctly..
Thanks :\
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Code:
public void teachSkill(ISkill skill, byte newLevel, int newMasterlevel, long expiration) {
getPlayer().changeSkillLevel(skill, newLevel, newMasterlevel, -1);
}
Add this to NPCConversationManager
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Thank you so much =]
I'll test it now.
Edit:
Getting this when using teachSkill:
Code:
java.lang.reflect.UndeclaredThrowableException
at $Proxy4.action(Unknown Source)
at scripting.npc.NPCScriptManager.action(NPCScriptManager.java:93)
at net.channel.handler.NPCMoreTalkHandler.handlePacket(NPCMoreTalkHandle
r.java:73)
at net.MapleServerHandler.messageReceived(MapleServerHandler.java:123)
at org.apache.mina.core.filterchain.DefaultIoFilterChain$TailFilter.mess
ageReceived(DefaultIoFilterChain.java:734)
at org.apache.mina.core.filterchain.DefaultIoFilterChain.callNextMessage
Received(DefaultIoFilterChain.java:429)
at org.apache.mina.core.filterchain.DefaultIoFilterChain.access$1200(Def
aultIoFilterChain.java:51)
at org.apache.mina.core.filterchain.DefaultIoFilterChain$EntryImpl$1.mes
sageReceived(DefaultIoFilterChain.java:812)
at org.apache.mina.filter.codec.ProtocolCodecFilter$ProtocolDecoderOutpu
tImpl.flush(ProtocolCodecFilter.java:346)
at org.apache.mina.filter.codec.ProtocolCodecFilter.messageReceived(Prot
ocolCodecFilter.java:221)
at org.apache.mina.core.filterchain.DefaultIoFilterChain.callNextMessage
Received(DefaultIoFilterChain.java:429)
at org.apache.mina.core.filterchain.DefaultIoFilterChain.access$1200(Def
aultIoFilterChain.java:51)
at org.apache.mina.core.filterchain.DefaultIoFilterChain$EntryImpl$1.mes
sageReceived(DefaultIoFilterChain.java:812)
at org.apache.mina.core.filterchain.IoFilterAdapter.messageReceived(IoFi
lterAdapter.java:119)
at org.apache.mina.core.filterchain.DefaultIoFilterChain.callNextMessage
Received(DefaultIoFilterChain.java:429)
at org.apache.mina.core.filterchain.DefaultIoFilterChain.fireMessageRece
ived(DefaultIoFilterChain.java:416)
at org.apache.mina.core.polling.AbstractPollingIoProcessor.read(Abstract
PollingIoProcessor.java:638)
at org.apache.mina.core.polling.AbstractPollingIoProcessor.process(Abstr
actPollingIoProcessor.java:598)
at org.apache.mina.core.polling.AbstractPollingIoProcessor.process(Abstr
actPollingIoProcessor.java:587)
at org.apache.mina.core.polling.AbstractPollingIoProcessor.access$400(Ab
stractPollingIoProcessor.java:61)
at org.apache.mina.core.polling.AbstractPollingIoProcessor$Processor.run
(AbstractPollingIoProcessor.java:969)
at org.apache.mina.util.NamePreservingRunnable.run(NamePreservingRunnabl
e.java:64)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.security.PrivilegedActionException: javax.script.ScriptException
: sun.org.mozilla.javascript.internal.EvaluatorException: Can't find method scri
pting.npc.NPCConversationManager.teachSkill(number,number,number). (<Unknown sou
rce>#11) in <Unknown source> at line number 11
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.script.util.InterfaceImplementor$InterfaceImplementorInvocati
onHandler.invoke(Unknown Source)
... 25 more
Caused by: javax.script.ScriptException: sun.org.mozilla.javascript.internal.Eva
luatorException: Can't find method scripting.npc.NPCConversationManager.teachSki
ll(number,number,number). (<Unknown source>#11) in <Unknown source> at line numb
er 11
at com.sun.script.javascript.RhinoScriptEngine.invoke(Unknown Source)
at com.sun.script.javascript.RhinoScriptEngine.invokeFunction(Unknown So
urce)
at com.sun.script.util.InterfaceImplementor$InterfaceImplementorInvocati
onHandler$1.run(Unknown Source)
... 27 more
Caused by: sun.org.mozilla.javascript.internal.EvaluatorException: Can't find me
thod scripting.npc.NPCConversationManager.teachSkill(number,number,number). (<Un
known source>#11)
at sun.org.mozilla.javascript.internal.DefaultErrorReporter.runtimeError
(Unknown Source)
at sun.org.mozilla.javascript.internal.Context.reportRuntimeError(Unknow
n Source)
at sun.org.mozilla.javascript.internal.Context.reportRuntimeError(Unknow
n Source)
at sun.org.mozilla.javascript.internal.Context.reportRuntimeError1(Unkno
wn Source)
at sun.org.mozilla.javascript.internal.NativeJavaMethod.call(Unknown Sou
rce)
at sun.org.mozilla.javascript.internal.Interpreter.interpretLoop(Unknown
Source)
at sun.org.mozilla.javascript.internal.Interpreter.interpret(Unknown Sou
rce)
at sun.org.mozilla.javascript.internal.InterpretedFunction.call(Unknown
Source)
at sun.org.mozilla.javascript.internal.ContextFactory.doTopCall(Unknown
Source)
at com.sun.script.javascript.RhinoScriptEngine$1.superDoTopCall(Unknown
Source)
at com.sun.script.javascript.RhinoScriptEngine$1.doTopCall(Unknown Sourc
e)
at sun.org.mozilla.javascript.internal.ScriptRuntime.doTopCall(Unknown S
ource)
at sun.org.mozilla.javascript.internal.InterpretedFunction.call(Unknown
Source)
... 30 more
Error: NPC 9010002. UndeclaredThrowableException.
Also if I use cm.getPlayer().changeSkillLevel(skillid,newLevel,newMasterLevel); it gives the same error only that it says it cant find changeSkillLevel in MapleCharacter.
Line i've used:
PHP Code:
cm.teachSkill(20001001,3,3); //Recovery
cm.teachSkill(20001002,3,3); //Nimble Feet
cm.teachSkill(20001000,3,3); //Three Snails
cm.teachSkill(20001004,1,1); //Monster Rider
cm.teachSkill(20001005,1,1); //Echo of Hero
cm.teachSkill(21000000,10,10); //Combo Ability
cm.teachSkill(21000002,20,20); //Double Swing
cm.teachSkill(21001003,20,20); //Aran Polearm Booster
cm.teachSkill(21001001,15,15); //Combo Step
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Quote:
Originally Posted by
AristoCat
Code:
public void teachSkill(ISkill skill, byte newLevel, int newMasterlevel, long expiration) {
getPlayer().changeSkillLevel(skill, newLevel, newMasterlevel, -1);
}
Add this to NPCConversationManager
Why add
PHP Code:
long expiration
if it's going to be set to -1 anyway.
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Well the expiration is set in changeSkillLevel so I must add it for no errors.
Got an idea to fix my bat error?
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Code:
public void teachSkill(ISkill skill, byte newLevel, int newMasterlevel) {
getPlayer().changeSkillLevel(skill, newLevel, newMasterlevel, -1);
}
Should work, if not, reply accordingly.
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Quote:
Originally Posted by
Alienx3
Code:
public void teachSkill(ISkill skill, byte newLevel, int newMasterlevel) {
getPlayer().changeSkillLevel(skill, newLevel, newMasterlevel, -1);
}
Should work, if not, reply accordingly.
XeonMS doesn't have the newLevel newMasterLevel in maplecharacter i believe
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
What are you talking about?
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
Quote:
Originally Posted by
Alienx3
What are you talking about?
Sorry i was thinking about another source o.o
Re: [Help] XeonMs doesn't seem to have the teachSkill method..
I can assure you your skills are maxed out when you get your job advancement.