Jump to content

Question

Posted

Hello everyone, im a new user on this community. 

Im a newbie but learning more and more about jass and code.

Im already got a live server and my problem is with the NPC achievement system. My source got the achievement system cause every time i complete an achievement a message system is shown. But no NPC.. In server files /data there is a file achievement.xml with requierements for achievements.  i know how to make a npc who reads html and make a multisell, but i dont know how to read xml and make that file to work with a npc.

I tried to call that achievement.xml like a multisell shop but it doesnt work-.

can anybody help me? 

9 answers to this question

Recommended Posts

  • 0
Posted
3 hours ago, expll0 said:

check database - custom_npc and search for achievement npc

image.png.84e4e26280403293da080ce481905eb2.png

2 hours ago, Zake said:

Pack/client?

Thanks for the quick reply guys, and sorry for bother with this dumb questions.

Its l2jOrion source, rev17+rev21. there is a ini in configs to enable achievement system, that is the wierd thing.

 

this is the achievement.xml in gamesever/data

 

but i dont know how to hook it to a npc to work ingame since its not an html


image.thumb.png.dc565a9783a4f601b01abc0a54943d9e.png

  • 0
Posted

Can you post a pic with the contents of model/actor/instance in your source? There's supposed to be an Achievement npc instance in there if it was meant to work with an npc and not CB or some command.

 

Orion still has npcs in sql lol.

  • 0
Posted (edited)
1 hour ago, An4rchy said:

Can you post a pic with the contents of model/actor/instance in your source? There's supposed to be an Achievement npc instance in there if it was meant to work with an npc and not CB or some command.

 

Orion still has npcs in sql lol.

 

* L2jOrion Project - www.l2jorion.com 
 * 
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2, or (at your option)
 * any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 * 02111-1307, USA.
 *
 * http://www.gnu.org/copyleft/gpl.html
 */
package l2jorion.game.model.actor.instance;

import java.util.List;
import java.util.StringTokenizer;

import l2jorion.Config;
import l2jorion.game.datatables.sql.ItemTable;
import l2jorion.game.enums.AchType;
import l2jorion.game.managers.AchievementManager;
import l2jorion.game.model.AchievementHolder;
import l2jorion.game.network.serverpackets.NpcHtmlMessage;
import l2jorion.game.templates.L2Item;
import l2jorion.game.templates.L2NpcTemplate;
import l2jorion.game.util.Util;

public final class L2AchievementInstance extends L2FolkInstance
{
    private final static int PAGE_LIMIT = Config.PAGE_LIMIT;
    
    public L2AchievementInstance(int objectId, L2NpcTemplate template)
    {
        super(objectId, template);
    }
    
    @Override
    public void onBypassFeedback(L2PcInstance player, String command)
    {
        final StringTokenizer st = new StringTokenizer(command, " ");
        String currentCommand = st.nextToken();
        
        if (currentCommand.startsWith("Chat"))
        {
            int val = Integer.parseInt(st.nextToken());
            showChatWindow(player, val);
        }
    }
    
    @Override
    public void showChatWindow(L2PcInstance player, int val)
    {
        final NpcHtmlMessage html = new NpcHtmlMessage(0);
        html.setFile(getHtmlPath(player, getNpcId(), 0));
        html.replace("%objectId%", getObjectId());
        html.replace("%list%", getList(player, val));
        player.sendPacket(html);
    }
    
    public static int countPagesNumber(int objectsSize, int pageSize)
    {
        return objectsSize / pageSize + (objectsSize % pageSize == 0 ? 0 : 1);
    }
    
