diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsCreate.java b/src/com/massivecraft/factions/cmd/CmdFactionsCreate.java index 19fe7983..047bc553 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsCreate.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsCreate.java @@ -13,9 +13,9 @@ import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.FactionColl; import com.massivecraft.factions.entity.FactionColls; import com.massivecraft.factions.entity.MConf; -import com.massivecraft.factions.event.FactionsEventCreate; -import com.massivecraft.factions.event.FactionsEventMembershipChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange.MembershipChangeReason; +import com.massivecraft.factions.event.EventFactionsCreate; +import com.massivecraft.factions.event.EventFactionsMembershipChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange.MembershipChangeReason; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.store.MStore; @@ -69,7 +69,7 @@ public class CmdFactionsCreate extends FCommand String factionId = MStore.createId(); // Event - FactionsEventCreate createEvent = new FactionsEventCreate(sender, coll.getUniverse(), factionId, newName); + EventFactionsCreate createEvent = new EventFactionsCreate(sender, coll.getUniverse(), factionId, newName); createEvent.run(); if (createEvent.isCancelled()) return; @@ -80,7 +80,7 @@ public class CmdFactionsCreate extends FCommand usender.setRole(Rel.LEADER); usender.setFaction(faction); - FactionsEventMembershipChange joinEvent = new FactionsEventMembershipChange(sender, usender, faction, MembershipChangeReason.CREATE); + EventFactionsMembershipChange joinEvent = new EventFactionsMembershipChange(sender, usender, faction, MembershipChangeReason.CREATE); joinEvent.run(); // NOTE: join event cannot be cancelled or you'll have an empty faction diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsDescription.java b/src/com/massivecraft/factions/cmd/CmdFactionsDescription.java index 485a050c..ec653f7f 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsDescription.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsDescription.java @@ -5,7 +5,7 @@ import com.massivecraft.factions.Rel; import com.massivecraft.factions.cmd.req.ReqFactionsEnabled; import com.massivecraft.factions.cmd.req.ReqHasFaction; import com.massivecraft.factions.cmd.req.ReqRoleIsAtLeast; -import com.massivecraft.factions.event.FactionsEventDescriptionChange; +import com.massivecraft.factions.event.EventFactionsDescriptionChange; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.mixin.Mixin; @@ -42,7 +42,7 @@ public class CmdFactionsDescription extends FCommand String newDescription = this.argConcatFrom(0); // Event - FactionsEventDescriptionChange event = new FactionsEventDescriptionChange(sender, usenderFaction, newDescription); + EventFactionsDescriptionChange event = new EventFactionsDescriptionChange(sender, usenderFaction, newDescription); event.run(); if (event.isCancelled()) return; newDescription = event.getNewDescription(); diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsDisband.java b/src/com/massivecraft/factions/cmd/CmdFactionsDisband.java index d6d17485..d3f63ad3 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsDisband.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsDisband.java @@ -7,9 +7,9 @@ import com.massivecraft.factions.entity.UPlayerColls; import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.FactionColls; import com.massivecraft.factions.entity.MConf; -import com.massivecraft.factions.event.FactionsEventDisband; -import com.massivecraft.factions.event.FactionsEventMembershipChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange.MembershipChangeReason; +import com.massivecraft.factions.event.EventFactionsDisband; +import com.massivecraft.factions.event.EventFactionsMembershipChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange.MembershipChangeReason; import com.massivecraft.factions.FFlag; import com.massivecraft.factions.FPerm; import com.massivecraft.factions.Factions; @@ -58,7 +58,7 @@ public class CmdFactionsDisband extends FCommand } // Event - FactionsEventDisband event = new FactionsEventDisband(me, faction); + EventFactionsDisband event = new EventFactionsDisband(me, faction); event.run(); if (event.isCancelled()) return; @@ -67,7 +67,7 @@ public class CmdFactionsDisband extends FCommand // Run event for each player in the faction for (UPlayer uplayer : faction.getUPlayers()) { - FactionsEventMembershipChange membershipChangeEvent = new FactionsEventMembershipChange(sender, uplayer, FactionColls.get().get(faction).getNone(), MembershipChangeReason.DISBAND); + EventFactionsMembershipChange membershipChangeEvent = new EventFactionsMembershipChange(sender, uplayer, FactionColls.get().get(faction).getNone(), MembershipChangeReason.DISBAND); membershipChangeEvent.run(); } diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsFaction.java b/src/com/massivecraft/factions/cmd/CmdFactionsFaction.java index dcfe9a4d..52226508 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsFaction.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsFaction.java @@ -11,7 +11,7 @@ import com.massivecraft.factions.cmd.req.ReqFactionsEnabled; import com.massivecraft.factions.entity.UConf; import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.factions.entity.Faction; -import com.massivecraft.factions.event.FactionsEventChunkChangeType; +import com.massivecraft.factions.event.EventFactionsChunkChangeType; import com.massivecraft.factions.integration.Econ; import com.massivecraft.factions.FFlag; import com.massivecraft.factions.Perm; @@ -86,7 +86,7 @@ public class CmdFactionsFaction extends FCommand { long landCount = faction.getLandCount(); - for (FactionsEventChunkChangeType type : FactionsEventChunkChangeType.values()) + for (EventFactionsChunkChangeType type : EventFactionsChunkChangeType.values()) { Double money = uconf.econChunkCost.get(type); if (money == null) continue; diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsHome.java b/src/com/massivecraft/factions/cmd/CmdFactionsHome.java index ea83748c..b262b613 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsHome.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsHome.java @@ -14,7 +14,7 @@ import com.massivecraft.factions.entity.BoardColls; import com.massivecraft.factions.entity.UConf; import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.factions.entity.Faction; -import com.massivecraft.factions.event.FactionsEventHomeTeleport; +import com.massivecraft.factions.event.EventFactionsHomeTeleport; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.cmd.req.ReqIsPlayer; import com.massivecraft.massivecore.mixin.Mixin; @@ -133,7 +133,7 @@ public class CmdFactionsHome extends FCommand } // Event - FactionsEventHomeTeleport event = new FactionsEventHomeTeleport(sender); + EventFactionsHomeTeleport event = new EventFactionsHomeTeleport(sender); event.run(); if (event.isCancelled()) return; diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsInvite.java b/src/com/massivecraft/factions/cmd/CmdFactionsInvite.java index 07a09c18..ee9b6c93 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsInvite.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsInvite.java @@ -7,7 +7,7 @@ import com.massivecraft.factions.cmd.arg.ARUPlayer; import com.massivecraft.factions.cmd.req.ReqFactionsEnabled; import com.massivecraft.factions.cmd.req.ReqHasFaction; import com.massivecraft.factions.entity.UPlayer; -import com.massivecraft.factions.event.FactionsEventInvitedChange; +import com.massivecraft.factions.event.EventFactionsInvitedChange; import com.massivecraft.massivecore.cmd.arg.ARBoolean; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.cmd.req.ReqIsPlayer; @@ -60,7 +60,7 @@ public class CmdFactionsInvite extends FCommand if ( ! FPerm.INVITE.has(usender, usenderFaction, true)) return; // Event - FactionsEventInvitedChange event = new FactionsEventInvitedChange(sender, uplayer, usenderFaction, newInvited); + EventFactionsInvitedChange event = new EventFactionsInvitedChange(sender, uplayer, usenderFaction, newInvited); event.run(); if (event.isCancelled()) return; newInvited = event.isNewInvited(); diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsJoin.java b/src/com/massivecraft/factions/cmd/CmdFactionsJoin.java index 76ea9174..bc154d95 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsJoin.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsJoin.java @@ -9,8 +9,8 @@ import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.MConf; import com.massivecraft.factions.entity.UConf; -import com.massivecraft.factions.event.FactionsEventMembershipChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange.MembershipChangeReason; +import com.massivecraft.factions.event.EventFactionsMembershipChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange.MembershipChangeReason; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.util.Txt; @@ -93,7 +93,7 @@ public class CmdFactionsJoin extends FCommand } // Event - FactionsEventMembershipChange membershipChangeEvent = new FactionsEventMembershipChange(sender, usender, faction, MembershipChangeReason.JOIN); + EventFactionsMembershipChange membershipChangeEvent = new EventFactionsMembershipChange(sender, usender, faction, MembershipChangeReason.JOIN); membershipChangeEvent.run(); if (membershipChangeEvent.isCancelled()) return; diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsKick.java b/src/com/massivecraft/factions/cmd/CmdFactionsKick.java index bf7b2666..97fbab0f 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsKick.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsKick.java @@ -11,8 +11,8 @@ import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.FactionColls; import com.massivecraft.factions.entity.MConf; import com.massivecraft.factions.entity.UConf; -import com.massivecraft.factions.event.FactionsEventMembershipChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange.MembershipChangeReason; +import com.massivecraft.factions.event.EventFactionsMembershipChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange.MembershipChangeReason; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; public class CmdFactionsKick extends FCommand @@ -70,7 +70,7 @@ public class CmdFactionsKick extends FCommand if (!FPerm.KICK.has(usender, uplayerFaction, true)) return; // Event - FactionsEventMembershipChange event = new FactionsEventMembershipChange(sender, uplayer, FactionColls.get().get(uplayer).getNone(), MembershipChangeReason.KICK); + EventFactionsMembershipChange event = new EventFactionsMembershipChange(sender, uplayer, FactionColls.get().get(uplayer).getNone(), MembershipChangeReason.KICK); event.run(); if (event.isCancelled()) return; diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsLeader.java b/src/com/massivecraft/factions/cmd/CmdFactionsLeader.java index ee21c249..b94d4752 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsLeader.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsLeader.java @@ -8,8 +8,8 @@ import com.massivecraft.factions.cmd.req.ReqFactionsEnabled; import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.factions.entity.UPlayerColls; import com.massivecraft.factions.entity.Faction; -import com.massivecraft.factions.event.FactionsEventMembershipChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange.MembershipChangeReason; +import com.massivecraft.factions.event.EventFactionsMembershipChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange.MembershipChangeReason; import com.massivecraft.factions.util.RelationUtil; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.util.Txt; @@ -78,7 +78,7 @@ public class CmdFactionsLeader extends FCommand // only run event when newLeader isn't actually in the faction if (newLeader.getFaction() != targetFaction) { - FactionsEventMembershipChange event = new FactionsEventMembershipChange(sender, newLeader, targetFaction, MembershipChangeReason.LEADER); + EventFactionsMembershipChange event = new EventFactionsMembershipChange(sender, newLeader, targetFaction, MembershipChangeReason.LEADER); event.run(); if (event.isCancelled()) return; } diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsName.java b/src/com/massivecraft/factions/cmd/CmdFactionsName.java index a19a9b43..af4383d2 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsName.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsName.java @@ -11,7 +11,7 @@ import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.FactionColl; import com.massivecraft.factions.entity.FactionColls; import com.massivecraft.factions.entity.UConf; -import com.massivecraft.factions.event.FactionsEventNameChange; +import com.massivecraft.factions.event.EventFactionsNameChange; import com.massivecraft.factions.util.MiscUtil; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; @@ -64,7 +64,7 @@ public class CmdFactionsName extends FCommand } // Event - FactionsEventNameChange event = new FactionsEventNameChange(sender, usenderFaction, newName); + EventFactionsNameChange event = new EventFactionsNameChange(sender, usenderFaction, newName); event.run(); if (event.isCancelled()) return; newName = event.getNewName(); diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsOpen.java b/src/com/massivecraft/factions/cmd/CmdFactionsOpen.java index 3e0035a8..03686a3b 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsOpen.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsOpen.java @@ -5,7 +5,7 @@ import com.massivecraft.factions.Rel; import com.massivecraft.factions.cmd.req.ReqFactionsEnabled; import com.massivecraft.factions.cmd.req.ReqHasFaction; import com.massivecraft.factions.cmd.req.ReqRoleIsAtLeast; -import com.massivecraft.factions.event.FactionsEventOpenChange; +import com.massivecraft.factions.event.EventFactionsOpenChange; import com.massivecraft.massivecore.cmd.arg.ARBoolean; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; @@ -42,7 +42,7 @@ public class CmdFactionsOpen extends FCommand if (newOpen == null) return; // Event - FactionsEventOpenChange event = new FactionsEventOpenChange(sender, usenderFaction, newOpen); + EventFactionsOpenChange event = new EventFactionsOpenChange(sender, usenderFaction, newOpen); event.run(); if (event.isCancelled()) return; newOpen = event.isNewOpen(); diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsRelationAbstract.java b/src/com/massivecraft/factions/cmd/CmdFactionsRelationAbstract.java index 0985d720..ae731545 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsRelationAbstract.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsRelationAbstract.java @@ -9,7 +9,7 @@ import com.massivecraft.factions.cmd.req.ReqHasFaction; import com.massivecraft.factions.cmd.req.ReqRoleIsAtLeast; import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.MConf; -import com.massivecraft.factions.event.FactionsEventRelationChange; +import com.massivecraft.factions.event.EventFactionsRelationChange; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; public abstract class CmdFactionsRelationAbstract extends FCommand @@ -66,7 +66,7 @@ public abstract class CmdFactionsRelationAbstract extends FCommand } // Event - FactionsEventRelationChange event = new FactionsEventRelationChange(sender, usenderFaction, otherFaction, newRelation); + EventFactionsRelationChange event = new EventFactionsRelationChange(sender, usenderFaction, otherFaction, newRelation); event.run(); if (event.isCancelled()) return; newRelation = event.getNewRelation(); diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsSethome.java b/src/com/massivecraft/factions/cmd/CmdFactionsSethome.java index cc5b3be0..55b8724b 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsSethome.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsSethome.java @@ -7,7 +7,7 @@ import com.massivecraft.factions.cmd.arg.ARFaction; import com.massivecraft.factions.cmd.req.ReqFactionsEnabled; import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.UConf; -import com.massivecraft.factions.event.FactionsEventHomeChange; +import com.massivecraft.factions.event.EventFactionsHomeChange; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.cmd.req.ReqIsPlayer; import com.massivecraft.massivecore.ps.PS; @@ -63,7 +63,7 @@ public class CmdFactionsSethome extends FCommand } // Event - FactionsEventHomeChange event = new FactionsEventHomeChange(sender, faction, newHome); + EventFactionsHomeChange event = new EventFactionsHomeChange(sender, faction, newHome); event.run(); if (event.isCancelled()) return; newHome = event.getNewHome(); diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsTitle.java b/src/com/massivecraft/factions/cmd/CmdFactionsTitle.java index 1c62c42a..20712971 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsTitle.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsTitle.java @@ -8,7 +8,7 @@ import com.massivecraft.factions.cmd.arg.ARUPlayer; import com.massivecraft.factions.cmd.req.ReqFactionsEnabled; import com.massivecraft.factions.cmd.req.ReqRoleIsAtLeast; import com.massivecraft.factions.entity.UPlayer; -import com.massivecraft.factions.event.FactionsEventTitleChange; +import com.massivecraft.factions.event.EventFactionsTitleChange; import com.massivecraft.massivecore.cmd.arg.ARString; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.util.Txt; @@ -58,7 +58,7 @@ public class CmdFactionsTitle extends FCommand if ( ! canIAdministerYou(usender, you)) return; // Event - FactionsEventTitleChange event = new FactionsEventTitleChange(sender, you, newTitle); + EventFactionsTitleChange event = new EventFactionsTitleChange(sender, you, newTitle); event.run(); if (event.isCancelled()) return; newTitle = event.getNewTitle(); diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsUnclaimall.java b/src/com/massivecraft/factions/cmd/CmdFactionsUnclaimall.java index 72ae7ab0..ec71a181 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsUnclaimall.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsUnclaimall.java @@ -14,7 +14,7 @@ import com.massivecraft.factions.entity.BoardColls; import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.FactionColls; import com.massivecraft.factions.entity.MConf; -import com.massivecraft.factions.event.FactionsEventChunkChange; +import com.massivecraft.factions.event.EventFactionsChunkChange; import com.massivecraft.massivecore.cmd.req.ReqHasPerm; import com.massivecraft.massivecore.ps.PS; @@ -58,7 +58,7 @@ public class CmdFactionsUnclaimall extends FCommand int countFail = 0; for (PS chunk : chunks) { - FactionsEventChunkChange event = new FactionsEventChunkChange(sender, chunk, newFaction); + EventFactionsChunkChange event = new EventFactionsChunkChange(sender, chunk, newFaction); event.run(); if (event.isCancelled()) { diff --git a/src/com/massivecraft/factions/entity/UConf.java b/src/com/massivecraft/factions/entity/UConf.java index 0f5fa853..2d9502b6 100644 --- a/src/com/massivecraft/factions/entity/UConf.java +++ b/src/com/massivecraft/factions/entity/UConf.java @@ -12,7 +12,7 @@ import org.bukkit.event.EventPriority; import com.massivecraft.factions.FFlag; import com.massivecraft.factions.FPerm; import com.massivecraft.factions.Rel; -import com.massivecraft.factions.event.FactionsEventChunkChangeType; +import com.massivecraft.factions.event.EventFactionsChunkChangeType; import com.massivecraft.massivecore.store.Entity; import com.massivecraft.massivecore.store.SenderEntity; import com.massivecraft.massivecore.util.MUtil; @@ -219,11 +219,11 @@ public class UConf extends Entity // INTEGRATION: LWC // -------------------------------------------- // - public Map lwcRemoveOnChange = MUtil.map( - FactionsEventChunkChangeType.BUY, false, - FactionsEventChunkChangeType.SELL, false, - FactionsEventChunkChangeType.CONQUER, false, - FactionsEventChunkChangeType.PILLAGE, false + public Map lwcRemoveOnChange = MUtil.map( + EventFactionsChunkChangeType.BUY, false, + EventFactionsChunkChangeType.SELL, false, + EventFactionsChunkChangeType.CONQUER, false, + EventFactionsChunkChangeType.PILLAGE, false ); // -------------------------------------------- // @@ -237,11 +237,11 @@ public class UConf extends Entity public String econUniverseAccount = ""; - public Map econChunkCost = MUtil.map( - FactionsEventChunkChangeType.BUY, 30.0, - FactionsEventChunkChangeType.SELL, -20.0, - FactionsEventChunkChangeType.CONQUER, -10.0, - FactionsEventChunkChangeType.PILLAGE, -10.0 + public Map econChunkCost = MUtil.map( + EventFactionsChunkChangeType.BUY, 30.0, + EventFactionsChunkChangeType.SELL, -20.0, + EventFactionsChunkChangeType.CONQUER, -10.0, + EventFactionsChunkChangeType.PILLAGE, -10.0 ); public double econCostCreate = 200.0; diff --git a/src/com/massivecraft/factions/entity/UPlayer.java b/src/com/massivecraft/factions/entity/UPlayer.java index 214fefea..7840561c 100644 --- a/src/com/massivecraft/factions/entity/UPlayer.java +++ b/src/com/massivecraft/factions/entity/UPlayer.java @@ -13,9 +13,9 @@ import com.massivecraft.factions.Factions; import com.massivecraft.factions.Lang; import com.massivecraft.factions.Rel; import com.massivecraft.factions.RelationParticipator; -import com.massivecraft.factions.event.FactionsEventChunkChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange.MembershipChangeReason; +import com.massivecraft.factions.event.EventFactionsChunkChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange.MembershipChangeReason; import com.massivecraft.factions.util.RelationUtil; import com.massivecraft.massivecore.mixin.Mixin; import com.massivecraft.massivecore.ps.PS; @@ -620,7 +620,7 @@ public class UPlayer extends SenderEntity implements EconomyParticipato } // Event - FactionsEventMembershipChange membershipChangeEvent = new FactionsEventMembershipChange(this.getSender(), this, myFaction, MembershipChangeReason.LEAVE); + EventFactionsMembershipChange membershipChangeEvent = new EventFactionsMembershipChange(this.getSender(), this, myFaction, MembershipChangeReason.LEAVE); membershipChangeEvent.run(); if (membershipChangeEvent.isCancelled()) return; @@ -760,7 +760,7 @@ public class UPlayer extends SenderEntity implements EconomyParticipato } // Event - FactionsEventChunkChange event = new FactionsEventChunkChange(sender, chunk, newFaction); + EventFactionsChunkChange event = new EventFactionsChunkChange(sender, chunk, newFaction); event.run(); if (event.isCancelled()) return false; diff --git a/src/com/massivecraft/factions/event/FactionsEventAbstract.java b/src/com/massivecraft/factions/event/EventFactionsAbstract.java similarity index 61% rename from src/com/massivecraft/factions/event/FactionsEventAbstract.java rename to src/com/massivecraft/factions/event/EventFactionsAbstract.java index 1263f522..1f309537 100644 --- a/src/com/massivecraft/factions/event/FactionsEventAbstract.java +++ b/src/com/massivecraft/factions/event/EventFactionsAbstract.java @@ -2,7 +2,7 @@ package com.massivecraft.factions.event; import com.massivecraft.massivecore.event.EventMassiveCore; -public abstract class FactionsEventAbstract extends EventMassiveCore +public abstract class EventFactionsAbstract extends EventMassiveCore { } diff --git a/src/com/massivecraft/factions/event/FactionsEventAbstractSender.java b/src/com/massivecraft/factions/event/EventFactionsAbstractSender.java similarity index 81% rename from src/com/massivecraft/factions/event/FactionsEventAbstractSender.java rename to src/com/massivecraft/factions/event/EventFactionsAbstractSender.java index 7913f5d3..e4907a3f 100644 --- a/src/com/massivecraft/factions/event/FactionsEventAbstractSender.java +++ b/src/com/massivecraft/factions/event/EventFactionsAbstractSender.java @@ -5,7 +5,7 @@ import org.bukkit.command.CommandSender; import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.massivecore.event.EventMassiveCore; -public abstract class FactionsEventAbstractSender extends EventMassiveCore +public abstract class EventFactionsAbstractSender extends EventMassiveCore { // -------------------------------------------- // // FIELDS @@ -19,7 +19,7 @@ public abstract class FactionsEventAbstractSender extends EventMassiveCore // CONSTRUCT // -------------------------------------------- // - public FactionsEventAbstractSender(CommandSender sender) + public EventFactionsAbstractSender(CommandSender sender) { this.sender = sender; } diff --git a/src/com/massivecraft/factions/event/FactionsEventChunkChange.java b/src/com/massivecraft/factions/event/EventFactionsChunkChange.java similarity index 77% rename from src/com/massivecraft/factions/event/FactionsEventChunkChange.java rename to src/com/massivecraft/factions/event/EventFactionsChunkChange.java index 8f187599..bc2f7e46 100644 --- a/src/com/massivecraft/factions/event/FactionsEventChunkChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsChunkChange.java @@ -8,7 +8,7 @@ import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.massivecore.ps.PS; -public class FactionsEventChunkChange extends FactionsEventAbstractSender +public class EventFactionsChunkChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -33,7 +33,7 @@ public class FactionsEventChunkChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventChunkChange(CommandSender sender, PS chunk, Faction newFaction) + public EventFactionsChunkChange(CommandSender sender, PS chunk, Faction newFaction) { super(sender); this.chunk = chunk.getChunk(true); @@ -45,15 +45,15 @@ public class FactionsEventChunkChange extends FactionsEventAbstractSender // UTIL // -------------------------------------------- // - public FactionsEventChunkChangeType getType() + public EventFactionsChunkChangeType getType() { - if (currentFaction.isNone()) return FactionsEventChunkChangeType.BUY; - if (newFaction.isNormal()) return FactionsEventChunkChangeType.CONQUER; + if (currentFaction.isNone()) return EventFactionsChunkChangeType.BUY; + if (newFaction.isNormal()) return EventFactionsChunkChangeType.CONQUER; UPlayer usender = this.getUSender(); - if (usender != null && usender.getFaction() == currentFaction) return FactionsEventChunkChangeType.SELL; + if (usender != null && usender.getFaction() == currentFaction) return EventFactionsChunkChangeType.SELL; - return FactionsEventChunkChangeType.PILLAGE; + return EventFactionsChunkChangeType.PILLAGE; } } diff --git a/src/com/massivecraft/factions/event/FactionsEventChunkChangeType.java b/src/com/massivecraft/factions/event/EventFactionsChunkChangeType.java similarity index 61% rename from src/com/massivecraft/factions/event/FactionsEventChunkChangeType.java rename to src/com/massivecraft/factions/event/EventFactionsChunkChangeType.java index 851ef708..33cd4140 100644 --- a/src/com/massivecraft/factions/event/FactionsEventChunkChangeType.java +++ b/src/com/massivecraft/factions/event/EventFactionsChunkChangeType.java @@ -1,6 +1,6 @@ package com.massivecraft.factions.event; -public enum FactionsEventChunkChangeType +public enum EventFactionsChunkChangeType { BUY, SELL, diff --git a/src/com/massivecraft/factions/event/FactionsEventCreate.java b/src/com/massivecraft/factions/event/EventFactionsCreate.java similarity index 89% rename from src/com/massivecraft/factions/event/FactionsEventCreate.java rename to src/com/massivecraft/factions/event/EventFactionsCreate.java index e570641c..f6d5ba1c 100644 --- a/src/com/massivecraft/factions/event/FactionsEventCreate.java +++ b/src/com/massivecraft/factions/event/EventFactionsCreate.java @@ -3,7 +3,7 @@ package com.massivecraft.factions.event; import org.bukkit.command.CommandSender; import org.bukkit.event.HandlerList; -public class FactionsEventCreate extends FactionsEventAbstractSender +public class EventFactionsCreate extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -30,7 +30,7 @@ public class FactionsEventCreate extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventCreate(CommandSender sender, String universe, String factionId, String factionName) + public EventFactionsCreate(CommandSender sender, String universe, String factionId, String factionName) { super(sender); this.universe = universe; diff --git a/src/com/massivecraft/factions/event/FactionsEventDescriptionChange.java b/src/com/massivecraft/factions/event/EventFactionsDescriptionChange.java similarity index 86% rename from src/com/massivecraft/factions/event/FactionsEventDescriptionChange.java rename to src/com/massivecraft/factions/event/EventFactionsDescriptionChange.java index 49578143..dc9585b4 100644 --- a/src/com/massivecraft/factions/event/FactionsEventDescriptionChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsDescriptionChange.java @@ -5,7 +5,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.Faction; -public class FactionsEventDescriptionChange extends FactionsEventAbstractSender +public class EventFactionsDescriptionChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -30,7 +30,7 @@ public class FactionsEventDescriptionChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventDescriptionChange(CommandSender sender, Faction faction, String newDescription) + public EventFactionsDescriptionChange(CommandSender sender, Faction faction, String newDescription) { super(sender); this.faction = faction; diff --git a/src/com/massivecraft/factions/event/FactionsEventDisband.java b/src/com/massivecraft/factions/event/EventFactionsDisband.java similarity index 88% rename from src/com/massivecraft/factions/event/FactionsEventDisband.java rename to src/com/massivecraft/factions/event/EventFactionsDisband.java index fa649eaa..3ad112e9 100644 --- a/src/com/massivecraft/factions/event/FactionsEventDisband.java +++ b/src/com/massivecraft/factions/event/EventFactionsDisband.java @@ -5,7 +5,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.Faction; -public class FactionsEventDisband extends FactionsEventAbstractSender +public class EventFactionsDisband extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -29,7 +29,7 @@ public class FactionsEventDisband extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventDisband(CommandSender sender, Faction faction) + public EventFactionsDisband(CommandSender sender, Faction faction) { super(sender); this.faction = faction; diff --git a/src/com/massivecraft/factions/event/FactionsEventHomeChange.java b/src/com/massivecraft/factions/event/EventFactionsHomeChange.java similarity index 86% rename from src/com/massivecraft/factions/event/FactionsEventHomeChange.java rename to src/com/massivecraft/factions/event/EventFactionsHomeChange.java index 1ea45c63..3a6290fc 100644 --- a/src/com/massivecraft/factions/event/FactionsEventHomeChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsHomeChange.java @@ -6,7 +6,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.Faction; import com.massivecraft.massivecore.ps.PS; -public class FactionsEventHomeChange extends FactionsEventAbstractSender +public class EventFactionsHomeChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -31,7 +31,7 @@ public class FactionsEventHomeChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventHomeChange(CommandSender sender, Faction faction, PS newHome) + public EventFactionsHomeChange(CommandSender sender, Faction faction, PS newHome) { super(sender); this.faction = faction; diff --git a/src/com/massivecraft/factions/event/FactionsEventHomeTeleport.java b/src/com/massivecraft/factions/event/EventFactionsHomeTeleport.java similarity index 80% rename from src/com/massivecraft/factions/event/FactionsEventHomeTeleport.java rename to src/com/massivecraft/factions/event/EventFactionsHomeTeleport.java index 2bbfa566..e9264f2c 100644 --- a/src/com/massivecraft/factions/event/FactionsEventHomeTeleport.java +++ b/src/com/massivecraft/factions/event/EventFactionsHomeTeleport.java @@ -3,7 +3,7 @@ package com.massivecraft.factions.event; import org.bukkit.command.CommandSender; import org.bukkit.event.HandlerList; -public class FactionsEventHomeTeleport extends FactionsEventAbstractSender +public class EventFactionsHomeTeleport extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -17,7 +17,7 @@ public class FactionsEventHomeTeleport extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventHomeTeleport(CommandSender sender) + public EventFactionsHomeTeleport(CommandSender sender) { super(sender); } diff --git a/src/com/massivecraft/factions/event/FactionsEventInvitedChange.java b/src/com/massivecraft/factions/event/EventFactionsInvitedChange.java similarity index 91% rename from src/com/massivecraft/factions/event/FactionsEventInvitedChange.java rename to src/com/massivecraft/factions/event/EventFactionsInvitedChange.java index e082375b..93bcf62b 100644 --- a/src/com/massivecraft/factions/event/FactionsEventInvitedChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsInvitedChange.java @@ -6,7 +6,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.factions.entity.Faction; -public class FactionsEventInvitedChange extends FactionsEventAbstractSender +public class EventFactionsInvitedChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -34,7 +34,7 @@ public class FactionsEventInvitedChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventInvitedChange(CommandSender sender, UPlayer uplayer, Faction faction, boolean newInvited) + public EventFactionsInvitedChange(CommandSender sender, UPlayer uplayer, Faction faction, boolean newInvited) { super(sender); this.uplayer = uplayer; diff --git a/src/com/massivecraft/factions/event/FactionsEventMembershipChange.java b/src/com/massivecraft/factions/event/EventFactionsMembershipChange.java similarity index 93% rename from src/com/massivecraft/factions/event/FactionsEventMembershipChange.java rename to src/com/massivecraft/factions/event/EventFactionsMembershipChange.java index b0ab9e3e..402f2f8b 100644 --- a/src/com/massivecraft/factions/event/FactionsEventMembershipChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsMembershipChange.java @@ -6,7 +6,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.UPlayer; import com.massivecraft.factions.entity.Faction; -public class FactionsEventMembershipChange extends FactionsEventAbstractSender +public class EventFactionsMembershipChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -40,7 +40,7 @@ public class FactionsEventMembershipChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventMembershipChange(CommandSender sender, UPlayer uplayer, Faction newFaction, MembershipChangeReason reason) + public EventFactionsMembershipChange(CommandSender sender, UPlayer uplayer, Faction newFaction, MembershipChangeReason reason) { super(sender); this.uplayer = uplayer; diff --git a/src/com/massivecraft/factions/event/FactionsEventNameChange.java b/src/com/massivecraft/factions/event/EventFactionsNameChange.java similarity index 89% rename from src/com/massivecraft/factions/event/FactionsEventNameChange.java rename to src/com/massivecraft/factions/event/EventFactionsNameChange.java index d4c2abc2..4c5cadfb 100644 --- a/src/com/massivecraft/factions/event/FactionsEventNameChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsNameChange.java @@ -5,7 +5,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.Faction; -public class FactionsEventNameChange extends FactionsEventAbstractSender +public class EventFactionsNameChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -30,7 +30,7 @@ public class FactionsEventNameChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventNameChange(CommandSender sender, Faction faction, String newName) + public EventFactionsNameChange(CommandSender sender, Faction faction, String newName) { super(sender); this.faction = faction; diff --git a/src/com/massivecraft/factions/event/FactionsEventOpenChange.java b/src/com/massivecraft/factions/event/EventFactionsOpenChange.java similarity index 86% rename from src/com/massivecraft/factions/event/FactionsEventOpenChange.java rename to src/com/massivecraft/factions/event/EventFactionsOpenChange.java index f931de78..b6758f4e 100644 --- a/src/com/massivecraft/factions/event/FactionsEventOpenChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsOpenChange.java @@ -5,7 +5,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.Faction; -public class FactionsEventOpenChange extends FactionsEventAbstractSender +public class EventFactionsOpenChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -30,7 +30,7 @@ public class FactionsEventOpenChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventOpenChange(CommandSender sender, Faction faction, boolean newOpen) + public EventFactionsOpenChange(CommandSender sender, Faction faction, boolean newOpen) { super(sender); this.faction = faction; diff --git a/src/com/massivecraft/factions/event/FactionsEventPowerChange.java b/src/com/massivecraft/factions/event/EventFactionsPowerChange.java similarity index 91% rename from src/com/massivecraft/factions/event/FactionsEventPowerChange.java rename to src/com/massivecraft/factions/event/EventFactionsPowerChange.java index 59380a2e..0361086c 100644 --- a/src/com/massivecraft/factions/event/FactionsEventPowerChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsPowerChange.java @@ -5,7 +5,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.UPlayer; -public class FactionsEventPowerChange extends FactionsEventAbstractSender +public class EventFactionsPowerChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -33,7 +33,7 @@ public class FactionsEventPowerChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventPowerChange(CommandSender sender, UPlayer uplayer, PowerChangeReason reason, double newPower) + public EventFactionsPowerChange(CommandSender sender, UPlayer uplayer, PowerChangeReason reason, double newPower) { super(sender); this.uplayer = uplayer; diff --git a/src/com/massivecraft/factions/event/FactionsEventPvpDisallowed.java b/src/com/massivecraft/factions/event/EventFactionsPvpDisallowed.java similarity index 93% rename from src/com/massivecraft/factions/event/FactionsEventPvpDisallowed.java rename to src/com/massivecraft/factions/event/EventFactionsPvpDisallowed.java index 2a211881..23ab32f6 100644 --- a/src/com/massivecraft/factions/event/FactionsEventPvpDisallowed.java +++ b/src/com/massivecraft/factions/event/EventFactionsPvpDisallowed.java @@ -13,7 +13,7 @@ import com.massivecraft.factions.entity.UPlayer; * Note that the defender field always is set but the attacker can be null. * Some other plugins seem to fire EntityDamageByEntityEvent without an attacker. */ -public class FactionsEventPvpDisallowed extends FactionsEventAbstract +public class EventFactionsPvpDisallowed extends EventFactionsAbstract { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -42,7 +42,7 @@ public class FactionsEventPvpDisallowed extends FactionsEventAbstract // CONSTRUCT // -------------------------------------------- // - public FactionsEventPvpDisallowed(Player attacker, Player defender, EntityDamageByEntityEvent event) + public EventFactionsPvpDisallowed(Player attacker, Player defender, EntityDamageByEntityEvent event) { this.attacker = attacker; this.defender = defender; diff --git a/src/com/massivecraft/factions/event/FactionsEventRelationChange.java b/src/com/massivecraft/factions/event/EventFactionsRelationChange.java similarity index 91% rename from src/com/massivecraft/factions/event/FactionsEventRelationChange.java rename to src/com/massivecraft/factions/event/EventFactionsRelationChange.java index a46aacf1..99625ea7 100644 --- a/src/com/massivecraft/factions/event/FactionsEventRelationChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsRelationChange.java @@ -7,7 +7,7 @@ import com.massivecraft.factions.Rel; import com.massivecraft.factions.entity.Faction; -public class FactionsEventRelationChange extends FactionsEventAbstractSender +public class EventFactionsRelationChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -35,7 +35,7 @@ public class FactionsEventRelationChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventRelationChange(CommandSender sender, Faction faction, Faction otherFaction, Rel newRelation) + public EventFactionsRelationChange(CommandSender sender, Faction faction, Faction otherFaction, Rel newRelation) { super(sender); this.faction = faction; diff --git a/src/com/massivecraft/factions/event/FactionsEventTitleChange.java b/src/com/massivecraft/factions/event/EventFactionsTitleChange.java similarity index 86% rename from src/com/massivecraft/factions/event/FactionsEventTitleChange.java rename to src/com/massivecraft/factions/event/EventFactionsTitleChange.java index b690631b..edcf7043 100644 --- a/src/com/massivecraft/factions/event/FactionsEventTitleChange.java +++ b/src/com/massivecraft/factions/event/EventFactionsTitleChange.java @@ -5,7 +5,7 @@ import org.bukkit.event.HandlerList; import com.massivecraft.factions.entity.UPlayer; -public class FactionsEventTitleChange extends FactionsEventAbstractSender +public class EventFactionsTitleChange extends EventFactionsAbstractSender { // -------------------------------------------- // // REQUIRED EVENT CODE @@ -30,7 +30,7 @@ public class FactionsEventTitleChange extends FactionsEventAbstractSender // CONSTRUCT // -------------------------------------------- // - public FactionsEventTitleChange(CommandSender sender, UPlayer uplayer, String newTitle) + public EventFactionsTitleChange(CommandSender sender, UPlayer uplayer, String newTitle) { super(sender); this.uplayer = uplayer; diff --git a/src/com/massivecraft/factions/integration/lwc/EngineLwc.java b/src/com/massivecraft/factions/integration/lwc/EngineLwc.java index fce83d94..c484cf5a 100644 --- a/src/com/massivecraft/factions/integration/lwc/EngineLwc.java +++ b/src/com/massivecraft/factions/integration/lwc/EngineLwc.java @@ -19,8 +19,8 @@ import com.massivecraft.factions.Factions; import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.UConf; import com.massivecraft.factions.entity.UPlayer; -import com.massivecraft.factions.event.FactionsEventChunkChange; -import com.massivecraft.factions.event.FactionsEventChunkChangeType; +import com.massivecraft.factions.event.EventFactionsChunkChange; +import com.massivecraft.factions.event.EventFactionsChunkChangeType; import com.massivecraft.massivecore.ps.PS; @@ -53,12 +53,12 @@ public class EngineLwc implements Listener // -------------------------------------------- // @EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true) - public void removeProtectionsOnChunkChange(FactionsEventChunkChange event) + public void removeProtectionsOnChunkChange(EventFactionsChunkChange event) { // If we are supposed to clear at this chunk change type ... Faction newFaction = event.getNewFaction(); UConf uconf = UConf.get(newFaction); - FactionsEventChunkChangeType type = event.getType(); + EventFactionsChunkChangeType type = event.getType(); Boolean remove = uconf.lwcRemoveOnChange.get(type); if (remove == null) return; if (remove == false) return; diff --git a/src/com/massivecraft/factions/listeners/FactionsListenerEcon.java b/src/com/massivecraft/factions/listeners/FactionsListenerEcon.java index dfdb1175..9ba35a97 100644 --- a/src/com/massivecraft/factions/listeners/FactionsListenerEcon.java +++ b/src/com/massivecraft/factions/listeners/FactionsListenerEcon.java @@ -9,21 +9,21 @@ import com.massivecraft.factions.Factions; import com.massivecraft.factions.entity.Faction; import com.massivecraft.factions.entity.UConf; import com.massivecraft.factions.entity.UPlayer; -import com.massivecraft.factions.event.FactionsEventAbstractSender; -import com.massivecraft.factions.event.FactionsEventChunkChange; -import com.massivecraft.factions.event.FactionsEventChunkChangeType; -import com.massivecraft.factions.event.FactionsEventCreate; -import com.massivecraft.factions.event.FactionsEventDescriptionChange; -import com.massivecraft.factions.event.FactionsEventDisband; -import com.massivecraft.factions.event.FactionsEventHomeChange; -import com.massivecraft.factions.event.FactionsEventHomeTeleport; -import com.massivecraft.factions.event.FactionsEventInvitedChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange; -import com.massivecraft.factions.event.FactionsEventMembershipChange.MembershipChangeReason; -import com.massivecraft.factions.event.FactionsEventOpenChange; -import com.massivecraft.factions.event.FactionsEventRelationChange; -import com.massivecraft.factions.event.FactionsEventNameChange; -import com.massivecraft.factions.event.FactionsEventTitleChange; +import com.massivecraft.factions.event.EventFactionsAbstractSender; +import com.massivecraft.factions.event.EventFactionsChunkChange; +import com.massivecraft.factions.event.EventFactionsChunkChangeType; +import com.massivecraft.factions.event.EventFactionsCreate; +import com.massivecraft.factions.event.EventFactionsDescriptionChange; +import com.massivecraft.factions.event.EventFactionsDisband; +import com.massivecraft.factions.event.EventFactionsHomeChange; +import com.massivecraft.factions.event.EventFactionsHomeTeleport; +import com.massivecraft.factions.event.EventFactionsInvitedChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange; +import com.massivecraft.factions.event.EventFactionsMembershipChange.MembershipChangeReason; +import com.massivecraft.factions.event.EventFactionsNameChange; +import com.massivecraft.factions.event.EventFactionsOpenChange; +import com.massivecraft.factions.event.EventFactionsRelationChange; +import com.massivecraft.factions.event.EventFactionsTitleChange; import com.massivecraft.factions.integration.Econ; import com.massivecraft.massivecore.money.Money; @@ -51,7 +51,7 @@ public class FactionsListenerEcon implements Listener // -------------------------------------------- // @EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true) - public void takeOnLeave(FactionsEventMembershipChange event) + public void takeOnLeave(EventFactionsMembershipChange event) { // If a player is leaving the faction ... if (event.getReason() != MembershipChangeReason.LEAVE) return; @@ -70,7 +70,7 @@ public class FactionsListenerEcon implements Listener // -------------------------------------------- // @EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true) - public void takeOnDisband(FactionsEventDisband event) + public void takeOnDisband(EventFactionsDisband event) { // If there is a usender ... UPlayer usender = event.getUSender(); @@ -95,7 +95,7 @@ public class FactionsListenerEcon implements Listener // PAY FOR ACTION // -------------------------------------------- // - public static void payForAction(FactionsEventAbstractSender event, Double cost, String desc) + public static void payForAction(EventFactionsAbstractSender event, Double cost, String desc) { // If there is a sender ... UPlayer usender = event.getUSender(); @@ -113,11 +113,11 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForAction(FactionsEventChunkChange event) + public void payForAction(EventFactionsChunkChange event) { Faction newFaction = event.getNewFaction(); UConf uconf = UConf.get(newFaction); - FactionsEventChunkChangeType type = event.getType(); + EventFactionsChunkChangeType type = event.getType(); Double cost = uconf.econChunkCost.get(type); String desc = type.toString().toLowerCase() + " this land"; @@ -126,7 +126,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForAction(FactionsEventMembershipChange event) + public void payForAction(EventFactionsMembershipChange event) { Double cost = null; String desc = null; @@ -158,7 +158,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventRelationChange event) + public void payForCommand(EventFactionsRelationChange event) { Double cost = UConf.get(event.getSender()).econRelCost.get(event.getNewRelation()); String desc = Factions.get().getOuterCmdFactions().cmdFactionsRelationNeutral.getDesc(); @@ -167,7 +167,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventHomeChange event) + public void payForCommand(EventFactionsHomeChange event) { Double cost = UConf.get(event.getSender()).econCostSethome; String desc = Factions.get().getOuterCmdFactions().cmdFactionsSethome.getDesc(); @@ -176,7 +176,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventCreate event) + public void payForCommand(EventFactionsCreate event) { Double cost = UConf.get(event.getSender()).econCostCreate; String desc = Factions.get().getOuterCmdFactions().cmdFactionsCreate.getDesc(); @@ -185,7 +185,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventDescriptionChange event) + public void payForCommand(EventFactionsDescriptionChange event) { Double cost = UConf.get(event.getSender()).econCostDescription; String desc = Factions.get().getOuterCmdFactions().cmdFactionsDescription.getDesc(); @@ -194,7 +194,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventNameChange event) + public void payForCommand(EventFactionsNameChange event) { Double cost = UConf.get(event.getSender()).econCostName; String desc = Factions.get().getOuterCmdFactions().cmdFactionsName.getDesc(); @@ -203,7 +203,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventTitleChange event) + public void payForCommand(EventFactionsTitleChange event) { Double cost = UConf.get(event.getSender()).econCostTitle; String desc = Factions.get().getOuterCmdFactions().cmdFactionsTitle.getDesc(); @@ -212,7 +212,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventOpenChange event) + public void payForCommand(EventFactionsOpenChange event) { Double cost = UConf.get(event.getSender()).econCostOpen; String desc = Factions.get().getOuterCmdFactions().cmdFactionsOpen.getDesc(); @@ -221,7 +221,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventInvitedChange event) + public void payForCommand(EventFactionsInvitedChange event) { Double cost = event.isNewInvited() ? UConf.get(event.getSender()).econCostInvite : UConf.get(event.getSender()).econCostDeinvite; String desc = Factions.get().getOuterCmdFactions().cmdFactionsInvite.getDesc(); @@ -230,7 +230,7 @@ public class FactionsListenerEcon implements Listener } @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) - public void payForCommand(FactionsEventHomeTeleport event) + public void payForCommand(EventFactionsHomeTeleport event) { Double cost = UConf.get(event.getSender()).econCostHome; String desc = Factions.get().getOuterCmdFactions().cmdFactionsHome.getDesc(); diff --git a/src/com/massivecraft/factions/listeners/FactionsListenerMain.java b/src/com/massivecraft/factions/listeners/FactionsListenerMain.java index b6cd8994..2a020a3b 100644 --- a/src/com/massivecraft/factions/listeners/FactionsListenerMain.java +++ b/src/com/massivecraft/factions/listeners/FactionsListenerMain.java @@ -66,9 +66,9 @@ import com.massivecraft.factions.entity.MConf; import com.massivecraft.factions.entity.UConf; import com.massivecraft.factions.entity.UPlayerColl; import com.massivecraft.factions.entity.UPlayerColls; -import com.massivecraft.factions.event.FactionsEventPvpDisallowed; -import com.massivecraft.factions.event.FactionsEventPowerChange; -import com.massivecraft.factions.event.FactionsEventPowerChange.PowerChangeReason; +import com.massivecraft.factions.event.EventFactionsPvpDisallowed; +import com.massivecraft.factions.event.EventFactionsPowerChange; +import com.massivecraft.factions.event.EventFactionsPowerChange.PowerChangeReason; import com.massivecraft.factions.util.VisualizeUtil; import com.massivecraft.massivecore.ps.PS; import com.massivecraft.massivecore.util.MUtil; @@ -218,7 +218,7 @@ public class FactionsListenerMain implements Listener // ... alter the power ... double newPower = uplayer.getPower() + uplayer.getPowerPerDeath(); - FactionsEventPowerChange powerChangeEvent = new FactionsEventPowerChange(null, uplayer, PowerChangeReason.DEATH, newPower); + EventFactionsPowerChange powerChangeEvent = new EventFactionsPowerChange(null, uplayer, PowerChangeReason.DEATH, newPower); powerChangeEvent.run(); if (powerChangeEvent.isCancelled()) return; newPower = powerChangeEvent.getNewPower(); @@ -279,7 +279,7 @@ public class FactionsListenerMain implements Listener // Utility method used in "canCombatDamageHappen" below. public static boolean falseUnlessDisallowedPvpEventCancelled(Player attacker, Player defender, EntityDamageByEntityEvent event) { - FactionsEventPvpDisallowed dpe = new FactionsEventPvpDisallowed(attacker, defender, event); + EventFactionsPvpDisallowed dpe = new EventFactionsPvpDisallowed(attacker, defender, event); dpe.run(); return dpe.isCancelled(); } diff --git a/src/com/massivecraft/factions/task/TaskPlayerPowerUpdate.java b/src/com/massivecraft/factions/task/TaskPlayerPowerUpdate.java index 12c79e0f..ac1d8885 100644 --- a/src/com/massivecraft/factions/task/TaskPlayerPowerUpdate.java +++ b/src/com/massivecraft/factions/task/TaskPlayerPowerUpdate.java @@ -6,8 +6,8 @@ import org.bukkit.entity.Player; import com.massivecraft.factions.entity.MConf; import com.massivecraft.factions.entity.UConf; import com.massivecraft.factions.entity.UPlayer; -import com.massivecraft.factions.event.FactionsEventPowerChange; -import com.massivecraft.factions.event.FactionsEventPowerChange.PowerChangeReason; +import com.massivecraft.factions.event.EventFactionsPowerChange; +import com.massivecraft.factions.event.EventFactionsPowerChange.PowerChangeReason; import com.massivecraft.massivecore.ModuloRepeatTask; import com.massivecraft.massivecore.util.TimeUnit; @@ -51,7 +51,7 @@ public class TaskPlayerPowerUpdate extends ModuloRepeatTask UPlayer uplayer = UPlayer.get(player); double newPower = uplayer.getPower() + uplayer.getPowerPerHour() * millis / TimeUnit.MILLIS_PER_HOUR; - FactionsEventPowerChange event = new FactionsEventPowerChange(null, uplayer, PowerChangeReason.TIME, newPower); + EventFactionsPowerChange event = new EventFactionsPowerChange(null, uplayer, PowerChangeReason.TIME, newPower); event.run(); if (event.isCancelled()) continue; newPower = event.getNewPower();