diff --git a/src/engine/net/client/handlers/GroupInviteHandler.java b/src/engine/net/client/handlers/GroupInviteHandler.java index bef9a198..0040df7b 100644 --- a/src/engine/net/client/handlers/GroupInviteHandler.java +++ b/src/engine/net/client/handlers/GroupInviteHandler.java @@ -21,6 +21,7 @@ import engine.net.client.msg.ClientNetMsg; import engine.net.client.msg.group.GroupInviteMsg; import engine.net.client.msg.group.GroupUpdateMsg; import engine.objects.Group; +import engine.objects.Guild; import engine.objects.PlayerCharacter; public class GroupInviteHandler extends AbstractClientMsgHandler { @@ -103,6 +104,12 @@ public class GroupInviteHandler extends AbstractClientMsgHandler { if (target.isIgnoringPlayer(source)) return false; + if(source.getGuild().getNation().equals(target.getGuild().getNation()) == false) + return false; // cannot group outside of nation + + if(source.getGuild().getNation().equals(target.getGuild().getNation()) && source.getGuild().getNation().equals(Guild.getErrantGuild())) + if(source.getGuild().equals(target.getGuild()) == false) + return false; // cannot group as an errant guild with other errant guilds // dont block invites to people already in a group and // dont check for pending invites, the client does it