Skip to content

Add Viewer#sendDeathProtection() #2586

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: api-14
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/main/java/org/spongepowered/api/effect/Viewer.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
import org.spongepowered.api.effect.particle.ParticleEffect;
import org.spongepowered.api.effect.sound.SoundType;
import org.spongepowered.api.effect.sound.music.MusicDisc;
import org.spongepowered.api.item.inventory.ItemStackLike;
import org.spongepowered.api.world.World;
import org.spongepowered.api.world.WorldType;
import org.spongepowered.api.world.WorldTypes;
Expand All @@ -57,6 +58,13 @@ public interface Viewer extends Audience {
*/
void sendWorldType(WorldType worldType);

/**
* Plays a client-only death protection effect with the given item.
*
* @param stack The item to display
*/
void playTotemOfUndyingEffect(ItemStackLike stack);

/**
* Spawn the given {@link ParticleEffect} at the given position.
*
Expand Down Expand Up @@ -234,5 +242,4 @@ default void resetBlockProgress(final Vector3i position) {
* @param z The z position
*/
void resetBlockProgress(int x, int y, int z);

}