    private String getList(L2PcInstance player, int page)
    {
        // Retrieve the entire types list based on group type.
        List<AchType> list = AchievementManager.getInstance().getTypeList(player);
        
        // Calculate page number.
        final int max = countPagesNumber(list.size(), PAGE_LIMIT);
        page = page > max ? max : page < 1 ? 1 : page;
        
        // Cut skills list up to page number.
        list = list.subList((page - 1) * PAGE_LIMIT, Math.min(page * PAGE_LIMIT, list.size()));
        
        final StringBuilder sb = new StringBuilder();
        
        int row = 0;
        for (AchType type : list)
        {
            boolean exist = player.getAchievement().getData().containsKey(type);
            boolean completed = false;
            int getLevel = exist ? player.getAchievement().getData().get(type).getId() - 1 : 0;
            int getCount = exist ? player.getAchievement().getData().get(type).getValue() : 0;
            int allStages = AchievementManager.getInstance().getStages(type).size();
            
            if (AchievementManager.getInstance().getStages(type).size() < (getLevel + 1))
            {
                getLevel = AchievementManager.getInstance().getStages(type).size() - 1;
                completed = true;
            }
            
            AchievementHolder ach = AchievementManager.getInstance().getAchievements().get(type).get(getLevel);
            sb.append("<img src=l2ui.squareblack width=296 height=1><table cellspacing=1 cellpadding=1 width=296 bgcolor=000000><tr>");
            sb.append("<td width=40 height=40 align=center><button width=32 height=32 back=" + ach.getIcon() + " fore=" + ach.getIcon() + "></td>");
            sb.append("<td width=256>" + ach.getName().toUpperCase() + " " + (completed ? "<font color=00FF00>Completed</font>" : "") + "<br1>");
            sb.append("Stage:<font color=LEVEL>" + ach.getLevel() + "/" + allStages + "</font> Reward:<font color=LEVEL>" + Util.formatAdena(ach.getRewardCount()) + "</font> " + getItemNameById(ach.getRewardId()) + "<br1>");
            sb.append("<font color=B09878>" + (completed ? "[" + ach.getName() + " achievement completed]" : ach.getDescription().replaceAll("%required%", getCount + "/" + ach.getRequired())) + "</font></td></tr></table>");
            sb.append("<table cellspacing=0 cellpadding=0 width=300 height=15><tr><td>" + generateBar(300, 15, completed ? ach.getRequired() : getCount, ach.getRequired()) + "</td></tr></table>");
            sb.append("<img src=l2ui.squareblack width=296 height=1><img height=3>");
            row++;
        }
        
        for (int i = PAGE_LIMIT; i > row; i--)
        {
            sb.append("<img height=47>");
        }
        
        // Build page footer.
        sb.append("<table width=300><tr>");
        sb.append("<td align=left width=100>" + (page > 1 ? "<button value=\"< PREV\" action=\"bypass npc_" + getObjectId() + "_Chat " + (page - 1) + "\" width=65 height=19 back=L2UI_ch3.smallbutton2_over fore=L2UI_ch3.smallbutton2>" : "") + "</td>");
        sb.append("<td align=center width=100>Page " + page + "/" + max + "</td>");
        sb.append("<td align=right width=100>" + (page < max ? "<button value=\"NEXT >\" action=\"bypass npc_" + getObjectId() + "_Chat " + (page + 1) + "\" width=65 height=19 back=L2UI_ch3.smallbutton2_over fore=L2UI_ch3.smallbutton2>" : "") + "</td>");
        sb.append("</tr></table>");
        
        return sb.toString();
    }
    
    public String generateBar(int width, int height, int current, int max)
    {
        final StringBuilder sb = new StringBuilder();
        current = current > max ? max : current;
        int bar = Math.max((width * (current * 100 / max) / 100), 0);
        sb.append("<table width=" + width + " cellspacing=0 cellpadding=0><tr><td width=" + bar + " align=center><img src=L2UI_CH3.BR_BAR1_CP width=" + bar + " height=" + height + "/></td>");
        sb.append("<td width=" + (width - bar) + " align=center><img src=L2UI_CH3.BR_BAR1_HP1 width=" + (width - bar) + " height=" + height + "/></td></tr></table>");
        return sb.toString();
    }
    
    @Override
    public String getHtmlPath(L2PcInstance player, final int npcId, final int val)
    {
        return "data/html/achievements/" + npcId + "" + (val == 0 ? "" : "-" + val) + ".htm";
    }
    
