ExShowScreenMessage mod

Support for the latest build of L2J Server, get help here with installations, upgrades, problems.
Do not post bugs reports here, use viewforum.php?f=77 instead.
There is no support for other server builds than the official provided by l2jserver.com
Forum rules
READ NOW: L2j Forums Rules of Conduct
Post Reply
User avatar
Naonah
Posts: 357
Joined: Sun Apr 04, 2010 11:12 pm

ExShowScreenMessage mod

Post by Naonah »

If you want to receive support we need this info to help you properly.
» Find Revision
L2J Revision Number:
L2JDP Revision Number:

Hi:)

I have such a code:

Code: Select all

sendPacket(new ExShowScreenMessage("You got reward for 5 successful PvP in a row :)", 5000));
It ofc dispaly a message to a player for 5 sec

I would like to modify this like this:

1.send this packet to all players
2. include players nick (exemple: "Player Pisior got reward for 5 successful PvP in a row)

Could you help me to make it working?

Thank you.
Best regards.
public void l2jserver ()
{
if (you want l2j server == no problems)
use Linux;
else
use Windows;
}
User avatar
jurchiks
Posts: 6769
Joined: Sat Sep 19, 2009 4:16 pm
Location: Eastern Europe

Re: ExShowScreenMessage mod

Post by jurchiks »

well then broadcastPacket
If you have problems, FIRST TRY SOLVING THEM YOURSELF, and if you get errors, TRY TO ANALYZE THEM, and ONLY if you can't help it, THEN ask here.
Otherwise you will never learn anything if all you do is copy-paste!
Discussion breeds innovation.
User avatar
Naonah
Posts: 357
Joined: Sun Apr 04, 2010 11:12 pm

Re: ExShowScreenMessage mod

Post by Naonah »

jurchiks wrote:well then broadcastPacket
yes it can work but how to take someone's nick to this message? I mean how to make a query to DB.

Thank you.
public void l2jserver ()
{
if (you want l2j server == no problems)
use Linux;
else
use Windows;
}
User avatar
SolidSnake
Posts: 865
Joined: Wed Jan 20, 2010 6:54 pm
Location: Italy

Re: ExShowScreenMessage mod

Post by SolidSnake »

You could create a new name to the player-killer as 'killer' or 'player1' and write + killer.getName() + in the script
Image
User avatar
Naonah
Posts: 357
Joined: Sun Apr 04, 2010 11:12 pm

Re: ExShowScreenMessage mod

Post by Naonah »

Yeah, simple like f... :mrgreen:

Code: Select all

broadcastPacket(new ExShowScreenMessage(getName() + " got reward for 5 successful PvP in a row :)", 5000));
Thank you @jurchiks and @SolidSnake for helpfull clues :)
public void l2jserver ()
{
if (you want l2j server == no problems)
use Linux;
else
use Windows;
}
Post Reply