diff --git a/src/main/java/com/comphenix/protocol/wrappers/AdventureComponentConverter.java b/src/main/java/com/comphenix/protocol/wrappers/AdventureComponentConverter.java index 2ebdc2180..9614a4204 100644 --- a/src/main/java/com/comphenix/protocol/wrappers/AdventureComponentConverter.java +++ b/src/main/java/com/comphenix/protocol/wrappers/AdventureComponentConverter.java @@ -86,6 +86,15 @@ public static WrappedChatComponent fromComponent(Component component) { return WrappedChatComponent.fromJson(SERIALIZER.serialize(component)); } + /** + * Converts an object that is instance of {@link Component} into a ProtocolLib wrapper + * @param component Component + * @return ProtocolLib wrapper + */ + public static WrappedChatComponent fromComponentObject(Object component) { + return fromComponent((Component) component); + } + /** * Converts a {@link WrappedComponentStyle} into a {@link Style} * @param wrapper ProtocolLib wrapper