Skip to content

Commit

Permalink
Prepare For Release (2.8.0-pre1) (#6282)
Browse files Browse the repository at this point in the history
  • Loading branch information
APickledWalrus committed Jan 1, 2024
1 parent 97093ab commit 38cc0fe
Show file tree
Hide file tree
Showing 66 changed files with 81 additions and 81 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Expand Up @@ -5,7 +5,7 @@ org.gradle.parallel=true

groupid=ch.njol
name=skript
version=2.8.0-dev
version=2.8.0-pre1
jarName=Skript.jar
testEnv=java17/paper-1.20.4
testEnvJavaVersion=17
2 changes: 1 addition & 1 deletion skript-aliases
Submodule skript-aliases updated 1 files
+8 −1 decoration.sk
6 changes: 3 additions & 3 deletions src/main/java/ch/njol/skript/classes/data/BukkitClasses.java
Expand Up @@ -1533,21 +1533,21 @@ public String toVariableNameString(EnchantmentOffer eo) {
.name("Quit Reason")
.description("Represents a quit reason from a <a href='/events.html#quit'>player quit server event</a>.")
.requiredPlugins("Paper 1.16.5+")
.since("INSERT VERSION"));
.since("2.8.0"));

if (Skript.classExists("org.bukkit.event.inventory.InventoryCloseEvent$Reason"))
Classes.registerClass(new EnumClassInfo<>(InventoryCloseEvent.Reason.class, "inventoryclosereason", "inventory close reasons")
.user("inventory ?close ?reasons?")
.name("Inventory Close Reasons")
.description("The inventory close reason in an <a href='/events.html#inventory_close'>inventory close event</a>.")
.requiredPlugins("Paper")
.since("INSERT VERSION"));
.since("2.8.0"));

Classes.registerClass(new EnumClassInfo<>(TransformReason.class, "transformreason", "transform reasons")
.user("(entity)? ?transform ?(reason|cause)s?")
.name("Transform Reason")
.description("Represents a transform reason of an <a href='events.html#entity transform'>entity transform event</a>.")
.since("INSERT VERSION"));
.since("2.8.0"));
}

}
Expand Up @@ -336,7 +336,7 @@ public Number[] executeSimple(Object[][] params) {
"clamp(5, 7, 10) = 7",
"clamp((5, 0, 10, 9, 13), 7, 10) = (7, 7, 10, 9, 10)",
"set {_clamped::*} to clamp({_values::*}, 0, 10)")
.since("INSERT VERSION");
.since("2.8.0");

// misc

Expand Down Expand Up @@ -522,7 +522,7 @@ public Player[] executeSimple(Object[][] params) {
}
}).description("Returns an online player from their name or UUID, if player is offline function will return nothing.", "Setting 'getExactPlayer' parameter to true will return the player whose name is exactly equal to the provided name instead of returning a player that their name starts with the provided name.")
.examples("set {_p} to player(\"Notch\") # will return an online player whose name is or starts with 'Notch'", "set {_p} to player(\"Notch\", true) # will return the only online player whose name is 'Notch'", "set {_p} to player(\"069a79f4-44e9-4726-a5be-fca90e38aaf5\") # <none> if player is offline")
.since("INSERT VERSION");
.since("2.8.0");

