Jump to content
  • 0

L2Maelstrom ChatALL is not Working h5 L2jPS


Marc_Mj

Question

Hi there... i´ve got a problem with the chat.. but i do not know since when...
i saw a config.properties called PvPchatSystem. where it comes this... on the lasts lines i put 0 anf false with the leve required  but same... isnt working...

 

# ---------------------------------------
# Section: Chat PvP System by Points
# ---------------------------------------
# Same as above, PvP's you need to use Chat Channels.
# Example:  PvpsToUseChatShout = 500, when a character's PvP counter reaches 500, their will Use ChatShout
# Pvps to use Chat Shout
# Default = False , 0
ChatShoutNeedPvps = False
PvpsToUseChatShout = 0
#
# Pvps to use chat Trade
# Default = False , 0
ChatTradeNeedPvps = False
PvpsToUseChatTrade = 0
#
# Pvp necessary to use the chat ALL.
# 0 Desactived.
ChatAllNeedPvps = False
NeedPvpUseChaT = 0

# level necessary to use the chat ALL.
# 0 Desactived.
ChatAllNeedLvl = False
NeedLvlUseChaT = 1
 

Link to comment
Share on other sites

6 answers to this question

Recommended Posts

  • 0
On 5/21/2020 at 7:51 PM, Marc_Mj said:

Hi there... i´ve got a problem with the chat.. but i do not know since when...
i saw a config.properties called PvPchatSystem. where it comes this... on the lasts lines i put 0 anf false with the leve required  but same... isnt working...

 

# ---------------------------------------
# Section: Chat PvP System by Points
# ---------------------------------------
# Same as above, PvP's you need to use Chat Channels.
# Example:  PvpsToUseChatShout = 500, when a character's PvP counter reaches 500, their will Use ChatShout
# Pvps to use Chat Shout
# Default = False , 0
ChatShoutNeedPvps = False
PvpsToUseChatShout = 0
#
# Pvps to use chat Trade
# Default = False , 0
ChatTradeNeedPvps = False
PvpsToUseChatTrade = 0
#
# Pvp necessary to use the chat ALL.
# 0 Desactived.
ChatAllNeedPvps = False
NeedPvpUseChaT = 0

# level necessary to use the chat ALL.
# 0 Desactived.
ChatAllNeedLvl = False
NeedLvlUseChaT = 1
 

visit handlers.chathandlers/Shout.java, post the part of the code here

Link to comment
Share on other sites

  • 0
On 5/24/2020 at 7:26 PM, Zake said:

visit handlers.chathandlers/Shout.java, post the part of the code here

package handlers.chathandlers;

import com.l2jserver.Config;
import com.l2jserver.gameserver.handler.IChatHandler;
import com.l2jserver.gameserver.instancemanager.MapRegionManager;
import com.l2jserver.gameserver.model.BlockList;
import com.l2jserver.gameserver.model.L2World;
import com.l2jserver.gameserver.model.PcCondOverride;
import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
import com.l2jserver.gameserver.network.SystemMessageId;
import com.l2jserver.gameserver.network.serverpackets.CreatureSay;
import com.l2jserver.gameserver.util.Util;

/**
 * Shout chat handler.
 * @author durgus
 */
public class ChatShout implements IChatHandler
{
    private static final int[] COMMAND_IDS =
    {
        1
    };
    
    /**
     * Handle chat type 'shout'
     */
    @Override
    public void handleChat(int type, L2PcInstance activeChar, String target, String text)
    {
        if (activeChar.isChatBanned() && Util.contains(Config.BAN_CHAT_CHANNELS, type))
        {
            activeChar.sendPacket(SystemMessageId.CHATTING_IS_CURRENTLY_PROHIBITED);
            return;
        }
        
        CreatureSay cs = new CreatureSay(activeChar.getObjectId(), type, activeChar.getName(), text);
        
        L2PcInstance[] pls = L2World.getInstance().getAllPlayersArray();
        
        if (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("on") || (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("gm") && activeChar.canOverrideCond(PcCondOverride.CHAT_CONDITIONS)))
        {
            int region = MapRegionManager.getInstance().getMapRegionLocId(activeChar);
            for (L2PcInstance player : pls)
            {
                if ((region == MapRegionManager.getInstance().getMapRegionLocId(player)) && !BlockList.isBlocked(player, activeChar) && (player.getInstanceId() == activeChar.getInstanceId()))
                {
                    player.sendPacket(cs);
                }
            }
        }
        else if (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("global"))
        {
            if (!activeChar.canOverrideCond(PcCondOverride.CHAT_CONDITIONS) && !activeChar.getFloodProtectors().getGlobalChat().tryPerformAction("global chat"))
            {
                activeChar.sendMessage("Do not spam shout channel.");
                return;
            }
            
            for (L2PcInstance player : pls)
            {
                if (!BlockList.isBlocked(player, activeChar))
                {
                    player.sendPacket(cs);
                }
            }
        }
    }
    
