Re: Chat and Siege Problems!
The first issue is that the chat command you made is broadcasting for current player's Knownlist, max 95 declared in VisibleObject.
Try this code instead.
Code:
private void broadcastFromCommander(final Player _actor) {
if (_actor.getRace() == Race.ELYOS) {
World.getInstance().doOnAllPlayers(new Visitor<Player>() {
@Override
public void visit(final Player _actore) {
if (_actore.getRace() == Race.ELYOS || _actore.isGM()) {
if (_actore.getWorldId() == _actor.getWorldId() && _actore.getRace() == _actor.getRace()) {
Player _sendere = (Player) _actor;
PacketSendUtility.broadcastPacket(_actore, new SM_MESSAGE(_sendere, message, type), true);
}
}
}
});
}
if (_actor.getRace() == Race.ASMODIANS) {
World.getInstance().doOnAllPlayers(new Visitor<Player>() {
@Override
public void visit(final Player _actora) {
if (_actora.getRace() == Race.ASMODIANS || _actora.isGM()) {
if (_actora.getWorldId() == _actor.getWorldId() && _actora.getRace() == _actor.getRace()) {
Player _sendera = (Player) _actor;
PacketSendUtility.broadcastPacket(_actora, new SM_MESSAGE(_sendera, message, type), true);
}
}
}
});
}
}
For the second problem, check SiegeService.
Re: Chat and Siege Problems!
Okay i just have this problem: https://imgur.com/HSgu2YJ
I think the problem that i'm having have something to do with the "actore" "actora" at SM_MESSAGE
About the siege i know is simple and is just a number but i cant find it.
Re: Chat and Siege Problems!
I edited the code. Copy paste it and compile now.
Re: Chat and Siege Problems!
It works now!
But it got 2 problems.
1°: The message is sent to all maps when is just supposed to be sent just to the map where the person are sending the message.
2°: When the message show up is always with the same player like...
Shows the self name not the name from the person that has sent the message like in the print screen below:
https://imgur.com/g8hWNAI
https://imgur.com/OJUxqMT
Re: Chat and Siege Problems!
I edited the code. I think that's what you want.
Re: Chat and Siege Problems!
Sorry but now i'm having this: https://imgur.com/M6HkTDH
You make and change the code so easily it's amazing.
Re: Chat and Siege Problems!
I type from the phone then some lines get messed up. Check if it compiles now.
Re: Chat and Siege Problems!
Got this: https://imgur.com/9mb1Tz9
From your phone? '-' i'm a garbage.
Re: Chat and Siege Problems!
Re: Chat and Siege Problems!
It works a 100%.
Thank you very much for helping me!
- - - Updated - - -
I have two more adjustments that i want to do in my server.
If you could help me i can donate for you.
First is my siege problem.
I already check the siegeservice but couldnt find the number where i can change to make it work properly.
The problem is that siege are kickin players when starts (it's okay) the problem is that the players have been kicked at 30 meters from the fortress when it should be like 250meters or 300.
This happens in Inggison/Gelkmaros/Reshanta fortress.
The second is this custom:
I want to set up in my files the PREMIUM/VIP tags like in this picture. https://imgur.com/a/kZWzr
I want to put the crowns in the 2 sides of the character's name.
What and how should i do it?
This is my full code in SM_PLAYER_INFO including the ADMIN tags.
https://imgur.com/a/IQl5DDd
If you can help i appreciate that!
I already thank you for your time and effort to help me fix my commander governor chat!
God bless you!
Re: Chat and Siege Problems!
Go to your membership configs, should be configs/main/membership.properties and just edit the tag you want with "\uE0BD %s \uE0BD".
For Siege, where are the kicked players being sent to? Bind location or?
Re: Chat and Siege Problems!
Bind location
- - - Updated - - -
This is how it looks now: https://imgur.com/25h5yvC
I wish it was (Sign) Asmodian Army Commander Decker (Sign)
I think i have to change my src code.
Re: Chat and Siege Problems!
You can't do that because Abyss Ranks aren't retrieved by Strings but by Integers.
Re: Chat and Siege Problems!
I see that in alot of private servers. One guy once told me to look for the code like this green balls when you select yourselft with F1
Like in this printscreen: https://imgur.com/TruD2gC
XD
Thx again for trying to help me.