Functions.registerFunction(new SimpleJavaFunction<OfflinePlayer>("offlineplayer", new Parameter[] {
new Parameter<>("nameOrUUID", DefaultClasses.STRING, true, null)
Expand All @@ -540,7 +540,7 @@ public OfflinePlayer[] executeSimple(Object[][] params) {
}
}).description("Returns a offline player from their name or UUID. This function will still return the player if they're online.")
.examples("set {_p} to offlineplayer(\"Notch\")", "set {_p} to offlineplayer(\"069a79f4-44e9-4726-a5be-fca90e38aaf5\")")
.since("INSERT VERSION");
.since("2.8.0");

Functions.registerFunction(new SimpleJavaFunction<Boolean>("isNaN", numberParam, DefaultClasses.BOOLEAN, true) {
@Override
Expand All @@ -549,7 +549,7 @@ public Boolean[] executeSimple(Object[][] params) {
}
}).description("Returns true if the input is NaN (not a number).")
.examples("isNaN(0) # false", "isNaN(0/0) # true", "isNaN(sqrt(-1)) # true")
.since("INSERT VERSION");
.since("2.8.0");
}

}
Expand Up @@ -35,7 +35,7 @@
"\tif player can't pick up items:",
"\t\tsend \"Be careful, you won't be able to pick that up!\" to player"
})
@Since("INSERT VERSION")
@Since("2.8.0")
public class CondCanPickUpItems extends PropertyCondition<LivingEntity> {

static {
Expand Down
Expand Up @@ -35,7 +35,7 @@
@Name("Has Glowing Text")
@Description("Checks whether a sign (either a block or an item) has glowing text")
@Examples("if target block has glowing text")
@Since("INSERT VERSION")
@Since("2.8.0")
public class CondGlowingText extends PropertyCondition<Object> {

static {
Expand Down
Expand Up @@ -40,7 +40,7 @@
"if player has player's tool on cooldown:",
"\tsend \"You can't use this item right now. Wait %item cooldown of player's tool for player%\""
})
@Since("INSERT VERSION")
@Since("2.8.0")
public class CondHasItemCooldown extends Condition {

static {
Expand Down
Expand Up @@ -40,7 +40,7 @@
"victim has line of sight to attacker",
"player has no line of sight to location 100 blocks in front of player"
})
@Since("INSERT VERSION")
@Since("2.8.0")
public class CondHasLineOfSight extends Condition {

static {
Expand Down
Expand Up @@ -37,7 +37,7 @@
"\tmessage\"The spider is now climbing!\""
})
@RequiredPlugins("Minecraft 1.17+")
@Since("INSERT VERSION")
@Since("2.8.0")
public class CondIsClimbing extends PropertyCondition<LivingEntity> {

static {
Expand Down
Expand Up @@ -44,7 +44,7 @@
"\t\tdrop player's tool at player",
"\t\tset player's tool to air"
})
@Since("INSERT VERSION")
@Since("2.8.0")
@RequiredPlugins("Paper")
public class CondIsHandRaised extends Condition {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/conditions/CondIsJumping.java
Expand Up @@ -40,7 +40,7 @@
"\t\twait 5 ticks",
"\tpush event-entity upwards"
})
@Since("INSERT VERSION")
@Since("2.8.0")
@RequiredPlugins("Paper 1.15+")
public class CondIsJumping extends PropertyCondition<LivingEntity> {

Expand Down
Expand Up @@ -43,7 +43,7 @@
"\tif victim is left handed:",
"\t\tcancel event"
})
@Since("INSERT VERSION")
@Since("2.8.0")
@RequiredPlugins("Paper 1.17.1+ (entities)")
public class CondIsLeftHanded extends PropertyCondition<LivingEntity> {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/conditions/CondIsSheared.java
Expand Up @@ -38,7 +38,7 @@
"if targeted entity of player is sheared:",
"\tsend \"This entity has nothing left to shear!\" to player"
})
@Since("INSERT VERSION")
@Since("2.8.0")
@RequiredPlugins("MC 1.13+ (cows, sheep & snowmen), Paper 1.19.4+ (all shearable entities)")
public class CondIsSheared extends PropertyCondition<LivingEntity> {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffApplyBoneMeal.java
Expand Up @@ -38,7 +38,7 @@
@Description("Applies bone meal to a crop, sapling, or composter")
@Examples("apply 3 bone meal to event-block")
@RequiredPlugins("MC 1.16.2+")
@Since("INSERT VERSION")
@Since("2.8.0")
public class EffApplyBoneMeal extends Effect {

static {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffCancelItemUse.java
Expand Up @@ -42,7 +42,7 @@
"\tif the victim's active tool is a bow:",
"\t\tinterrupt the usage of the player's active item"
})
@Since("INSERT VERSION")
@Since("2.8.0")
@RequiredPlugins("Paper 1.16+")
public class EffCancelItemUse extends Effect {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffCommand.java
Expand Up @@ -48,7 +48,7 @@
"execute console command \"/say Hello everyone!\"",
"execute player bungeecord command \"/alert &6Testing Announcement!\""
})
@Since("1.0, INSERT VERSION (bungeecord command)")
@Since("1.0, 2.8.0 (bungeecord command)")
public class EffCommand extends Effect {

public static final String MESSAGE_CHANNEL = "Message";
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffContinue.java
Expand Up @@ -55,7 +55,7 @@
"\t\tcontinue # only print when counter is 1, 2, 3, 5 or 10",
"\tbroadcast \"Game starting in %{_counter}% second(s)\"",
})
@Since("2.2-dev37, 2.7 (while loops), INSERT VERSION (outer loops)")
@Since("2.2-dev37, 2.7 (while loops), 2.8.0 (outer loops)")
public class EffContinue extends Effect {

static {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffCopy.java
Expand Up @@ -51,7 +51,7 @@
"broadcast {_copy::bar} # 1",
"broadcast {_copy::sublist::foobar} # \"hey!\""
})
@Since("INSERT VERSION")
@Since("2.8.0")
@Keywords({"clone", "variable", "list"})
public class EffCopy extends Effect {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffGlowingText.java
Expand Up @@ -40,7 +40,7 @@
@Name("Make Sign Glow")
@Description("Makes a sign (either a block or item) have glowing text or normal text")
@Examples("make target block of player have glowing text")
@Since("INSERT VERSION")
@Since("2.8.0")
public class EffGlowingText extends Effect {

static {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffHandedness.java
Expand Up @@ -41,7 +41,7 @@
"",
"make all zombies in radius 10 of player right handed"
})
@Since("INSERT VERSION")
@Since("2.8.0")
@RequiredPlugins("Paper 1.17.1+")
public class EffHandedness extends Effect {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffReturn.java
Expand Up @@ -48,7 +48,7 @@
"function divide(i: number) returns number:",
"\treturn {_i} / 2"
})
@Since("2.2, INSERT VERSION (returns aliases)")
@Since("2.2, 2.8.0 (returns aliases)")
public class EffReturn extends Effect {

static {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffShear.java
Expand Up @@ -50,7 +50,7 @@
"\tchance of 10%",
"\tforce shear the clicked sheep"
})
@Since("2.0 (cows, sheep & snowmen), INSERT VERSION (all shearable entities)")
@Since("2.0 (cows, sheep & snowmen), 2.8.0 (all shearable entities)")
@RequiredPlugins("Paper 1.19.4+ (all shearable entities)")
public class EffShear extends Effect {

Expand Down
Expand Up @@ -41,7 +41,7 @@
"\tif player can't pick up items:",
"\t\tallow player to pick up items"
})
@Since("INSERT VERSION")
@Since("2.8.0")
public class EffToggleCanPickUpItems extends Effect {

static {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffWorldLoad.java
Expand Up @@ -47,7 +47,7 @@
"unload \"world_the_end\" without saving",
"unload all worlds"
})
@Since("INSERT VERSION")
@Since("2.8.0")
public class EffWorldLoad extends Effect {

static {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/effects/EffWorldSave.java
Expand Up @@ -40,7 +40,7 @@
"save \"world_nether\"",
"save all worlds"
})
@Since("INSERT VERSION")
@Since("2.8.0")
public class EffWorldSave extends Effect {

static {
Expand Down
Expand Up @@ -54,7 +54,7 @@ public class EvtEntityBlockChange extends SkriptEvent {
"\tevent-entity is a falling dirt",
"\tcancel event"
)
.since("<i>unknown</i>, 2.5.2 (falling block), INSERT VERSION (any entity support)");
.since("<i>unknown</i>, 2.5.2 (falling block), 2.8.0 (any entity support)");
}

private enum ChangeEvent {
Expand Down
Expand Up @@ -40,7 +40,7 @@ public class EvtEntityTransform extends SkriptEvent {
"a mooshroom that when sheared, spawns a new cow.")
.examples("on a zombie transforming due to curing:", "on mooshroom transforming:", "on zombie, skeleton or slime transform:")
.keywords("entity transform")
.since("INSERT VERSION");
.since("2.8.0");
}

@Nullable
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/events/EvtGrow.java
Expand Up @@ -70,7 +70,7 @@ public class EvtGrow extends SkriptEvent {
"on grow of wheat, carrots, or potatoes:",
"on grow into tree, giant mushroom, cactus:",
"on grow from wheat[age=0] to wheat[age=1] or wheat[age=2]:")
.since("1.0, 2.2-dev20 (plants), INSERT VERSION (from, into, blockdata)");
.since("1.0, 2.2-dev20 (plants), 2.8.0 (from, into, blockdata)");
}