    public String getItemNameById(int itemId)
    {
        L2Item item = ItemTable.getInstance().getTemplate(itemId);
        
        String itemName = "NoName";
        
        if (itemId != 0)
        {
            itemName = item.getName();
        }
        
        return itemName;
    }
}
 

30 minutes ago, Amenadiel said:

.achiv command? On xml might have the command

i tried /achievement .achievement .achiv /achiv .achievements /achievements

nothing. 

its funny cause i receive the system msg ingame when i unlock an achievment like adquire noblesse and so

This is the achievementManager page

Quote

package l2jorion.game.managers;

import java.util.ArrayList;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;

import org.w3c.dom.Document;
import org.w3c.dom.NamedNodeMap;
import org.w3c.dom.Node;

import l2jorion.Config;
import l2jorion.game.enums.AchType;
import l2jorion.game.model.AchievementHolder;
import l2jorion.game.model.actor.instance.L2PcInstance;
import l2jorion.game.templates.StatsSet;
import l2jorion.logger.Logger;
import l2jorion.logger.LoggerFactory;
import l2jorion.util.xml.IXmlReader;

public class AchievementManager implements IXmlReader
{
    private static Logger LOG = LoggerFactory.getLogger(AchievementManager.class);
    
    private final Map<AchType, List<AchievementHolder>> _achievements = new LinkedHashMap<>();
    
    public AchievementManager()
    {
        load();
    }
    
    @Override
    public void load()
    {
        parseDatapackFile("./data/xml/achievements.xml");
        LOG.info("Loaded {} of {} achievements data.", _achievements.size(), AchType.values().length);
    }
    
    public void reload()
    {
        _achievements.clear();
        load();
    }
    
    @Override
    public void parseDocument(Document doc)
    {
        for (Node a = doc.getFirstChild(); a != null; a = a.getNextSibling())
        {
            if ("list".equalsIgnoreCase(a.getNodeName()))
            {
                for (Node b = a.getFirstChild(); b != null; b = b.getNextSibling())
                {
                    if ("achievement".equalsIgnoreCase(b.getNodeName()))
                    {
                        final NamedNodeMap attrs = b.getAttributes();
                        
                        final AchType type = AchType.valueOf(parseString(attrs, "type"));
                        final StatsSet set = new StatsSet();
                        set.set("icon", parseString(attrs, "icon"));
                        set.set("name", parseString(attrs, "name"));
                        set.set("desc", parseString(attrs, "desc"));
                        
                        final List<AchievementHolder> levels = new ArrayList<>();
                        
                        for (Node c = b.getFirstChild(); c != null; c = c.getNextSibling())
                        {
                            if ("stage".equalsIgnoreCase(c.getNodeName()))
                            {
                                set.add(parseAttributes(c));
                                levels.add(new AchievementHolder(set));
                            }
                        }
                        
                        _achievements.put(type, levels);
                    }
                }
            }
        }
        
    }
    
    public List<AchievementHolder> getStages(AchType type)
    {
        return _achievements.get(type);
    }
    
    public AchievementHolder getAchievement(AchType type, int level)
    {
        return _achievements.get(type).stream().filter(x -> x.getLevel() == level).findFirst().orElse(null);
    }
    
    public Map<AchType, List<AchievementHolder>> getAchievements()
    {
        return _achievements;
    }
    
    public List<AchType> getTypeList(L2PcInstance player)
    {
        List<AchType> list = new ArrayList<>();
        for (AchType type : _achievements.keySet())
        {
            if (type == AchType.SPOIL && !player.getSkills().containsKey(254))
            {
                continue;
            }
            
            if (type == AchType.LEADER && player.getClan() != null && !player.isClanLeader())
            {
                continue;
            }
            
            if ((type == AchType.CLAN_LEVEL_UP || type == AchType.CASTLE) && !player.isClanLeader())
            {
                continue;
            }
            
            if (type == AchType.ACADEMY && player.getClassId().level() > 1 && player.getAchievement().getLevel(AchType.ACADEMY) != 2)
            {
                continue;
            }
            
            if (type == AchType.MONSTER_CHAMPION && Config.L2JMOD_CHAMPION_FREQUENCY == 0)
            {
                continue;
            }
            
            list.add(type);
        }
        return list;
    }
    
