Skip to content

Commit

Permalink
Update 2.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
AlessioDP committed Jan 23, 2019
1 parent f0cd1b3 commit 7b4a7c1
Show file tree
Hide file tree
Showing 145 changed files with 2,156 additions and 1,548 deletions.
2 changes: 1 addition & 1 deletion api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>com.alessiodp.parties</groupId>
<artifactId>Parties</artifactId>
<version>2.4.7</version>
<version>2.5.0</version>
</parent>

<artifactId>parties-api</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@
public interface Cancellable {
/**
* Is the event cancelled?
*
*
* @return Returns {@code true} if the event is cancelled
*/
boolean isCancelled();

/**
* Set the event as cancelled
*
*
* @param cancel {@code True} to cancel
*/
void setCancelled(boolean cancel);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ public interface PartiesEvent {

/**
* Set the Parties API instance. Used by Parties instance to let you hook directly to the main API.
*
* @param instance {@link PartiesAPI} instance to set
*/
void setApi(PartiesAPI instance);
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@

public abstract class BukkitPartiesPlayerPostLeaveEvent extends BukkitPartiesEvent implements IPlayerPostLeaveEvent {
// Dummy class

}
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@

public abstract class BukkitPartiesPlayerPreLeaveEvent extends BukkitPartiesEvent implements IPlayerPreLeaveEvent {
// Dummy class

}
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@
public abstract class BukkitPartiesCombustFriendlyFireBlockedEvent extends BukkitPartiesEvent implements Cancellable {
/**
* Get the victim of the event
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
public abstract PartyPlayer getPlayerVictim();

/**
* Get the attacker
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
public abstract PartyPlayer getPlayerAttacker();

/**
* Get the original Bukkit event handled by Parties
*
*
* @return Returns the original {@link EntityCombustByEntityEvent}
*/
@NotNull
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,23 @@
public abstract class BukkitPartiesFriendlyFireBlockedEvent extends BukkitPartiesEvent implements Cancellable {
/**
* Get the victim of the event
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
public abstract PartyPlayer getPlayerVictim();

/**
* Get the attacker
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
public abstract PartyPlayer getPlayerAttacker();

/**
* Get the original Bukkit event handled by Parties
*
*
* @return Returns the original {@link EntityDamageByEntityEvent}, or {@code null} if there is no bukkit event
*/
@Nullable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@
public abstract class BukkitPartiesPotionsFriendlyFireBlockedEvent extends BukkitPartiesEvent implements Cancellable {
/**
* Get the victim of the event
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
public abstract PartyPlayer getPlayerVictim();

/**
* Get the attacker
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
public abstract PartyPlayer getPlayerAttacker();

/**
* Gets the original Bukkit event handled by Parties
*
*
* @return Returns the original {@link PotionSplashEvent}
*/
@NotNull
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@

public abstract class BungeePartiesPlayerPostLeaveEvent extends BungeePartiesEvent implements IPlayerPostLeaveEvent {
// Dummy class

}
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@

public abstract class BungeePartiesPlayerPreLeaveEvent extends BungeePartiesEvent implements IPlayerPreLeaveEvent {
// Dummy class

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package com.alessiodp.parties.api.events.bungee.unique;

import com.alessiodp.parties.api.events.Cancellable;
import com.alessiodp.parties.api.events.bungee.BungeePartiesEvent;
import com.alessiodp.parties.api.interfaces.Party;
import org.jetbrains.annotations.NotNull;

public abstract class BungeePartiesPartyFollowEvent extends BungeePartiesEvent implements Cancellable {
/**
* Get the party
*
* @return Returns the {@link Party}
*/
@NotNull
public abstract Party getParty();

/**
* Get the name of the server that the party will join into
*
* @return Returns the name of the server
*/
@NotNull
public abstract String getJoinedServer();
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
public interface IPartyPostCreateEvent extends PartiesEvent {
/**
* Get the creator of the party
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
PartyPlayer getCreator();

/**
* Get the party
*
*
* @return Returns the {@link Party}
*/
@NotNull
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,35 +10,35 @@
public interface IPartyPostDeleteEvent extends PartiesEvent {
/**
* Get the deleted party name
*
*
* @return Returns the name of the deleted party
*/
@NotNull
String getPartyName();

/**
* Get the delete cause
*
*
* @return Returns the {@link DeleteCause} of the delete
*/
@NotNull
DeleteCause getCause();

/**
* Get the kicked player
*
*
* @return Returns the {@link PartyPlayer} of the kicked player, returns
* {@code null} if the delete cause is {@link DeleteCause#DELETE} or
* {@link DeleteCause#TIMEOUT}
* {@code null} if the delete cause is {@link DeleteCause#DELETE} or
* {@link DeleteCause#TIMEOUT}
*/
@Nullable
PartyPlayer getKickedPlayer();

/**
* Get the player who performed the command
*
*
* @return Returns the {@link PartyPlayer} who did the command, returns
* {@code null} if the delete cause is {@link DeleteCause#TIMEOUT}
* {@code null} if the delete cause is {@link DeleteCause#TIMEOUT}
*/
@Nullable
PartyPlayer getCommandSender();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,47 +1,45 @@
package com.alessiodp.parties.api.events.common.party;

import com.alessiodp.parties.api.events.Cancellable;
import com.alessiodp.parties.api.events.PartiesEvent;
import com.alessiodp.parties.api.interfaces.PartyPlayer;
import com.alessiodp.parties.api.events.Cancellable;
import org.jetbrains.annotations.NotNull;

public interface IPartyPreCreateEvent extends PartiesEvent, Cancellable {
/**
* Get the player that is creating the party
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
PartyPlayer getPartyPlayer();

/**
* Get the name of the party
*
*
* @return Returns the party name
*/
@NotNull
String getPartyName();

/**
* Set a new name to the party
*
* @param name
* The name to set
*
* @param name The name to set
*/
void setPartyName(String name);

/**
* Is the party fixed?
*
*
* @return Returns {@code true} if it's fixed
*/
boolean isFixed();

/**
* Set if the party is fixed
*
* @param fixed
* {@code True} to be fixed
*
* @param fixed {@code True} to be fixed
*/
void setFixed(boolean fixed);
}
Original file line number Diff line number Diff line change
@@ -1,45 +1,45 @@
package com.alessiodp.parties.api.events.common.party;

import com.alessiodp.parties.api.enums.DeleteCause;
import com.alessiodp.parties.api.events.Cancellable;
import com.alessiodp.parties.api.events.PartiesEvent;
import com.alessiodp.parties.api.interfaces.Party;
import com.alessiodp.parties.api.interfaces.PartyPlayer;
import com.alessiodp.parties.api.events.Cancellable;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

public interface IPartyPreDeleteEvent extends PartiesEvent, Cancellable {
/**
* Get the party that is getting cancelled
*
*
* @return Returns the the {@link Party}
*/
@NotNull
Party getParty();

/**
* Get the cause of delete
*
*
* @return Returns the {@link DeleteCause} of the delete
*/
@NotNull
DeleteCause getCause();

/**
* Get the kicked player
*
*
* @return Returns the {@link PartyPlayer} of the kicked player, returns {@code null}
* if the delete cause is {@link DeleteCause#DELETE} or
* {@link DeleteCause#TIMEOUT}
* if the delete cause is {@link DeleteCause#DELETE} or
* {@link DeleteCause#TIMEOUT}
*/
@Nullable
PartyPlayer getKickedPlayer();

/**
* Get the player who performed the command
*
*
* @return Returns the {@link PartyPlayer} who did the command, returns
* {@code null} if the delete cause is {@link DeleteCause#TIMEOUT}
* {@code null} if the delete cause is {@link DeleteCause#TIMEOUT}
*/
@Nullable
PartyPlayer getCommandSender();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,46 +1,46 @@
package com.alessiodp.parties.api.events.common.party;

import com.alessiodp.parties.api.events.Cancellable;
import com.alessiodp.parties.api.events.PartiesEvent;
import com.alessiodp.parties.api.interfaces.Party;
import com.alessiodp.parties.api.interfaces.PartyPlayer;
import com.alessiodp.parties.api.events.Cancellable;
import org.jetbrains.annotations.NotNull;

public interface IPartyRenameEvent extends PartiesEvent, Cancellable {
/** Get the party that is getting renamed
*
/**
* Get the party that is getting renamed
*
* @return Returns the {@link Party}
*/
@NotNull
Party getParty();

/**
* Get the new party name
*
*
* @return Returns the new name of the party
*/
@NotNull
String getNewPartyName();

/**
* Set the new name of the party
*
* @param name
* The party name to set
*
* @param name The party name to set
*/
void setNewPartyName(String name);

/**
* Get the player who performed the command
*
*
* @return Returns the {@link PartyPlayer}
*/
@NotNull
PartyPlayer getPartyPlayer();

/**
* Is it an admin renaming?
*
*
* @return Returns {@code true} if the rename has been performed by an admin
*/
boolean isAdmin();
Expand Down
Loading

0 comments on commit 7b4a7c1

Please sign in to comment.