@Nullable
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/ch/njol/skript/events/EvtItem.java
Expand Up @@ -140,7 +140,7 @@ public class EvtItem extends SkriptEvent {
"on inventory item move:",
"\tbroadcast \"%holder of past event-inventory% is transporting %event-item% to %holder of event-inventory%!\""
)
.since("INSERT VERSION");
.since("2.8.0");
if (HAS_PLAYER_STONECUTTER_RECIPE_SELECT_EVENT) {
Skript.registerEvent("Stonecutter Recipe Select", EvtItem.class, PlayerStonecutterRecipeSelectEvent.class, "stonecutting [[of] %-itemtypes%]")
.description("Called when a player selects a recipe in a stonecutter.")
Expand All @@ -151,7 +151,7 @@ public class EvtItem extends SkriptEvent {
"on stonecutting:",
"\tbroadcast \"%player% is using stonecutter to craft %event-item%!\""
)
.since("INSERT VERSION")
.since("2.8.0")
.requiredPlugins("Paper 1.16+");
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ch/njol/skript/events/EvtMove.java
Expand Up @@ -59,7 +59,7 @@ public class EvtMove extends SkriptEvent {
"on player turning around:",
"send action bar \"You are currently turning your head around!\" to player")
.requiredPlugins("Paper 1.16.5+ (entity move)")
.since("2.6, INSERT VERSION (turn around)");
.since("2.6, 2.8.0 (turn around)");
}