    /**
     * Returns the chat types registered to this handler.
     */
    @Override
    public int[] getChatTypeList()
    {
        return COMMAND_IDS;
    }
}
 

o forgot to say the console dosnt drop any error, and in the chatbox ingame too... no error texts...
and the chat doest apear as well...

Link to comment
Share on other sites

  • 0
14 hours ago, Marc_Mj said:

package handlers.chathandlers;

import com.l2jserver.Config;
import com.l2jserver.gameserver.handler.IChatHandler;
import com.l2jserver.gameserver.instancemanager.MapRegionManager;
import com.l2jserver.gameserver.model.BlockList;
import com.l2jserver.gameserver.model.L2World;
import com.l2jserver.gameserver.model.PcCondOverride;
import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
import com.l2jserver.gameserver.network.SystemMessageId;
import com.l2jserver.gameserver.network.serverpackets.CreatureSay;
import com.l2jserver.gameserver.util.Util;

/**
 * Shout chat handler.
 * @author durgus
 */
public class ChatShout implements IChatHandler
{
    private static final int[] COMMAND_IDS =
    {
        1
    };
    
    /**
     * Handle chat type 'shout'
     */
    @Override
    public void handleChat(int type, L2PcInstance activeChar, String target, String text)
    {
        if (activeChar.isChatBanned() && Util.contains(Config.BAN_CHAT_CHANNELS, type))
        {
            activeChar.sendPacket(SystemMessageId.CHATTING_IS_CURRENTLY_PROHIBITED);
            return;
        }
        
        CreatureSay cs = new CreatureSay(activeChar.getObjectId(), type, activeChar.getName(), text);
        
        L2PcInstance[] pls = L2World.getInstance().getAllPlayersArray();
        
        if (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("on") || (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("gm") && activeChar.canOverrideCond(PcCondOverride.CHAT_CONDITIONS)))
        {
            int region = MapRegionManager.getInstance().getMapRegionLocId(activeChar);
            for (L2PcInstance player : pls)
            {
                if ((region == MapRegionManager.getInstance().getMapRegionLocId(player)) && !BlockList.isBlocked(player, activeChar) && (player.getInstanceId() == activeChar.getInstanceId()))
                {
                    player.sendPacket(cs);
                }
            }
        }
        else if (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("global"))
        {
            if (!activeChar.canOverrideCond(PcCondOverride.CHAT_CONDITIONS) && !activeChar.getFloodProtectors().getGlobalChat().tryPerformAction("global chat"))
            {
                activeChar.sendMessage("Do not spam shout channel.");
                return;
            }
            
            for (L2PcInstance player : pls)
            {
                if (!BlockList.isBlocked(player, activeChar))
                {
                    player.sendPacket(cs);
                }
            }
        }
    }
    
    /**
     * Returns the chat types registered to this handler.
     */
    @Override
    public int[] getChatTypeList()
    {
        return COMMAND_IDS;
    }
}
 

o forgot to say the console dosnt drop any error, and in the chatbox ingame too... no error texts...
and the chat doest apear as well...

Some code is missing, probably some lazy "developer" forgot to remove some crappy configs.

Link to comment
Share on other sites

  • 0

L2jPS is outdated af, they stopped working on it since 2014-2015 and it was always a bad pack.

There are a lot of free projects out there newer and working try one of them and don't waste your time with this.

Link to comment
Share on other sites

  • 0
On 5/26/2020 at 7:33 PM, Designatix said:

L2jPS is outdated af, they stopped working on it since 2014-2015 and it was always a bad pack.

There are a lot of free projects out there newer and working try one of them and don't waste your time with this.

yeah! thanks for your advise... but i´d already got a l2jsunrise its gonna be really interesting...

Link to comment
Share on other sites

  • 0
13 minutes ago, Marc_Mj said:

yeah! thanks for your advise... but i´d already got a l2jsunrise its gonna be really interesting...

Good job, they are kinda similar (not in quality way but they used to look almost the same way back) so it won't confuse you.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...