mirror of
https://github.com/MassiveCraft/Factions.git
synced 2024-11-24 03:05:52 +01:00
Add missing return statements.
This commit is contained in:
parent
356842ab41
commit
edfe465ad5
@ -36,6 +36,7 @@ public class CmdDeinvite extends FCommand {
|
|||||||
msg.then(name + " ").color(ChatColor.WHITE).tooltip("Click to revoke invite for " + name).command("f deinvite " + name);
|
msg.then(name + " ").color(ChatColor.WHITE).tooltip("Click to revoke invite for " + name).command("f deinvite " + name);
|
||||||
}
|
}
|
||||||
sendFancyMessage(msg);
|
sendFancyMessage(msg);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (you.getFaction() == myFaction) {
|
if (you.getFaction() == myFaction) {
|
||||||
|
@ -47,6 +47,7 @@ public class CmdKick extends FCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
sendFancyMessage(msg);
|
sendFancyMessage(msg);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fme == toKick) {
|
if (fme == toKick) {
|
||||||
|
@ -7,12 +7,10 @@ import com.massivecraft.factions.Factions;
|
|||||||
import com.massivecraft.factions.integration.Econ;
|
import com.massivecraft.factions.integration.Econ;
|
||||||
import com.massivecraft.factions.struct.Permission;
|
import com.massivecraft.factions.struct.Permission;
|
||||||
import com.massivecraft.factions.struct.Relation;
|
import com.massivecraft.factions.struct.Relation;
|
||||||
import com.massivecraft.factions.struct.Role;
|
|
||||||
import mkremins.fanciful.FancyMessage;
|
import mkremins.fanciful.FancyMessage;
|
||||||
import org.bukkit.ChatColor;
|
import org.bukkit.ChatColor;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
|
||||||
|
|
||||||
public class CmdShow extends FCommand {
|
public class CmdShow extends FCommand {
|
||||||
|
|
||||||
@ -47,10 +45,6 @@ public class CmdShow extends FCommand {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Collection<FPlayer> admins = faction.getFPlayersWhereRole(Role.ADMIN);
|
|
||||||
Collection<FPlayer> mods = faction.getFPlayersWhereRole(Role.MODERATOR);
|
|
||||||
Collection<FPlayer> normals = faction.getFPlayersWhereRole(Role.NORMAL);
|
|
||||||
|
|
||||||
msg(p.txt.titleize(faction.getTag(fme)));
|
msg(p.txt.titleize(faction.getTag(fme)));
|
||||||
msg("<a>Description: <i>%s", faction.getDescription());
|
msg("<a>Description: <i>%s", faction.getDescription());
|
||||||
if (!faction.isNormal()) {
|
if (!faction.isNormal()) {
|
||||||
@ -103,10 +97,11 @@ public class CmdShow extends FCommand {
|
|||||||
Relation rel = otherFaction.getRelationTo(faction);
|
Relation rel = otherFaction.getRelationTo(faction);
|
||||||
String s = otherFaction.getTag(fme);
|
String s = otherFaction.getTag(fme);
|
||||||
if (rel.isAlly()) {
|
if (rel.isAlly()) {
|
||||||
if (firstAlly)
|
if (firstAlly) {
|
||||||
currentAllies.then(s).tooltip(getToolTips(otherFaction));
|
currentAllies.then(s).tooltip(getToolTips(otherFaction));
|
||||||
else
|
} else {
|
||||||
currentAllies.then(", " + s).tooltip(getToolTips(otherFaction));
|
currentAllies.then(", " + s).tooltip(getToolTips(otherFaction));
|
||||||
|
}
|
||||||
firstAlly = false;
|
firstAlly = false;
|
||||||
|
|
||||||
if (currentAllies.toJSONString().length() >= 32700) { // Client gets kicked at 32767, some leniency
|
if (currentAllies.toJSONString().length() >= 32700) { // Client gets kicked at 32767, some leniency
|
||||||
@ -114,10 +109,11 @@ public class CmdShow extends FCommand {
|
|||||||
currentAllies = new FancyMessage();
|
currentAllies = new FancyMessage();
|
||||||
}
|
}
|
||||||
} else if (rel.isEnemy()) {
|
} else if (rel.isEnemy()) {
|
||||||
if (firstEnemy)
|
if (firstEnemy) {
|
||||||
currentEnemies.then(s).tooltip(getToolTips(otherFaction));
|
currentEnemies.then(s).tooltip(getToolTips(otherFaction));
|
||||||
else
|
} else {
|
||||||
currentEnemies.then(", " + s).tooltip(getToolTips(otherFaction));
|
currentEnemies.then(", " + s).tooltip(getToolTips(otherFaction));
|
||||||
|
}
|
||||||
firstEnemy = false;
|
firstEnemy = false;
|
||||||
|
|
||||||
if (currentEnemies.toJSONString().length() >= 32700) { // Client gets kicked at 32767, some leniency
|
if (currentEnemies.toJSONString().length() >= 32700) { // Client gets kicked at 32767, some leniency
|
||||||
@ -136,16 +132,18 @@ public class CmdShow extends FCommand {
|
|||||||
for (FPlayer p : faction.getFPlayers()) {
|
for (FPlayer p : faction.getFPlayers()) {
|
||||||
String name = p.getNameAndTitle();
|
String name = p.getNameAndTitle();
|
||||||
if (p.isOnline()) {
|
if (p.isOnline()) {
|
||||||
if (firstOnline)
|
if (firstOnline) {
|
||||||
online.then(name).tooltip(getToolTips(p));
|
online.then(name).tooltip(getToolTips(p));
|
||||||
else
|
} else {
|
||||||
online.then(", " + name).tooltip(getToolTips(p));
|
online.then(", " + name).tooltip(getToolTips(p));
|
||||||
|
}
|
||||||
firstOnline = false;
|
firstOnline = false;
|
||||||
} else {
|
} else {
|
||||||
if (firstOffline)
|
if (firstOffline) {
|
||||||
offline.then(name).tooltip(getToolTips(p));
|
offline.then(name).tooltip(getToolTips(p));
|
||||||
else
|
} else {
|
||||||
offline.then(", " + name).tooltip(getToolTips(p));
|
offline.then(", " + name).tooltip(getToolTips(p));
|
||||||
|
}
|
||||||
firstOffline = false;
|
firstOffline = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -27,8 +27,6 @@ public class CmdShowInvites extends FCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
sendFancyMessage(msg);
|
sendFancyMessage(msg);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user