Added getPlayer to AttractionPreStatusChangeEvent
This commit is contained in:
parent
b319ef5088
commit
e69fd04282
135 changed files with 15 additions and 5 deletions
0
.gitignore
vendored
Normal file → Executable file
0
.gitignore
vendored
Normal file → Executable file
0
pom.xml
Normal file → Executable file
0
pom.xml
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/ThemePark.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/ThemePark.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ThemeParkAPI.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ThemeParkAPI.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/AttractionService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/AttractionService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/enums/Status.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/enums/Status.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/objects/Attraction.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/objects/Attraction.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/objects/Region.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/attraction/objects/Region.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/ConfigurationManager.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/ConfigurationManager.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/enums/StorageKey.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/enums/StorageKey.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/enums/StorageLocation.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/enums/StorageLocation.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/objects/Configuration.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/objects/Configuration.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/objects/ConfigurationUpdater.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/config/objects/ConfigurationUpdater.java
Normal file → Executable file
2
src/main/java/nl/iobyte/themepark/api/config/objects/JsonConfiguration.java
Normal file → Executable file
2
src/main/java/nl/iobyte/themepark/api/config/objects/JsonConfiguration.java
Normal file → Executable file
|
@ -10,9 +10,7 @@ import org.bukkit.configuration.file.FileConfiguration;
|
||||||
import org.bukkit.configuration.file.YamlConfiguration;
|
import org.bukkit.configuration.file.YamlConfiguration;
|
||||||
import org.jetbrains.annotations.NotNull;
|
import org.jetbrains.annotations.NotNull;
|
||||||
import org.yaml.snakeyaml.error.YAMLException;
|
import org.yaml.snakeyaml.error.YAMLException;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.FileNotFoundException;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
|
|
0
src/main/java/nl/iobyte/themepark/api/database/DatabaseService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/DatabaseService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/Database.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/Database.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/types/MySQLDatabase.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/types/MySQLDatabase.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/types/NullDatabase.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/types/NullDatabase.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/types/SQLiteDatabase.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/database/objects/types/SQLiteDatabase.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/EventDispatcher.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/EventDispatcher.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionCoverChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionCoverChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionCreateEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionCreateEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionDescriptionChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionDescriptionChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionLocationChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionLocationChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionNameChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionNameChangeEvent.java
Normal file → Executable file
11
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionPreStatusChangeEvent.java
Normal file → Executable file
11
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionPreStatusChangeEvent.java
Normal file → Executable file
|
@ -3,14 +3,21 @@ package nl.iobyte.themepark.api.event.attraction;
|
||||||
import nl.iobyte.themepark.api.attraction.enums.Status;
|
import nl.iobyte.themepark.api.attraction.enums.Status;
|
||||||
import nl.iobyte.themepark.api.attraction.objects.Attraction;
|
import nl.iobyte.themepark.api.attraction.objects.Attraction;
|
||||||
import nl.iobyte.themepark.api.event.objects.AttractionEvent;
|
import nl.iobyte.themepark.api.event.objects.AttractionEvent;
|
||||||
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.event.Cancellable;
|
import org.bukkit.event.Cancellable;
|
||||||
|
|
||||||
public class AttractionPreStatusChangeEvent extends AttractionEvent<Status> implements Cancellable {
|
public class AttractionPreStatusChangeEvent extends AttractionEvent<Status> implements Cancellable {
|
||||||
|
|
||||||
private boolean b;
|
private final Player player;
|
||||||
|
private boolean b = false;
|
||||||
|
|
||||||
public AttractionPreStatusChangeEvent(Attraction attraction, Status old, Status current) {
|
public AttractionPreStatusChangeEvent(Attraction attraction, Status old, Status current, Player player) {
|
||||||
super(attraction, old, current);
|
super(attraction, old, current);
|
||||||
|
this.player = player;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Player getPlayer() {
|
||||||
|
return player;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isCancelled() {
|
public boolean isCancelled() {
|
||||||
|
|
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionRegionChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionRegionChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionRemoveEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionRemoveEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionStatusChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/attraction/AttractionStatusChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/AttractionEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/AttractionEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/ChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/ChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/RegionEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/RegionEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/StatusEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/objects/StatusEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionCreateEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionCreateEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionMaterialChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionMaterialChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionNameChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionNameChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionRemoveEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/region/RegionRemoveEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/ridecount/RideCountAddEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/ridecount/RideCountAddEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/ridecount/RideCountTotalTypeChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/ridecount/RideCountTotalTypeChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusColorChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusColorChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusHexColorChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusHexColorChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusMaterialChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusMaterialChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusNameChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusNameChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusTeleportChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/event/status/StatusTeleportChangeEvent.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/DataLoadService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/DataLoadService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/interfaces/IDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/interfaces/IDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/DatabaseLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/DatabaseLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/MenuDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/MenuDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/SignDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/SignDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/StatusDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/load/objects/StatusDataLoader.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/MenuService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/MenuService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/MainMenu.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/MainMenu.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/StatusMenu.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/StatusMenu.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/actions/PageAction.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/actions/PageAction.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/actions/TPAction.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/actions/TPAction.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/CommandMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/CommandMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/JsonMessageMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/JsonMessageMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/PlainMessageMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/PlainMessageMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/StatusMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/menu/objects/handlers/StatusMenuHandler.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/message/MessageKey.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/message/MessageKey.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/message/Text.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/message/Text.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/RideCountService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/RideCountService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/enums/TotalType.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/enums/TotalType.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/objects/AttractionCount.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/objects/AttractionCount.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/objects/RideCount.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/objects/RideCount.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/objects/TopData.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/ridecount/objects/TopData.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sign/SignManager.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sign/SignManager.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sign/objects/StatusSign.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sign/objects/StatusSign.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/SyncService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/SyncService.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/enums/SyncType.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/enums/SyncType.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/interfaces/ISync.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/interfaces/ISync.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/objects/ConfigurationSync.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/objects/ConfigurationSync.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/objects/SignSync.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/api/sync/objects/SignSync.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/ThemeParkCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/ThemeParkCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/AttractionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/AttractionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/MaterialArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/MaterialArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/NoAttractionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/NoAttractionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/NoRegionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/NoRegionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/PlayerArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/PlayerArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/PlayersArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/PlayersArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/RegionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/arguments/RegionArgument.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/executors/ConsoleExecutor.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/executors/ConsoleExecutor.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/executors/PlayerExecutor.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/executors/PlayerExecutor.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/objects/Reflection.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/objects/Reflection.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/objects/SpigotPlayerSelector.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/objects/SpigotPlayerSelector.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/objects/WGManager.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/objects/WGManager.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/HelpCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/HelpCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/ItemCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/ItemCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/MenuCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/MenuCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionCommands.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionCommands.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionCoverCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionCoverCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionCreateCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionCreateCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionListCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionListCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionLocationCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionLocationCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionNameCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionNameCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionRegionCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionRegionCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionRemoveCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionRemoveCommand.java
Normal file → Executable file
7
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionStatusCommand.java
Normal file → Executable file
7
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionStatusCommand.java
Normal file → Executable file
|
@ -9,6 +9,8 @@ import nl.iobyte.themepark.api.attraction.objects.Attraction;
|
||||||
import nl.iobyte.themepark.api.event.attraction.AttractionPreStatusChangeEvent;
|
import nl.iobyte.themepark.api.event.attraction.AttractionPreStatusChangeEvent;
|
||||||
import nl.iobyte.themepark.api.message.Text;
|
import nl.iobyte.themepark.api.message.Text;
|
||||||
import nl.iobyte.themepark.commands.arguments.AttractionArgument;
|
import nl.iobyte.themepark.commands.arguments.AttractionArgument;
|
||||||
|
import org.bukkit.entity.Player;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
public class AttractionStatusCommand extends SubCommand {
|
public class AttractionStatusCommand extends SubCommand {
|
||||||
|
@ -25,10 +27,13 @@ public class AttractionStatusCommand extends SubCommand {
|
||||||
Attraction attraction = (Attraction) list.get(0);
|
Attraction attraction = (Attraction) list.get(0);
|
||||||
Status status = (Status) list.get(1);
|
Status status = (Status) list.get(1);
|
||||||
|
|
||||||
|
Player player = sender.getOriginal() instanceof Player ? (Player) sender.getOriginal() : null;
|
||||||
|
|
||||||
AttractionPreStatusChangeEvent event = new AttractionPreStatusChangeEvent(
|
AttractionPreStatusChangeEvent event = new AttractionPreStatusChangeEvent(
|
||||||
attraction,
|
attraction,
|
||||||
attraction.getStatus(),
|
attraction.getStatus(),
|
||||||
status
|
status,
|
||||||
|
player
|
||||||
);
|
);
|
||||||
ThemePark.getInstance().getAPI().getEventDispatcher().call(
|
ThemePark.getInstance().getAPI().getEventDispatcher().call(
|
||||||
event,
|
event,
|
||||||
|
|
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionWarpCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/attraction/AttractionWarpCommand.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/region/RegionCommands.java
Normal file → Executable file
0
src/main/java/nl/iobyte/themepark/commands/subcommands/region/RegionCommands.java
Normal file → Executable file
Some files were not shown because too many files have changed in this diff Show more
Reference in a new issue