Hola! como estan? Necesito ayuda para lograr incrementar el lvl max de 85 a 99 ... Les cuento que lei varias guias pero mi datapack ( L2JSUNRISE ) no contiene los mismos archivos dejo de ejemplo el Core.
public final class ExperienceData
implements IXmlReader {
private final Map<Integer, Long> _expTable = new HashMap<Integer, Long>();
private byte MAX_LEVEL;
private byte MAX_PET_LEVEL;
protected ExperienceData() {
this.load();
}
@Override
public void load() {
this._expTable.clear();
this.parseDatapackFile("data/xml/stats/experience.xml");
LOGGER.info(this.getClass().getSimpleName() + ": Loaded " + this._expTable.size() + " levels.");
LOGGER.info(this.getClass().getSimpleName() + ": Max Player Level is: " + (this.MAX_LEVEL - 1));
LOGGER.info(this.getClass().getSimpleName() + ": Max Pet Level is: " + (this.MAX_PET_LEVEL - 1));
}
@Override
public void parseDocument(Document doc) {
Node table = doc.getFirstChild();
NamedNodeMap tableAttr = table.getAttributes();
this.MAX_LEVEL = (byte)(Byte.parseByte(tableAttr.getNamedItem("maxLevel").getNodeValue()) + 1);
this.MAX_PET_LEVEL = (byte)(Byte.parseByte(tableAttr.getNamedItem("maxPetLevel").getNodeValue()) + 1);
for (Node n = table.getFirstChild(); n != null; n = n.getNextSibling()) {
if (!"experience".equals(n.getNodeName())) continue;
NamedNodeMap attrs = n.getAttributes();
this._expTable.put(this.parseInteger(attrs, "level"), this.parseLong(attrs, "tolevel"));
}
}
public long getExpForLevel(int level) {
try {
return this._expTable.get(level);
}
catch (Exception e) {
LOGGER.error(this.getClass().getSimpleName() + " incoming level is: " + String.valueOf(level));
if (this._expTable != null && !this._expTable.isEmpty()) {
if (this._expTable.get(level) != null) {
LOGGER.error(this.getClass().getSimpleName() + " _expTable get(level) is: " + String.valueOf(this._expTable.get(level)));
} else {
LOGGER.error(this.getClass().getSimpleName() + " _expTable.get(level) is NULL");
}
} else {
LOGGER.error(this.getClass().getSimpleName() + " _expTable is NULL");
}
return 25314105600L;
}
}
public byte getMaxLevel() {
return this.MAX_LEVEL;
}
public byte getMaxPetLevel() {
return this.MAX_PET_LEVEL;
}
public static ExperienceData getInstance() {
return SingletonHolder._instance;
}
private static class SingletonHolder {
protected static final ExperienceData _instance = new ExperienceData();
You can post now and register later.
If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.
GOSTARIA DOS ICONES DAS TATTOS , TODOS ICONES , COM ESSE LV , ATÉ O LVL 6 POR FAVOR , PARA INTERLUDE , ESSES DO PRINT NAO SAO INTERLUDE E NAO TENHO ! OBRIGADO!
Olá, seu tópico se encontra com um ou mais links offline. Caso ainda possua o conteúdo, favor postar aqui mesmo no tópico ou mandar MP para algum staff que estaremos normalizando o tópico.
Grato pela atenção!
Voce usar a conta de admin q vc tem no server, vai em accounts e define o acess_level la. e vc entra auto.
Eu tenho uma versão desse votesystem q tentei atualizar e com tutorial so acessar o link na minha assinatura em baixo.
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.
Pergunta
amarhat13
Hola! como estan? Necesito ayuda para lograr incrementar el lvl max de 85 a 99 ... Les cuento que lei varias guias pero mi datapack ( L2JSUNRISE ) no contiene los mismos archivos dejo de ejemplo el Core.
*********************************************************
package l2r.gameserver.data.xml.impl;
import java.util.HashMap;
import java.util.Map;
import l2r.util.data.xml.IXmlReader.IXmlReader;
import org.w3c.dom.Document;
import org.w3c.dom.NamedNodeMap;
import org.w3c.dom.Node;
public final class ExperienceData
implements IXmlReader {
private final Map<Integer, Long> _expTable = new HashMap<Integer, Long>();
private byte MAX_LEVEL;
private byte MAX_PET_LEVEL;
protected ExperienceData() {
this.load();
}
@Override
public void load() {
this._expTable.clear();
this.parseDatapackFile("data/xml/stats/experience.xml");
LOGGER.info(this.getClass().getSimpleName() + ": Loaded " + this._expTable.size() + " levels.");
LOGGER.info(this.getClass().getSimpleName() + ": Max Player Level is: " + (this.MAX_LEVEL - 1));
LOGGER.info(this.getClass().getSimpleName() + ": Max Pet Level is: " + (this.MAX_PET_LEVEL - 1));
}
@Override
public void parseDocument(Document doc) {
Node table = doc.getFirstChild();
NamedNodeMap tableAttr = table.getAttributes();
this.MAX_LEVEL = (byte)(Byte.parseByte(tableAttr.getNamedItem("maxLevel").getNodeValue()) + 1);
this.MAX_PET_LEVEL = (byte)(Byte.parseByte(tableAttr.getNamedItem("maxPetLevel").getNodeValue()) + 1);
for (Node n = table.getFirstChild(); n != null; n = n.getNextSibling()) {
if (!"experience".equals(n.getNodeName())) continue;
NamedNodeMap attrs = n.getAttributes();
this._expTable.put(this.parseInteger(attrs, "level"), this.parseLong(attrs, "tolevel"));
}
}
public long getExpForLevel(int level) {
try {
return this._expTable.get(level);
}
catch (Exception e) {
LOGGER.error(this.getClass().getSimpleName() + " incoming level is: " + String.valueOf(level));
if (this._expTable != null && !this._expTable.isEmpty()) {
if (this._expTable.get(level) != null) {
LOGGER.error(this.getClass().getSimpleName() + " _expTable get(level) is: " + String.valueOf(this._expTable.get(level)));
} else {
LOGGER.error(this.getClass().getSimpleName() + " _expTable.get(level) is NULL");
}
} else {
LOGGER.error(this.getClass().getSimpleName() + " _expTable is NULL");
}
return 25314105600L;
}
}
public byte getMaxLevel() {
return this.MAX_LEVEL;
}
public byte getMaxPetLevel() {
return this.MAX_PET_LEVEL;
}
public static ExperienceData getInstance() {
return SingletonHolder._instance;
}
private static class SingletonHolder {
protected static final ExperienceData _instance = new ExperienceData();
private SingletonHolder() {
}
}
}
*****************************************************
Que deberia de editar para subir el maximo ? No tengo el archivo Experience.java si no el nombrado ExperienceData.class !
Gracias !
-L2jAprendiz
Link para o comentário
Compartilhar em outros sites
2 respostass a esta questão
Posts recomendados
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.