[SPIGOT-6373] Shulker API additions Created: 20/Feb/21  Updated: 28/Apr/21  Resolved: 28/Apr/21

Status: Resolved
Project: Spigot
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Minor
Reporter: blablubbabc Assignee: Unassigned
Resolution: Fixed Votes: 2
Labels: None

Attachments: Text File 0016-Added-Shulker-Peek-and-AttachedFace-Methods.patch     Text File 0102-Added-Shulker-Peek-and-AttachedFace-Methods.patch     PNG File download.png    
Version: This server is running CraftBukkit version dev-Spigot-89d6047-c3e684e (MC: 1.16.5) (Implementing API version 1.16.5-R0.1-SNAPSHOT)
Guidelines Read: Yes

 Description   

It's not yet possible to change:



 Comments   
Comment by Evil Witchdoctor [ 28/Apr/21 ]

Thank you for adding getAttachedFace()!
I forgot to mention it in my bug (https://hub.spigotmc.org/jira/browse/SPIGOT-6388), but I've been using reflection to access this field as well for 3+ years and it's really nice to have a Bukkit/Spigot API alternative for the future

Comment by Julian v.d Berkmortel [ 20/Apr/21 ]

`isOpen()`, `isClosed()` and `isPeeking()` are redundant, `getPeek()` is enough. Checking if it is either open, closed or peeking can be achieved using `getPeek()`. In regards to why it is implemented as a float rather than a byte, a link to the pull request below in which this was discussed.

 

https://hub.spigotmc.org/stash/projects/SPIGOT/repos/craftbukkit/pull-requests/821/overview

Comment by FreeSoccerHDX [ 20/Apr/21 ]

You should provide Methods like isOpen() or isClosed() and also isPeeking() for Users that don't want to find out if Peeking is 50.0 or 100,0 with your Methods. (Also why do you implemented the 'peeking' as Percentage and not with the bytes it rly uses^^)

Comment by Julian v.d Berkmortel [ 20/Apr/21 ]

I will look into adding the attached face to the API as well.

Comment by FreeSoccerHDX [ 04/Apr/21 ]

Implemented in Shulker:

public boolean isPeeking();
public boolean isClosed();
public boolean isOpen();
public void setPeeking();
public void setOpen();
public void setClosed();
public void setCustomPeek(byte b);
public BlockFace getAttachedFace();
public void setAttachedFace(BlockFace bf);

 

(SpigotMC Contributor Licensing is done too)

0102 is from Spigot\CraftBukkit-Patches
0016 is from Spigot\Bukkit-Patches

Generated at Sun Mar 30 02:41:50 UTC 2025 using Jira 10.3.3#10030003-sha1:d220e3fefc8dfc6d47f522d3b9a20c1455e12b7b.