private EntityData<?> entityData;
Expand Down
Expand Up @@ -46,7 +46,7 @@ public class EvtPlayerCommandSend extends SkriptEvent {
"\tset command list to command list where [input does not contain \":\"]",
"\tremove \"help\" from command list"
)
.since("INSERT VERSION");
.since("2.8.0");
}

private final Collection<String> originalCommands = new ArrayList<>();
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/ch/njol/skript/events/EvtWorld.java
Expand Up @@ -41,31 +41,31 @@ public class EvtWorld extends SkriptEvent {
.examples(
"on world save of \"world\":",
"\tbroadcast \"The world %event-world% has been saved\"")
.since("1.0, INSERT VERSION (defining worlds)");
.since("1.0, 2.8.0 (defining worlds)");

// World Init Event
Skript.registerEvent("World Init", EvtWorld.class, WorldInitEvent.class, "world init[ialization] [of %-worlds%]")
.description("Called when a world is initialized. As all default worlds are initialized before",
"any scripts are loaded, this event is only called for newly created worlds.",
"World management plugins might change the behaviour of this event though.")
.examples("on world init of \"world_the_end\":")
.since("1.0, INSERT VERSION (defining worlds)");
.since("1.0, 2.8.0 (defining worlds)");

// World Unload Event
Skript.registerEvent("World Unload", EvtWorld.class, WorldUnloadEvent.class, "world unload[ing] [of %-worlds%]")
.description("Called when a world is unloaded. This event will never be called if you don't have a world management plugin.")
.examples(
"on world unload:",
"\tbroadcast \"the %event-world% has been unloaded!\"")
.since("1.0, INSERT VERSION (defining worlds)");
.since("1.0, 2.8.0 (defining worlds)");

// World Load Event
Skript.registerEvent("World Load", EvtWorld.class, WorldLoadEvent.class, "world load[ing] [of %-worlds%]")
.description("Called when a world is loaded. As with the world init event, this event will not be called for the server's default world(s).")
.examples(
"on world load of \"world_nether\":",
"\tbroadcast \"The world %event-world% has been loaded!\"")
.since("1.0, INSERT VERSION (defining worlds)");
.since("1.0, 2.8.0 (defining worlds)");
}

private Literal<World> worlds;
Expand Down
6 changes: 3 additions & 3 deletions src/main/java/ch/njol/skript/events/SimpleEvents.java
Expand Up @@ -643,7 +643,7 @@ public class SimpleEvents {
.examples(
"on player stop using item:",
"\tbroadcast \"%player% used %event-item% for %event-timespan%.\"")
.since("INSERT VERSION");
.since("2.8.0");
}

if (Skript.classExists("com.destroystokyo.paper.event.player.PlayerReadyArrowEvent")) {
Expand All @@ -658,7 +658,7 @@ public class SimpleEvents {
"\tif selected arrow is not a spectral arrow:",
"\t\tcancel event"
)
.since("INSERT VERSION");
.since("2.8.0");
}

if (Skript.classExists("io.papermc.paper.event.player.PlayerInventorySlotChangeEvent")) {
Expand Down Expand Up @@ -726,7 +726,7 @@ public class SimpleEvents {
"\tcancel the event",
"\tteleport event-projectile to block 5 above event-projectile"
)
.since("INSERT VERSION")
.since("2.8.0")
.requiredPlugins("Minecraft 1.14+ (event-projectile)");

Skript.registerEvent("Inventory Drag", SimpleEvent.class, InventoryDragEvent.class, "inventory drag[ging]")
Expand Down
Expand Up @@ -41,7 +41,7 @@
"\tif victim's active tool is a bow:",
"\t\tinterrupt player's active item use"
})
@Since("INSERT VERSION")
@Since("2.8.0")
@RequiredPlugins("Paper")
public class ExprActiveItem extends SimplePropertyExpression<LivingEntity, ItemStack> {

Expand Down

0 comments on commit 38cc0fe

Please sign in to comment.