    public static AchievementManager getInstance()
    {
        return SingletonHolder.INSTANCE;
    }
    
    private static class SingletonHolder
    {
        protected static final AchievementManager INSTANCE = new AchievementManager();
    }
}

 

package l2jorion.game.managers;

import java.util.ArrayList;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;

import org.w3c.dom.Document;
import org.w3c.dom.NamedNodeMap;
import org.w3c.dom.Node;

import l2jorion.Config;
import l2jorion.game.enums.AchType;
import l2jorion.game.model.AchievementHolder;
import l2jorion.game.model.actor.instance.L2PcInstance;
import l2jorion.game.templates.StatsSet;
import l2jorion.logger.Logger;
import l2jorion.logger.LoggerFactory;
import l2jorion.util.xml.IXmlReader;

public class AchievementManager implements IXmlReader
{
    private static Logger LOG = LoggerFactory.getLogger(AchievementManager.class);
    
    private final Map<AchType, List<AchievementHolder>> _achievements = new LinkedHashMap<>();
    
    public AchievementManager()
    {
        load();
    }
    
    @Override
    public void load()
    {
        parseDatapackFile("./data/xml/achievements.xml");
        LOG.info("Loaded {} of {} achievements data.", _achievements.size(), AchType.values().length);
    }
    
    public void reload()
    {
        _achievements.clear();
        load();
    }
    
    @Override
    public void parseDocument(Document doc)
    {
        for (Node a = doc.getFirstChild(); a != null; a = a.getNextSibling())
        {
            if ("list".equalsIgnoreCase(a.getNodeName()))
            {
                for (Node b = a.getFirstChild(); b != null; b = b.getNextSibling())
                {
                    if ("achievement".equalsIgnoreCase(b.getNodeName()))
                    {
                        final NamedNodeMap attrs = b.getAttributes();
                        
                        final AchType type = AchType.valueOf(parseString(attrs, "type"));
                        final StatsSet set = new StatsSet();
                        set.set("icon", parseString(attrs, "icon"));
                        set.set("name", parseString(attrs, "name"));
                        set.set("desc", parseString(attrs, "desc"));
                        
                        final List<AchievementHolder> levels = new ArrayList<>();
                        
                        for (Node c = b.getFirstChild(); c != null; c = c.getNextSibling())
                        {
                            if ("stage".equalsIgnoreCase(c.getNodeName()))
                            {
                                set.add(parseAttributes(c));
                                levels.add(new AchievementHolder(set));
                            }
                        }
                        
                        _achievements.put(type, levels);
                    }
                }
            }
        }
        
    }
    
    public List<AchievementHolder> getStages(AchType type)
    {
        return _achievements.get(type);
    }
    
    public AchievementHolder getAchievement(AchType type, int level)
    {
        return _achievements.get(type).stream().filter(x -> x.getLevel() == level).findFirst().orElse(null);
    }
    
    public Map<AchType, List<AchievementHolder>> getAchievements()
    {
        return _achievements;
    }
    
    public List<AchType> getTypeList(L2PcInstance player)
    {
        List<AchType> list = new ArrayList<>();
        for (AchType type : _achievements.keySet())
        {
            if (type == AchType.SPOIL && !player.getSkills().containsKey(254))
            {
                continue;
            }
            
            if (type == AchType.LEADER && player.getClan() != null && !player.isClanLeader())
            {
                continue;
            }
            
            if ((type == AchType.CLAN_LEVEL_UP || type == AchType.CASTLE) && !player.isClanLeader())
            {
                continue;
            }
            
            if (type == AchType.ACADEMY && player.getClassId().level() > 1 && player.getAchievement().getLevel(AchType.ACADEMY) != 2)
            {
                continue;
            }
            
            if (type == AchType.MONSTER_CHAMPION && Config.L2JMOD_CHAMPION_FREQUENCY == 0)
            {
                continue;
            }
            
            list.add(type);
        }
        return list;
    }
    
