Skip to content

Commit

Permalink
Version 2.2-RC1
Browse files Browse the repository at this point in the history
  • Loading branch information
JustBru00 committed Mar 31, 2024
1 parent 59940d0 commit 6702489
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 16 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<groupId>com.andurilunlogic</groupId>
<artifactId>flyspeed</artifactId>
<version>2.2-SNAPSHOT</version>
<version>2.2-RC1</version>
<packaging>jar</packaging>

<name>flyspeed</name>
Expand Down
4 changes: 3 additions & 1 deletion src/com/andurilunlogic/flyspeed/commands/FlyCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,10 @@ public boolean onCommand(@NotNull CommandSender sender, @NotNull Command command

p.sendMessage(prefix + flightDisabled);

if (p != target)
if (p != target) {
target.sendMessage(prefix + flightDisabled);
}
return true;
} else {
for (String s : plugin.getConfig().getConfigurationSection("default-speed").getKeys(false)) {
if (target.hasPermission(plugin.getConfig().getString("default-speed." + s + ".permission"))
Expand Down
14 changes: 7 additions & 7 deletions src/com/andurilunlogic/flyspeed/commands/FlySpeedCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@ public boolean onCommand(@NotNull CommandSender sender, @NotNull Command command
return true;
}

Player p = (Player) sender;

if (!p.hasPermission("flyspeed.flyspeed")) {
p.sendMessage(prefix + noPermission);
return true;
}
Player p = (Player) sender;

if (args.length == 0) {
if (!p.hasPermission("flyspeed.flyspeed")) {
p.sendMessage(prefix + noPermission);
return true;
}

float fspeedn = p.getFlySpeed();
float fspeed = fspeedn * 10.0F;
p.sendMessage(prefix + ChatColor.GOLD + "Your flyspeed is: " + fspeed);
Expand Down Expand Up @@ -165,7 +165,7 @@ private static void sendPluginInfo(Player p) {
p.sendMessage("");
p.sendMessage(ChatColor.GOLD + "======================================================================");
p.sendMessage(ChatColor.DARK_AQUA + "[FlySpeed]" + ChatColor.GOLD + " Version: " + pdf.getVersion());
p.sendMessage(ChatColor.DARK_AQUA + "Author: " + ChatColor.GOLD + "AndurilUnlogic");
p.sendMessage(ChatColor.DARK_AQUA + "Author: " + ChatColor.GOLD + "AndurilUnlogic, JustBru00");
p.sendMessage(ChatColor.DARK_AQUA + "Description: " + ChatColor.GOLD + pdf.getDescription());
p.sendMessage(ChatColor.DARK_AQUA + "Commands: " + ChatColor.GOLD
+ "Use '/flyspeed help' (or '/walkspeed help') to see a list of all commands");
Expand Down
11 changes: 6 additions & 5 deletions src/com/andurilunlogic/flyspeed/commands/SpeedCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ public boolean onCommand(@NotNull CommandSender sender, @NotNull Command command
Player p = (Player) sender;

if (p.isFlying()) {
if (!p.hasPermission("flyspeed.flyspeed")) {
p.sendMessage(prefix + noPermission);
return true;
}

if (args.length == 0) {
if (!p.hasPermission("flyspeed.flyspeed")) {
p.sendMessage(prefix + noPermission);
return true;
}

float fspeedn = p.getFlySpeed();
float fspeed = fspeedn * 10.0F;
p.sendMessage(prefix + ChatColor.GOLD + "Your flyspeed is: " + fspeed);
Expand All @@ -43,6 +43,7 @@ public boolean onCommand(@NotNull CommandSender sender, @NotNull Command command
p.sendMessage(prefix + noPermission);
return true;
}

p.setFlySpeed(0.1F);
p.sendMessage(prefix + ChatColor.GREEN + "Flyspeed set to default!");
return true;
Expand Down
4 changes: 2 additions & 2 deletions src/plugin.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
main: com.andurilunlogic.flyspeed.FlySpeedPlugin
name: FlySpeed
version: 2.2-SNAPSHOT
version: 2.2-RC1
authors: [AndurilUnlogic, JustBru00]
description: A simple plugin to change your fly and walkspeed.

Expand Down Expand Up @@ -45,4 +45,4 @@ permissions:
default: op
flyspeed.walkspeed.others:
usage: Permission to change the walkspeed of others
default: op
default: op

0 comments on commit 6702489

Please sign in to comment.