#(person0z) Potion effect when in a world
26 messages · Page 1 of 1 (latest)
(person0z) Potion effect when in a world
Hi I'm AutoThreadBot! Don't mind me, I'll just be adding the helper team to this thread so they can see it. A human will get to you soon.
Please @ when respond
Example:
If player in world nether then potion apply levitaiton 2 2(seconds)
loop
!e player changes world
Player
player changes world (from <world>) (to <world>)
when a player moves to a different world.
Always. - this adds switches flagged:<flag name> + permission:<node>, in addition to the <player> link.
<context.origin_world> returns the WorldTag that the player was previously on.
<context.destination_world> returns the WorldTag that the player is now in.
True - this adds switches in:<area> + location_flagged:<flag name>.
!e player joins
Player
player joins player join
when a player joins the server.
Always. - this adds switches flagged:<flag name> + permission:<node>, in addition to the <player> link.
<context.message> returns an ElementTag of the join message.
ElementTag to change the join message.
"NONE" to cancel the join message.
True - this adds switches in:<area> + location_flagged:<flag name>.
!t locationtag.world
easier just to run it on loop tbh
That method definitely works and is a bit more efficient, but you'd have to cover a lot of edge cases
I'd typically just use a time event and loop through online players
@real portal
Could maybe have the best of both worlds? if you just make an update task that checks the player's world and adds/removes effects and then run it in these 2 events it should be pretty fail proof, no?
I.e. what you'd have in a time event loop but only run it when relevant
Can't you basically make effects infinite in the latest version of MC?
!c cast
entity
cast [<effect>] (remove) (duration:<value>) (amplifier:<#>) (<entity>|...) (no_ambient) (hide_particles) (no_icon) (no_clear)
Casts a potion effect to a list of entities.
Casts or removes a potion effect to or from a list of entities.
The effect type must be from https://hub.spigotmc.org/javadocs/spigot/org/bukkit/potion/PotionEffectType.html.
If you don't specify a duration, it defaults to 60 seconds.
An infinite duration will apply an infinite duration potion effect, refer to !objecttype DurationTag for more details.
The amplifier is how many levels to *add* over the normal level 1.
If you don't specify an amplifier level, it defaults to 1...
Not basically, you can make actual infinite effects
If you don't specify a duration, it defaults to 60 seconds. An infinite duration will apply an infinite duration potion effect
iirc it's just duration:infinite?
Has your issue been resolved, or your question been answered?
If so, please use the </resolved:1028673926114594866> command to close your thread.
Or </invalid:1028673926898909185> if it's not possible to resolve.
If not yet resolved, please reply below to tell us what you still need.
(Note that if there is no reply for a few days, this thread will eventually close itself.)
@real portal