    public static AchievementManager getInstance()
    {
        return SingletonHolder.INSTANCE;
    }
    
    private static class SingletonHolder
    {
        protected static final AchievementManager INSTANCE = new AchievementManager();
    }
}

 

This is Achievement Instance page:

 

* L2jOrion Project - www.l2jorion.com 
 * 
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2, or (at your option)
 * any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 * 02111-1307, USA.
 *
 * http://www.gnu.org/copyleft/gpl.html
 */
package l2jorion.game.model.actor.instance;

import java.util.List;
import java.util.StringTokenizer;

import l2jorion.Config;
import l2jorion.game.datatables.sql.ItemTable;
import l2jorion.game.enums.AchType;
import l2jorion.game.managers.AchievementManager;
import l2jorion.game.model.AchievementHolder;
import l2jorion.game.network.serverpackets.NpcHtmlMessage;
import l2jorion.game.templates.L2Item;
import l2jorion.game.templates.L2NpcTemplate;
import l2jorion.game.util.Util;

public final class L2AchievementInstance extends L2FolkInstance
{
    private final static int PAGE_LIMIT = Config.PAGE_LIMIT;
    
    public L2AchievementInstance(int objectId, L2NpcTemplate template)
    {
        super(objectId, template);
    }
    
    @Override
    public void onBypassFeedback(L2PcInstance player, String command)
    {
        final StringTokenizer st = new StringTokenizer(command, " ");
        String currentCommand = st.nextToken();
        
        if (currentCommand.startsWith("Chat"))
        {
            int val = Integer.parseInt(st.nextToken());
            showChatWindow(player, val);
        }
    }
    
    @Override
    public void showChatWindow(L2PcInstance player, int val)
    {
        final NpcHtmlMessage html = new NpcHtmlMessage(0);
        html.setFile(getHtmlPath(player, getNpcId(), 0));
        html.replace("%objectId%", getObjectId());
        html.replace("%list%", getList(player, val));
        player.sendPacket(html);
    }
    
    public static int countPagesNumber(int objectsSize, int pageSize)
    {
        return objectsSize / pageSize + (objectsSize % pageSize == 0 ? 0 : 1);
    }
    
