Examples of run()


Examples of com.massivecraft.factions.event.FactionsEventHomeChange.run()

      return;
    }
   
    // Event
    FactionsEventHomeChange event = new FactionsEventHomeChange(sender, faction, newHome);
    event.run();
    if (event.isCancelled()) return;
    newHome = event.getNewHome();

    // Apply
    faction.setHome(newHome);
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventHomeTeleport.run()

      }
    }

    // Event
    FactionsEventHomeTeleport event = new FactionsEventHomeTeleport(sender);
    event.run();
    if (event.isCancelled()) return;
   
    // Apply
    try
    {
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventInvitedChange.run()

    // FPerm
    if ( ! FPerm.INVITE.has(usender, usenderFaction, true)) return;
   
    // Event
    FactionsEventInvitedChange event = new FactionsEventInvitedChange(sender, uplayer, usenderFaction, newInvited);
    event.run();
    if (event.isCancelled()) return;
    newInvited = event.isNewInvited();

    // Apply
    usenderFaction.setInvited(uplayer, newInvited);
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventMembershipChange.run()

   
    // 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);
      membershipChangeEvent.run();
    }

    // Inform all players
    for (UPlayer uplayer : UPlayerColls.get().get(usender).getAllOnline())
    {
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventNameChange.run()

      return;
    }

    // Event
    FactionsEventNameChange event = new FactionsEventNameChange(sender, usenderFaction, newName);
    event.run();
    if (event.isCancelled()) return;
    newName = event.getNewName();

    // Apply
    String oldName = usenderFaction.getName();
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventOpenChange.run()

    Boolean newOpen = this.arg(0, ARBoolean.get(), !usenderFaction.isOpen());
    if (newOpen == null) return;

    // Event
    FactionsEventOpenChange event = new FactionsEventOpenChange(sender, usenderFaction, newOpen);
    event.run();
    if (event.isCancelled()) return;
    newOpen = event.isNewOpen();
   
    // Apply
    usenderFaction.setOpen(newOpen);
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventPowerChange.run()

     
      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);
      event.run();
      if (event.isCancelled()) continue;
      newPower = event.getNewPower();
     
      uplayer.setPower(newPower);
    }
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventRelationChange.run()

      return;
    }
   
    // Event
    FactionsEventRelationChange event = new FactionsEventRelationChange(sender, usenderFaction, otherFaction, newRelation);
    event.run();
    if (event.isCancelled()) return;
    newRelation = event.getNewRelation();

    // try to set the new relation
    usenderFaction.setRelationWish(otherFaction, newRelation);
View Full Code Here

Examples of com.massivecraft.factions.event.FactionsEventTitleChange.run()

    // Verify
    if ( ! canIAdministerYou(usender, you)) return;

    // Event
    FactionsEventTitleChange event = new FactionsEventTitleChange(sender, you, newTitle);
    event.run();
    if (event.isCancelled()) return;
    newTitle = event.getNewTitle();

    // Apply
    you.setTitle(newTitle);
View Full Code Here

Examples of com.massivecraft.mcore.event.MCorePermissionDeniedFormatEvent.run()

  }
 
  public static String getDeniedFormat(String perm)
  {
    MCorePermissionDeniedFormatEvent event = new MCorePermissionDeniedFormatEvent(perm);
    event.run();
    String ret = event.getFormat();
    if (ret == null) ret = Lang.PERM_DEFAULT_DENIED_FORMAT;
    return ret;
  }
  public static String getDeniedFormat(Permission perm)
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.