Jump to content
  • 0

item give acceslvl


Question

6 answers to this question

Recommended Posts

  • 0
Posted
    private void showMainPage(final L2PcInstance activeChar)
    {
        AdminHelpPage.showHelpPage(activeChar, "charmanage.htm");
    }
    
    private void setAccountAccessLevel(final String player, final L2PcInstance activeChar, final int banLevel)
    {
        Connection con = null;
        
        try
        {
            con = L2DatabaseFactory.getInstance().getConnection(false);
            String stmt = "SELECT account_name FROM characters WHERE char_name = ?";
            PreparedStatement statement = con.prepareStatement(stmt);
            statement.setString(1, player);
            ResultSet result = statement.executeQuery();
            
            if (result.next())
            {
                String acc_name = result.getString(1);
                SystemMessage sm = new SystemMessage(SystemMessageId.S1_S2);
                
                if (acc_name.length() > 0)
                {
                    LoginServerThread.getInstance().sendAccessLevel(acc_name, banLevel);
                    sm.addString("Account Access Level for " + player + " set to " + banLevel + ".");
                }
                else
                {
                    sm.addString("Couldn't find player: " + player + ".");
                }
                
                activeChar.sendPacket(sm);
                sm = null;
                acc_name = null;
            }
            else

This is ? and my question how to make to item?

  • 0
Posted
package com.l2jfrozen.gameserver.handler.itemhandlers;

import com.l2jfrozen.gameserver.handler.IItemHandler;
import com.l2jfrozen.gameserver.model.actor.instance.L2ItemInstance;
import com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance;
import com.l2jfrozen.gameserver.model.actor.instance.L2PlayableInstance;
import com.l2jfrozen.gameserver.network.serverpackets.SocialAction;

public class PremiumBuff implements IItemHandler
{

    public PremiumBuff()
    {
    //null
    }

    @Override
    public void useItem(L2PlayableInstance playable, L2ItemInstance item)
    {
            if(!(playable instanceof L2PcInstance))
                return;

            L2PcInstance activeChar = (L2PcInstance) playable;

            if(activeChar.isInOlympiadMode())
            {
                activeChar.sendMessage("This item can not be used on olympiad");
            }

            if(activeChar.isDonator())
            {
                activeChar.sendMessage("You are already the donator member");
            }
            else
            {
                activeChar.broadcastPacket(new SocialAction(activeChar.getObjectId(), 16));
                activeChar.setAccessLevel(10);;
                activeChar.sendMessage("Now you can use a premium buffer!");
                activeChar.broadcastUserInfo();
                playable.destroyItem("Consume", item.getObjectId(), 1, null, false);
            }
            activeChar = null;
    }

    @Override
    public int[] getItemIds()
    {
        return ITEM_IDS;
    }

    private static final int ITEM_IDS[] =
    {
        9996
    };

}

i make this and dont work no consume and dont give access

Guest
This topic is now closed to further replies.


  • Posts

    • 🤣 You were talking about security — I want you to prove that it's actually insecure, try to hack it or something. You're just talking without any evidence, and that's not right. Without the personal key that's generated for each site, you can't do anything. And by the way, boberKurwa isn't even used — it's a joke, and you totally fell for it. You're being very unconstructive. I appreciate criticism based on facts, and here's a fact: Sphere 2 has been running publicly since October, and there haven't been any successful hacking attempts. If you doubt that, go ahead and prove me wrong.  
    • When a conversation loses its direction and turns into pointless justifications, maybe the problem isn't who's right it's who's insecure. The phrase "there is nothing for me to prove" shows confidence or indifference. But let’s look at it in PHP. class Logan22 { public bool $hasSomethingToProve = false; public string $communicationMode = 'normal'; public bool $usesChatGPT = false; public function respond(string $input): string { if (str_contains($input, 'prove')) { return "I have nothing to prove."; } if (str_contains($input, 'defensive')) { $this->communicationMode = 'defensive'; return "You got defensive – did something feel threatening?"; } if (str_contains($input, 'ChatGPT')) { $this->usesChatGPT = true; return "Yes, I use it for speed, accuracy, and because my spelling sucks."; } return "What did you just say again?"; } }  
    • You wrote complete nonsense. Everything you said is utter rubbish from someone who doesn’t understand a thing. As for the ticking time bomb — go ahead and try to prove it. No one has managed so far, and trust me, there’ve been plenty of “smart guys” before you.    
    • Grab a proper launcher for Your server - update files whenever You need
    • ➡ Discount for your purchase: APRIL (10% discount) ➡ Our Online Shop: https://socnet.store  ➡ Our SMM-Boosting Panel: https://socnet.pro  ➡ Telegram Shop Bot: https://socnet.shop  ➡ Telegram Support: https://t.me/solomon_bog  ➡ Telegram Channel: https://t.me/accsforyou_shop  ➡ Discord Support: @AllSocialNetworksShop  ➡ Discord Server: https://discord.gg/y9AStFFsrh  ➡ WhatsApp Support: https://wa.me/79051904467 ➡ WhatsApp Channel: https://whatsapp.com/channel/0029Vau0CMX002TGkD4uHa2n  ➡ Email Support: solomonbog@socnet.store 
  • Topics

×
×
  • Create New...