    private String getList(L2PcInstance player, int page)
    {
        // Retrieve the entire types list based on group type.
        List<AchType> list = AchievementManager.getInstance().getTypeList(player);
        
        // Calculate page number.
        final int max = countPagesNumber(list.size(), PAGE_LIMIT);
        page = page > max ? max : page < 1 ? 1 : page;
        
        // Cut skills list up to page number.
        list = list.subList((page - 1) * PAGE_LIMIT, Math.min(page * PAGE_LIMIT, list.size()));
        
        final StringBuilder sb = new StringBuilder();
        
        int row = 0;
        for (AchType type : list)
        {
            boolean exist = player.getAchievement().getData().containsKey(type);
            boolean completed = false;
            int getLevel = exist ? player.getAchievement().getData().get(type).getId() - 1 : 0;
            int getCount = exist ? player.getAchievement().getData().get(type).getValue() : 0;
            int allStages = AchievementManager.getInstance().getStages(type).size();
            
            if (AchievementManager.getInstance().getStages(type).size() < (getLevel + 1))
            {
                getLevel = AchievementManager.getInstance().getStages(type).size() - 1;
                completed = true;
            }
            
            AchievementHolder ach = AchievementManager.getInstance().getAchievements().get(type).get(getLevel);
            sb.append("<img src=l2ui.squareblack width=296 height=1><table cellspacing=1 cellpadding=1 width=296 bgcolor=000000><tr>");
            sb.append("<td width=40 height=40 align=center><button width=32 height=32 back=" + ach.getIcon() + " fore=" + ach.getIcon() + "></td>");
            sb.append("<td width=256>" + ach.getName().toUpperCase() + " " + (completed ? "<font color=00FF00>Completed</font>" : "") + "<br1>");
            sb.append("Stage:<font color=LEVEL>" + ach.getLevel() + "/" + allStages + "</font> Reward:<font color=LEVEL>" + Util.formatAdena(ach.getRewardCount()) + "</font> " + getItemNameById(ach.getRewardId()) + "<br1>");
            sb.append("<font color=B09878>" + (completed ? "[" + ach.getName() + " achievement completed]" : ach.getDescription().replaceAll("%required%", getCount + "/" + ach.getRequired())) + "</font></td></tr></table>");
            sb.append("<table cellspacing=0 cellpadding=0 width=300 height=15><tr><td>" + generateBar(300, 15, completed ? ach.getRequired() : getCount, ach.getRequired()) + "</td></tr></table>");
            sb.append("<img src=l2ui.squareblack width=296 height=1><img height=3>");
            row++;
        }
        
        for (int i = PAGE_LIMIT; i > row; i--)
        {
            sb.append("<img height=47>");
        }
        
        // Build page footer.
        sb.append("<table width=300><tr>");
        sb.append("<td align=left width=100>" + (page > 1 ? "<button value=\"< PREV\" action=\"bypass npc_" + getObjectId() + "_Chat " + (page - 1) + "\" width=65 height=19 back=L2UI_ch3.smallbutton2_over fore=L2UI_ch3.smallbutton2>" : "") + "</td>");
        sb.append("<td align=center width=100>Page " + page + "/" + max + "</td>");
        sb.append("<td align=right width=100>" + (page < max ? "<button value=\"NEXT >\" action=\"bypass npc_" + getObjectId() + "_Chat " + (page + 1) + "\" width=65 height=19 back=L2UI_ch3.smallbutton2_over fore=L2UI_ch3.smallbutton2>" : "") + "</td>");
        sb.append("</tr></table>");
        
        return sb.toString();
    }
    
    public String generateBar(int width, int height, int current, int max)
    {
        final StringBuilder sb = new StringBuilder();
        current = current > max ? max : current;
        int bar = Math.max((width * (current * 100 / max) / 100), 0);
        sb.append("<table width=" + width + " cellspacing=0 cellpadding=0><tr><td width=" + bar + " align=center><img src=L2UI_CH3.BR_BAR1_CP width=" + bar + " height=" + height + "/></td>");
        sb.append("<td width=" + (width - bar) + " align=center><img src=L2UI_CH3.BR_BAR1_HP1 width=" + (width - bar) + " height=" + height + "/></td></tr></table>");
        return sb.toString();
    }
    
    @Override
    public String getHtmlPath(L2PcInstance player, final int npcId, final int val)
    {
        return "data/html/achievements/" + npcId + "" + (val == 0 ? "" : "-" + val) + ".htm";
    }
    
    public String getItemNameById(int itemId)
    {
        L2Item item = ItemTable.getInstance().getTemplate(itemId);
        
        String itemName = "NoName";
        
        if (itemId != 0)
        {
            itemName = item.getName();
        }
        
        return itemName;
    }
}
 

 

 

Edited by Paly
  • 0
Posted (edited)

Bro, use pastebin.com for large chunks of code. It's unreadable like that.

 

You need to make a new npc with type L2Achievement and add its html in data/html/achievements. If there is already a html there, leave it as it is (only rename with your npc id).

 

If there isn't make sure to include %list% in the html so the actual achievement list can appear.

 

I just had a look at the code, it should work fine unless I missed something. If you find any problems just reply.

 

 

P.S. Kindly suggestion, don't use orion. If you don't have a developer and need ready features, use lucera. Otherwise pay a developer and use aCis.

Edited by An4rchy
  • 0
Posted
1 hour ago, An4rchy said:

Bro, use pastebin.com for large chunks of code. It's unreadable like that.

 

