Jump to content
  • 0

[Help]GM Text..


Question

Posted

Hey guys! I saw in l2extreme a thingie that gm's can write with.Something like a blue text ,but gm's decide what it is (a new kind of announcement lol).Its like a normal chat,but its navy(blue) colored and its like it has no recipent.. Is this a client edit? Or java? Or both?! So i need something like this...

//chat WizZy: Hello all!

And if i dont type WizZy: it will send it like only Hello all! with no further information.. Can someone help me? Thanks..

11 answers to this question

Recommended Posts

  • 0
Posted

he mean on announcements, im looking something like that too.

Also i need a new chat ( have u seen the faction chat on RvB?) u type ^and the text and there is a yellow collored message that only your faction can see. It would be great chat for VIP's or smthing like that.

Same to leeroy im looking for announcement chat without the "announcements:" text

  • 0
Posted

heh.. I think i will remove announcements and make this.Its like i`ll try to find //announce command source ,so it has to be Announcement: blabla ,so i`ll try to remove announcement: and leave only the bla bla :D Anyway i`m STILL searching for this!

  • 0
Posted

its in java ;) better its in client but u dont have to mod it

 

	Chat_Normal ("ALL"),// id = 0 , white
Chat_Shout ("SHOUT"), // ! id = 1 , dark orange
Chat_Tell ("WHISPER"), // " id = 2, purple
Chat_Party ("PARTY"), // # id = 3, green
Chat_Clan ("CLAN"), // @ id = 4, blue/purple
Chat_System ("EMOTE"), // ( id = 5
Chat_User_Pet ("USERPET"), // * id = 6
Chat_GM_Pet ("GMPET"), // * id = 7
Chat_Market ("TRADE"), // + id = 8 pink
Chat_Alliance ("ALLIANCE"), // $ id = 9 light green
Chat_Announce ("ANNOUNCE"), // id = 10 light cyan
Chat_Custom ("CRASH"), // id = 11 --> Crashes client
Chat_L2Friend ("L2FRIEND"), // id = 12 
Chat_MSN ("MSN"),// id = 13
Chat_Party_Room ("PARTYROOM"),// id = 14
Chat_Commander ("COMMANDER"),// id = 15 
Chat_Inner_Partymaster ("INNERPARTYMASTER"),// id = 16 
Chat_Hero ("HERO"), // % id = 17 blue
Chat_Critical_Announce ("CRITANNOUNCE"),// id = 18 dark cyan
Chat_Unknown ("UNKNOWN"), // id = 19
Chat_Battlefield ("BATTLEFIELD"), // ^ id = 20
Chat_None ("NONE");

 

above the colors, and make a view in the chat handlers than u will know how it work ;)

  • 0
Posted

You don't have to mod anything.

Just change the announcer and instead of Announcements.getInstance().announceToAll("yourtext"); Make a CreatureSay with the type SAY2_HERO.

  • 0
Posted

Create new Admin Command Handler...

 

Example: //say <text>

 

One Example:

http://www.maxcheaters.com/forum/index.php?topic=46448.0

 

--------------------------------------------------->

Step 1

 

Create New File < AdminSay >

 

AdminSay <code>

/*
* 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 net.sf.l2j.gameserver.handler.admincommandhandlers;

import java.util.Collection;

import net.sf.l2j.Config;
import net.sf.l2j.gameserver.handler.IAdminCommandHandler;
import net.sf.l2j.gameserver.model.L2World;
import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;
import net.sf.l2j.gameserver.serverpackets.CreatureSay;

/**
* Critical Announce, Deep Blue Channel
* Author: Slave
*/
public class AdminSay implements IAdminCommandHandler {

private static final String[] ADMIN_COMMANDS = {"admin_say"};
private static final int REQUIRED_LEVEL = Config.GM_MIN;

public boolean useAdminCommand(String command, L2PcInstance activeChar) {
	if (!Config.ALT_PRIVILEGES_ADMIN)
		if (!(checkLevel(activeChar.getAccessLevel()) && activeChar.isGM())) return false;

	if (command.startsWith("admin_say"))
		HandleChat(command, activeChar);
	return true;
}

private void HandleChat(String command, L2PcInstance activeChar)
{
	try
	{
		int offset=0;
		String text;
		offset=10;
		text = activeChar.getName()+ ": " + command.substring(offset);
		CreatureSay cs = new CreatureSay(0, 18, activeChar.getName(), text);
		Collection<L2PcInstance> pls = L2World.getInstance().getAllPlayers();			
		{
			for (L2PcInstance player : pls)
			{
				player.sendPacket(cs);
			}
		}
	}
	catch (StringIndexOutOfBoundsException e)
	{
		// System.out.print("GM is Using Critical Announce Channel Successful!"); 
	}
}

public String[] getAdminCommandList() {
	return ADMIN_COMMANDS;
}

private boolean checkLevel(int level) {
	return (level >= REQUIRED_LEVEL);
}
}

 

Step 2

 

Register Handler (C6=Gameserver.Java)

 

PS: This is For C6 ...For Other Chronicle Need Litle Changes

PS2: Command = //say <text>

Example: //say i rock

 

 

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.

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...