Skript Things you probably didn't know were available in vanilla Skript

ModeratorSupporter

I've been getting tilted in the skUnity Discord for a while now when seeing people recommend add-ons for simple operations which have been possible in vanilla Skript for months or even a year or two now, so I figured it would be good to have a comprehensive list here of things which vanilla Skript now allows you to do which most people are stuck in the mentality of needing an add-on for. I'll also include a few specific super cool newer Skript syntaxes that make your code way cleaner even if they weren't previously addon-specific.

I'll include notes where I can on each new feature about the add-ons you previously would have needed to install for it. Note that this doesn't mean you don't need that add-on anymore since it may provide other functionality which you're using, it just means you no longer need an add-on for that specific feature.

Vanilla Skript Stuff That Was Previously Addon-Exclusive

Sounds: Sounds can be played with this syntax (previously from many add-ons). This supports vanilla OR Spigot sound enum names AND supports resource pack sounds.

Inventories: Skript has much more inventory support now (from many add-ons). You can:

Filters (skQuery Lambdas): Vanilla Skript supports filter statements just like skQuery's lambda which allow you to filter objects based on a condition. Some simple examples are send "congrats on being staff!" to all players where [player input has permission "staff"] or loop players in radius 10 of player where [player input isn't player].

Vectors: Skript has 100% full vector support now (previously some RandomSK and Vectors-Skript). Too many things to list but it's very powerful. Expressions here, a couple of effects here.

Metadata: Skript now supports metadata (previously RandomSK, now from Skellett). This lets you store data indexed by a key on either a block or entity which is automatically removed on server restart. There's a condition for has/doesn't have metadata and an expression to get a specific metadata value.

Scoreboard Tags: We also now support scoreboard tags (from Skellett). This is similar to metadata, but it can only store data on an entity and can only store text, but it persists across server restarts -- it's permanent and dies with the entity, and doesn't require variables. Simple example script using tags.

Checking Event Cancellation: You can now check if an event is canceled (from Skellett and SharpSK). You've always been able to cancel events but couldn't check if it was already canceled until recently.

Command Cooldowns: Skript has built-in support for commands having a cooldown, with tons of expressions to give you info about the cooldown's remaining time, elapsed time, duration, the command's last usage date, and a permission to bypass the cooldown. To use the "elapsed time" or "last usage date" expressions you need to enable "keep command last usage dates" in your Skript config. You can also conditionally cancel a cooldown. Example command.

Default Value: You can now in one line provide an alternative default value if the first value isn't set. Example: broadcast {score::%player's uuid%} otherwise "%player% has no score!". This only sends their score if their variable is set, otherwise sending the 2nd message.

Ternary: You can now use ternary statements, which basically means returning a different value based on the result of a condition all in one line. Example: set {points} to 500 if {admin::%player's uuid%} is set else 100

Do If (Conditional Effects): Similar to the ternary, the do if effect allows you to execute an effect only if a condition passes. Note that this can be used to entirely replace if statements which only execute one line of code. Example: give a diamond to the player if {honor::%player's uuid%} > 50

Continue: You can now use continue in a loop to skip to the next loop value.

Full Server List Control: Skript now has an entire detailed suite of how your server appears in the server list. This is spread over many expressions and effects which are viewable here in the on server list ping event documentation but includes support for modifying the player count, server icon, MOTD, the text displayed in the hover list, and much much more.

Loaded: There are conditions for checking the load state of...

Scripts: You can check if a specific script is loaded. If you don't specify a script name it'll default to the current one which is useful for stuff like "while script is loaded" in an "on load" event!

ModeratorSupporter

Updated with some other new stuff that has been added in the past month (10/28/2018):

Full extensive server list control

Action bar send effect

Jump and hand swap events (jump requires PaperSpigot)

"Do if" for conditional effect execution

Leash effect and expression

Updated the "upcoming" with things which either are already merged in and will be available next release or which currently have PRs open. Note that the ones coming from already open PRs have the off chance of not making it in (i.e. if the PR doesn't end up getting merged for one reason or another).

Updated with some other new stuff that has been added in the past month (10/28/2018):

Full extensive server list control

Action bar send effect

Jump and hand swap events (jump requires PaperSpigot)

"Do if" for conditional effect execution

Leash effect and expression

Updated the "upcoming" with things which either are already merged in and will be available next release or which currently have PRs open. Note that the ones coming from already open PRs have the off chance of not making it in (i.e. if the PR doesn't end up getting merged for one reason or another).

About Us

Our community has been around for many years and pride ourselves on offering unbiased, critical discussion among people of all different backgrounds. We are working every day to make sure our community is one of the best.

Support skUnity

The staff team works very hard to make sure the community is running its best. This means constantly performing upgrades to systems and other features. This does cost a bit of money to keep doing. Donating to skUnity would allow the server to keep running smoothly for years to come!