You need to make a new npc with type L2Achievement and add its html in data/html/achievements. If there is already a html there, leave it as it is (only rename with your npc id).

 

If there isn't make sure to include %list% in the html so the actual achievement list can appear.

 

I just had a look at the code, it should work fine unless I missed something. If you find any problems just reply.

 

 

P.S. Kindly suggestion, don't use orion. If you don't have a developer and need ready features, use lucera. Otherwise pay a developer and use aCis.

Hello, you save me. Many many thanks! it works perfectly. I was using L2AchievementManager and the system dont found the npc!  So many thanks to all of you.

I will try lucera. Im on Orion cause it works fine for now and got all the mods i wanted: bang points, offline trade/craft, no core bugs, and now achievements. 

Sorry for the bad reply without <code>

 

I want to ask a little things that maybe are very easy for u guys.

 

How can i create a new item? i need to add it to handlers? i want no make a new sp scroll, that gives exp no sp. i can imagine is not so simple like create a new npc id in custom npc.

 

I follow this steps, create a new code in etcitems. then edit the etcitems in system, and i think i need to add the ability item in source?

  • 0
Posted

You need to make a new ItemHandler and in there add player.addExpAndSp or whatever similar method orion uses. Then, you need to create a new item (in xml or sql, idk what orion uses) and specify the handler you created (if it's xml smth like <set name="handler" val="YourHandlerName"/>0).

 

Also, having a pack that has 'no core bugs' like you said does not mean everything will be OK when you open  a server. You will probably end up with 500 errors/missing things/not working things you had no idea about and 0 clue how to fix them. You cannot open a server if you don't know what you're doing, avoid it. Pay a developer to do it for you, or start learning.

 

Even if you use lucera, which is a pack used by numerous online servers (L2Unity, L2Dream namely and 99% of russian servers) you will still have errors and problems. But as long as you don't leech the pack and buy it, you will have support by experienced developers (a thing that I cannot say for orion unfortunately).

 

Long story short if you don't pay or spend numerous hours learning, you'll fail. But gl.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Posts

    • Facebook-Ins-X-Pin-Proxy - 150M+ Fresh Residential Proxies    MoMoProxy Official Site: MoMoProxy.com   1. Features ------------------------------------------ 1. 190+ Countries And Millions of City Targeting”; 2. 80M+ Rotating Residential Proxies”; 3. 5M+ 240 Minutes Lasting Sticky Residential Proxies”; 4. 99.64% Request Success Rate.” 5. High Anonymous Clean Residential Proxies. 6. 50M-1GB/S Download and Upload Speed. 7. IP Whitelist Or User Pass Authentication. 8. Convenient IP Abstracting On User Panel, No APP Download. 9. IP Pool Covers 190+ Countries. 10. API For Automation Workflow. 11. Compatible With All Browsers & Devices. 12. SOCKS5 HTTP(S) Proxies. 13. 99.64% Request Success Rate and 99.9% Update. 2. Use Cases: Web Scraping and Data Extraction Use MoMoProxy to access websites anonymously and avoid IP blocking while scraping large volumes of data for research, business intelligence, or competitive analysis. Social Media Management (Multiple Accounts) Manage multiple social media accounts (e.g., Instagram, Twitter, Facebook) simultaneously with different proxy IPs to avoid account bans and increase operational efficiency. SEO and SERP Tracking Use MoMoProxy to perform SEO audits and track search engine result page (SERP) rankings without being blocked by search engines, simulating searches from different geographical locations. E-commerce Price Monitoring Monitor competitors' prices on e-commerce platforms (like Amazon, eBay) by using MoMoProxy's rotating residential IPs to simulate user requests from different regions without getting flagged. Web Testing and Automation Conduct automated web testing by using MoMoProxy to simulate user behavior across different locations, devices, and networks, ensuring that web applications behave consistently under various conditions. Ad Verification Verify online advertisements (display ads, pay-per-click ads) from different IP addresses to ensure proper targeting and compliance with advertising policies. Fraud Prevention and Security Safeguard your online activities (such as financial transactions or account logins) by using MoMoProxy to rotate IP addresses and protect against IP-based attacks or fraud. Market Research Collect data from various sources without being detected or restricted, allowing for comprehensive market research, competitor analysis, and trend forecasting. Mobile App Testing Use MoMoProxy to test mobile applications across different regions and simulate real-world user scenarios, ensuring that apps perform correctly in various network environments. Ticketing and Event Booking Secure tickets for high-demand events by using MoMoProxy to mask your real IP and bypass ticket purchasing limits based on IP addresses. Ad Fraud Prevention Prevent ad fraud by rotating IPs to detect and block suspicious activities related to advertising, ensuring accurate attribution and campaign performance analysis. Academic Research and Surveys Use MoMoProxy to distribute surveys or gather data from different regions without bias due to regional IP filtering or restrictions.   3. Pricing List: ----------------------------------------------- Note: Price List will be changable based on our promotion every month or in some Dig Days. If any question or help please contact our support online timely: Telegram: https://t.me/momoproxy_com Email: support@momoproxy.com 4. Payments: Now MoMoProxy Supports: A. Crypto Currency Payment, including USDT, BTC, and more; B. Alipay HK, UnionPay; C. Doku For local Southeast Asia payment; D. Offline Aliay and WeChat, please contact support Online; (Note: Visa, MasterCard and Paypal is coming within 30 days). 5.Return Policy MoMoProxy Offer 3 days free trial for all new users that will be helpful for you get further experience on MoMoProxy quality before payment. We also provide 24 hours money-back guarantee, which only applies to technical issues related to MoMoProxy servers that we can not fix within 24 hours. 6. FAQ A. How to buy a plan and how about MoMoProxy payments? After logging in, and enter into the user dashboard, please choose the right plan that be suitable for you, and click [Buy Proxy]. Now MoMoProxy Supports: A. Crypto Currency Payment, including USDT, BTC, and more; B. Alipay HK, UnionPay; C. Doku For local Southeast Asia payment; D. Offline Aliay and WeChat, please contact support Online; (Note: Visa, MasterCard and Paypal is coming within 30 days). B. Where can I use residential IP addresses? a. For Handle Proxy Generate, Just Choose [Proxy Setup], Click [Residential Proxies], and go to [Endpoint Generator] Part, and choose [location] and [proxy type], click [Generate] to generate Proxy List, all steps will be easily; b. Residential Proxies (API) is also available for automation. Can I integrate proxies with 3rd party software, bots and automation tools? You can integrate MoMoProxy proxies with all major automation bots under the help of our API. C. Can I select proxies from specific locations? You can access residential proxies through country-specific, state-targeting or city-targeting after using your login credentials (username and password) or in Allowlisted IPs, such as Los Angeles, California, USA. 7. Contact Us Telegram: https://t.me/momoproxy_com Email: support@momoproxy.com 8. How To Get A FREE Trial? Please register your account firstly, and contact support online to get A 1GB Free Trial! Get 1GB Free Trial NOW! Get 1GB Free Trial NOW! Get 1GB Free Trial NOW! Get 1GB Free Trial NOW! Get 1GB Free Trial NOW! Get 1GB Free Trial NOW!
    • Hello! That's funny things: Rates x3 And  "No Donate things affect the game balance"                           GM Donate Shop - B-A-S grade for Donation Coins VIP Status: Rates x8
    • I’ve been using SMS.To for a while now and it’s been solid. No issues with delays so far, and the text messaging works right away for verification. Way easier than dealing with local SIM cards for every site.
    • Good evening, I have a problem with the items+ when I enchant, for example, the armors, the weapons, all the stats are normal. When I put them on my inventory, the +4+5 etc. that I have done do not appear. The project is h5 with the salvation protocol. Can any expert help me fix it? Thanks in advance. some screens... this items is +12   https://prnt.sc/fh2i0pjCHDY_ https://prnt.sc/qc1kLl-S4hn6 https://prnt.sc/CTFw3HOdZDPz  
  • Topics

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock