#adventure-platform-help

1480 messages · Page 2 of 2 (latest)

hexed venture
#

Everyone who maintained it has migrated away from using it to only support non-legacy platforms

bright scarab
bright scarab
#

I'm not sure how it's community maintained if community PRs aren't looked at regularly.

#

There are PRs that haven't had any reviews for the last three years.

hexed venture
#

Yeah because one is blocked on adventure features and the other is not explained and weird

#

There's only 3 active PRs that haven't been looked at yet in just over a month and it's only been less than a week since adventure 4.25 was released

bright scarab
#

So you're saying that all these PRs will be resolved someday?

hexed venture
#

Yes

bright scarab
#

Three years without any development on a PR sounds and looks grim though.

#

I bet papers or velocitys own repos have some of those too though for some reason 🤔

hexed venture
#

Welcome to open source lmao

#

Sometimes people start things and don't finish them 🤷

bright scarab
#

Why not close them as stale?

hexed venture
#

I just did

bright scarab
#

That came unexpected SCCUTE

bright scarab
#

is shadow color already handled by adventure platform?

hexed venture
#

What do you mean by "handled"?

bright scarab
#

discarded on old versions

#

unless the server uses vv

hexed venture
#

I think it just passes it over

#

Don't think the client cares

radiant barn
#

yeah adventure-platform doesn't do anything special

bright scarab
#

confuses me then that object components fully discard the whole message

#

what's the adventure platform debug flag again?

unkempt minnow
#

I mean, have you checked the client logs?

hexed venture
#

Well there's a difference between additional superfluous data and an entire component type the client has no idea about

bright scarab
unkempt minnow
#

I'd imagine that if it's failing it's one probably the client not being able to read it ^

hexed venture
bright scarab
#

could someone pin this?

hexed venture
#

It's in the docs

bright scarab
#

well yeah but it's referenced here often

hexed venture
#

I'd rather keep information in one place

bright scarab
#

I guess mbaxter has to delete their message then SCCUTE

unkempt minnow
#

wat

hexed venture
#

dont be facetious, there's a difference between support and pinning :p

radiant barn
#

we have pins, they're called docs :p

bright scarab
woven mist
#

Skinrestorer 🥹

radiant barn
#

ah yeah, the serverside adv -> native conversion fails cuz native doesn't know about object components

#

probably need to add a new Option to control which component types are emitted, and disable object components for data versions before they were added

small basin
#

anyway to set the player locale?

radiant barn
#

from the client

small basin
#

beyond the client, ofc. there isn't any declared server-side method to set the user language?

radiant barn
#

no, -platform just uses whatever language is set

bright scarab
radiant barn
#

no

#

mostly its changes to gson serializer

humble shore
#

Hi, i'm looking to convert a kyori component to and from the NMS equivalent, what I had previously doesn't seem to exist anymore which confuses me

what I had:

@Override
public Component asNMSComponent(net.kyori.adventure.text.Component component) {
    return Component.Serializer.fromJson(GsonComponentSerializer.gson().serialize(component));
}

@Override
public net.kyori.adventure.text.Component asComponent(Component component) {
    return GsonComponentSerializer.gson().deserialize(Component.Serializer.toJson(component));
}```

It seems that the `net.minecraft.network.chat.Component$Serializer` class doesn't exist anymore
rose cave
#

on what platform?

humble shore
#

Paper

#

im using paperweight

rose cave
#

Then you shouldn't worry about using adventure-platform-bukkit. But rather than send you to the other channel I'll note that I think Paper has a method that does what you're doing there. I bet it's searchable in here, or someone will chime in before I finish searching for it :3

humble shore
#

oh

#

so, i found ComponentSerialization.CODEC but i dont know how to use it, mind helping me with that in #paper-dev ?

pure fernBOT
gloomy tundra
#

bro got nuked in 1 second

eternal solstice
#

damn i didnt even have time to read

astral sun
#

Hello!

I'm working on a project that requires support of Spigot/Paper across 1.8.8 to 1.21.10. I have Adventure-Bukkit shaded and relocated at de.Keyle.mypet.util.kyori.adventure. On Paper 1.8.8, audiences().player(player).sendActionBar(message); works perfectly. On Paper 1.21.10 the user gets kicked and I get this error:

Caused by: java.lang.NullPointerException: Cannot invoke "net.minecraft.network.chat.Component.tryCollapseToString()" because "component" is null

Anyone run in to this before? I assume it has something to do with the fact that Adventure is already provided on Paper 1.16.5+.

grizzled wing
#

i mean, i imagine it's because the latest release of the bukkit platform was for up to 1.21.7

astral sun
#

Just gave it a shot on 1.21.7 as well and facing the same client kick issue

#

Looks like it's working fine on Paper 1.21.5. Everything from 1.8.8 to 1.21.5 works, but 1.21.6-1.21.10 it's having issues

grizzled wing
#

platform version?

#

i tried using platform version 4.4.1 on paper 1.21.8 and sending an action bar message, didn't get an error

astral sun
#

Platform version 4.4.1, Paper 1.21.6-1.21.10 all have the issue

grizzled wing
#

example code?

#

for reference, all i did was

Audience audience = audiences.player(player); // audiences is an instance of BukkitAudiences
audience.sendActionBar(Component.text("Test."));
#

also, are you using the same client version as the server version you're testing on?

astral sun
#
    public void sendMessageActionBar(Player player, Component message) {
        if (player == null || !player.isOnline()) return;
        MyPetApi.getPlugin().audiences().player(player).sendActionBar(message);
    }

the main class:

    private BukkitAudiences audiences;
    public void onEnable() {
      audiences = BukkitAudiences.create(this);
    }
    @Override
    public BukkitAudiences audiences() { return audiences; }
#

Yes, client and server version always match

#

Even in the main class, doing audiences.player(player).sendActionBar(Component.text("Test")); results in a kick and the same error

grizzled wing
#

.

astral sun
#

Thanks, after adding the flag it's been producing this warning:

java.lang.UnsupportedOperationException: java.lang.ClassCastException: class de.Keyle.MyPet.util.gson.JsonObject cannot be cast to class com.google.gson.JsonElement (de.Keyle.MyPet.util.gson.JsonObject is in unnamed module of loader 'MyPet-3.14.0.jar' @e6a53cf; com.google.gson.JsonElement is in unnamed module of loader java.net.URLClassLoader @4629104a)
#

Looks like it may be an issue with me relocating gson in our project.

unkempt minnow
#

Using the non-platform gson breaks the conversion into a component, there is a PR which patches it on the github

astral sun
#

Thanks, I'll give that PR a shot. Is there an ETA on review and approval?

radiant barn
#

whenever the PR author makes it not garbage, the logic looked wrong last I looked

#

but like, nobody with brain cells cares enough about platform-bukkiy to maintain it

astral sun
#

Lol completely understandable. I'm leaning towards dropping Bukkit/Spigot support for my plugin as it is.

cedar jasper
#

Do it, nothing of value will be lost.

pastel briar
#

Can I use Adventure/MiniMessage for a fabric mod? My issue till now is that I can’t use mm.deserialize() in a player.sendMessage() method because it requires a Text and not a Component.

#

Fabric 1.21.8 & 1.21.10 btw

hexed venture
pastel briar
hexed venture
#

just player.sendMessage(Component) as the docs state

#

are you sure you're using the right version?

pastel briar
#
AttackBlockCallback.EVENT.register((player, world, hand, pos, direction) -> {
  MiniMessage mm = MiniMessage.miniMessage();
  Component comp = mm.deserialize("<red>AttackBlockCallback fired!</red>");
  player.sendMessage(comp, true);
  return ActionResult.PASS;
});```
pastel briar
hexed venture
#

That isn't a game crash that's an IDE error - and that IDE error makes it seem like you didn't set up the project correctly, make sure you read the docs for the build tool examples for correctly setting dependencies

pastel briar
#

I mean yeah that's an IDE error but if I try to fix it (and when it actually goes away in the IDE) it still crashes the game

hexed venture
#

I also have no clue how it works considering you need a different version of adventure-platform-mod for each Minecraft version

pastel briar
#

then let my try using a fresh fabric project

hexed venture
#

can you share your build file?

pastel briar
latent dawnBOT
hexed venture
#

you'll have to wait until someone more experienced with adventure-platform-mod replies, im unfortunately at the limit of my help now :')

pastel briar
radiant barn
#

@pastel briar wrong artifact

#

read the docs page for platform-fabric

#

interface injection is only done per-platform

pastel briar
#

Or do I need to manually add the fabric apis? Afaik the Fabric API dependency should already be enough

radiant barn
#

well you're not depending on platform-fabric, just the modcommon module

pastel briar
radiant barn
#

well for one, colonel hasn't been used in years

pastel briar
#

gg

pastel briar
# radiant barn well for one, colonel hasn't been used in years
private volatile MinecraftServerAudiences adventure;

public MinecraftServerAudiences adventure() {
    if (this.adventure == null) {
        throw new IllegalStateException("Tried to access Adventure without a running server!");
    }
    return this.adventure;
}

@Override
public void onInitialize() {
    ServerLifecycleEvents.SERVER_STARTING.register(server -> this.adventure = MinecraftServerAudiences.of(server));
    ServerLifecycleEvents.SERVER_STOPPED.register(server -> this.adventure = null);

    AttackBlockCallback.EVENT.register((player, world, hand, pos, direction) -> {
        var mm = MiniMessage.miniMessage();
        var comp = mm.deserialize("<red>AttackBlockCallback fired!</red>");

        adventure.audience((ServerPlayerEntity) player).sendMessage(comp);
        return ActionResult.PASS;
    });
}

This still doesn't work. Even though the website states that it would

pastel briar
#

I tried to get all players from the server so it would definitely be a ServerPlayerEntity but the game still crashes

olive temple
#

because I gave it a go with modstitch stonecutter template and it seemed to work fine

radiant barn
#

or just explain what "doesn't work" means

pastel briar
pastel briar
latent dawnBOT
radiant barn
pastel briar
radiant barn
#

a stacktrace, for one?

pastel briar
latent dawnBOT
radiant barn
#

not an adventure-platform issue, that's a logical client vs logical server issue

pastel briar
#

mb, solved then

pastel briar
radiant barn
#

think about what the miniMessage() method does and you can answer that yourself

ancient lily
#

then just static import

pastel briar
unique sequoia
#

I'm on fabric for mc 1.21.10 and want to convert a native component to an Adventure component in order to serialize it.
However it seems i need to supply a server instance, or know that i am on a client to get the correct MinecraftAudiences.
Is there some easier way to do it, or do i create an entrypoint for the client and one for the server that inject the correct one into the common code?

hexed venture
#

yeah you can get the serializer from MinecraftAudiences

#

non-wrapping serializer or smth

#

but in your common code you can just use instances of MinecraftAudiences that have asAdventure instance methods

#

then di them with the server/client specific instances

unique sequoia
#

ok, now for the server side: how do i get the MinecraftServer instance that i need for the MinecraftServerAudiences.of() method?

hexed venture
#

that's more of a fabric question tbh

unique sequoia
#

ok, then i will ask on their discord

radiant barn
#

ya you need registry context, you can get your own seruslizer with just a RegistryAccess but the server/client methods are helpers for that

unique sequoia
#

yeah, but i also didn't knew how i could get the RegistryAccess instance i need, so i now use the server started event from the fabric api

normal elm
#

Ok, I got the dreaded Legacy formatting codes have been detected, and I see a lot of posts here pointing this as the solution.. but HOW? Is there a tool, bash script, anything other than manually going through every string in the config and manually updating?

unkempt minnow
#

Not really, as said, find and replace solutions kinda suck, most solutions are generally to do it in code (try MM, fall back to legacy serialiser if it fails)

rose cave
#

What I do is I just refuse to support legacy and if somebody puts it in they can see the error and fix their mistake.

cedar jasper
#

wen paper docs tool

rose cave
cedar jasper
#

well, couldnt someone write a tool that gets a yml, json whatever file and replaces all legacy text with mm text?
I know it would kinda require a backend since i dont think there is a javascript version of the serializers but its just an idea.

unkempt minnow
#

Generally you want to understand the structure of a file before you butcher it

rose cave
#

Lots of plugin stuff uses placeholders of some nature, like I've seen legacy formats using java format placeholders (e.g. %s) and then transition to properly using minimessage. Or what do you do when you encounter a papi placeholder?

I view it as better to have the user create it themselves. :3

cedar jasper
#

yeah

#

you are right

normal elm
#

omg I've literally looked everywhere, even in this channel there r refs to "the legacy warning is gated behind a system property" - but where?? How do I turn off the Legacy formatting codes have been detected if fixing this Adventure stuff is too hard??

rose cave
#

Consider not sending legacy formatting in your components? I don't recall the system property bit - I just don't use the legacy symbols.

normal elm
#

Not really an option for me - I did try to patch the plugin (not mine) I'm using but it's too complicated & I'd love to not waste time & just disable the message

#

my server logs are nothing but Adventure warning stacks
[13:35:03 WARN]: net.kyori.adventure.text.LegacyFormattingDetected: Legacy formatting codes have been detected

main wyvern
#

net.kyori.adventure.text.warnWhenLegacyFormattingDetected is the system property for it, the default for it is false so it's weird it's triggering for you

normal elm
#

ty Warrior - that property is set in the plugin code?

#

this is all coming from Multiverse

main wyvern
#

system props are typically set using -DpropertyName=value on the command line while starting your server but can also be set programatically by anything

rose cave
#

Are you sure it isn't a case of you giving multiverse messages to use containing legacy section signs?

main wyvern
#

how are you running your server right now?

normal elm
normal elm
main wyvern
#

run-task sets that property to true specifically

normal elm
#

i wonder what version MV is using

normal elm
#

I am blind..

#

SWEET! All better, logs r clean, moving onto whatever upset Snakeyml...

#

thank u Warrior ❤️

silk smelt
unkempt minnow
#

error suggests that you're trying to mess with a bossbar which doesn't exist on the client

silk smelt
unkempt minnow
silk smelt
#

I'm using literally identical code from common module, which is called in both velocity and bungee modules
On velocity everything works perfectly fine, but on bungee it crashes the client

unkempt minnow
#

I mean, you'd need to work out why the bossbar doesn't exist to the client

#

I guess you could file a bug but adventure platform isn't the most looked after part of adventure

#

or, well, I guess there is already one there

#

sounds like you're doing stuff really early on, you might want to try delaying it

mint ermine
#

Hello, how can I get a native yarn Text component from Adventure's Component in the version 5.9.0?

#

nvm found it

#

FabricClientAudiences.of().toNative(message)

steep valley
#

the jds for adventure platform mod v6.8.0 are now available on the jd website (https://jd.advntr.dev/), sorry for the delay

shadow orbit
#

ughhh will i got loss of performance if using BukkitAudiences?

#

i expect wrapping audience create bunch of objects

#

or maybe im wrong?

rose cave
#

Shouldn't be significant but why not just use Paper's built in stuff? It's almost 2026, nobody's really running new servers on spigot at this point.

shadow orbit
#

there are still some whird api platform

#

like mixed server that combines forge and spigot

rose cave
#

Any of those that don't include Paper in the mix are worth ignoring.

shadow orbit
#

so i want to compat them

#

and legacy servers that does not have paperapi at all

#

like paperspigot 1.8.8

rose cave
#

Okay, if you want to support a handful of more servers for a gigantic headache, best of luck 😆

shadow orbit
#

its not that pain

#

i created a auto-select system to use multiple impls on current platform

#

for example: my plugin select path to send message in order

  1. use protocollib
    2.use native adventure of paper
    3.use spigot and converted component
    4.use bukkit and send serialized msg
rose cave
#

player.sendRichMessage("<red>Hello <name>", Placeholder.unparsed("name", name)); is so much simpler IMO 🙂

shadow orbit
#

i actually process components builted and rendered from data driven lib which is from advapi

shadow orbit
#

is it possible and legal to pack adventue api and adventure bukkit platform in my artifact?

#

it it could this will be awwwwwwesome

rose cave
#

shading and relocating, yes.

shadow orbit
#

so i have to remap the package to reduce conflicts?
is there any gradle plugin could do this

#

ok i found one

#

thanks soooo much

woeful fox
#

the same one you use for shading, yes

safe lotus
#

I have a question. i want to set the reason with setReason in Bungeecord LoginEvent but the method needs a BaseComponent but BungeeComponentSerializer#get#serialize returns a BaseComponent array. How i can solve this problem?

#

is TextComponent.fromArray() the way to go?

unkempt minnow
#

We can’t really advise much with bungee chat, but, it’ll either be a single sized array or, yes

rare pike
#

How can I get a Native component in Mojang's mappings from an Adventure component?

#

I got: packet.disconnect(plugin.adventure.asNative(component));
But the IDE says that "disconnect" needs Component but class_2561 was passed

#

I'm using Fabric API 1.21.1 and Adventure Fabric platform 6.8.0

olive temple
rare pike
#

1.21.1

olive temple
#

because if it is actually 1.21.1 then that's the wrong adventure platform version

rare pike
#

Where can I check which version I must use?

olive temple
rare pike
#

Alright, thanks

#

There is no 6.0.0

rare pike
#

mod-shared does have it

rose cave
#

To avoid breaking changes within a Minecraft release cycle, there will be no 6.x release of adventure-platform-fabric until Minecraft 1.21.2.

olive temple
rare pike
olive temple
#

the release notes for 6.0 of platform mod mentioned there wouldn't be a 6.0 for platform-fabric

rare pike
#

Alright, thanks

#
compileOnly("net.kyori:adventure-api:4.17.0")
compileOnly("net.kyori:adventure-text-minimessage:4.17.0")
compileOnly("net.kyori:adventure-text-serializer-plain:4.17.0")
compileOnly("net.kyori:adventure-platform-mod-shared-fabric-repack:6.0.0")
ServerLifecycleEvents.SERVER_STARTING.register(server -> this.adventure = MinecraftServerAudiences.of(server));
ServerLifecycleEvents.SERVER_STOPPED.register(server -> this.adventure = null);
error: cannot access AudienceProvider
        ServerLifecycleEvents.SERVER_STARTING.register(server -> this.adventure = MinecraftServerAudiences.of(server));
                                                                                                          ^
  class file for net.kyori.adventure.platform.AudienceProvider not found
radiant barn
#

no

cobalt voidBOT
radiant barn
#

this applies if you can't read the docs

rare pike
#

I'm using the adventure-platform-fabric v5.14.2 (Minecraft 1.21.1) and there's an issue:

com.google.gson.JsonParseException: Can't access registry ResourceKey[minecraft:root / minecraft:enchantment]

And I saw this issue. However, I cannot figure out how to fix it.

The current code which is throwing an error is inside a TextReplacementConfig:

builder.content("")
    .append(item.getDisplayName())
    .hoverEvent(item.asHoverEvent());

I know it's an unsupported version, but the whole modpack is 1.21.1 so I can't update until it does. If there is no fix, just say nothing can be done. If there's some workaround, please let me know.

midnight orbit
#

<@&748618676189528155>

rose cave
#

already on it 🙁

grave pagoda
pure fernBOT
brittle falcon
#

if you don't have a minecraft audiences instance yet then you will need to pass your own builtin registry access to create your own non wrapping serializer instance

rare pike
# brittle falcon how are you converting to vanilla types

I've tried both ways and both throw errors:

// On server start:
this.adventure = FabricServerAudiences.of(server);

public Component asAdventure(net.minecraft.network.chat.Component component) {
    return component.asComponent();
    // Tried this too:
    return adventure.toAdventure(component)
}
brittle falcon
#

the later should work, I encountered that bug on 5.14 in my mods and 5.14.1 fixed it (although that was more than a year ago atp)

#

not sure why it wouldn't assuming you use the fabric events to hook when the server inits/aren't using the server too early somehow

radiant barn
#

I feel like its the asHoverEvent that might be causing issues maybe?

rare pike
static badger
#

I've tried to setup adventure for neoforge platform, but it threw these errors when I tried to join a server:

Caused by: java.lang.IllegalStateException: Expected to find one service interface net.kyori.adventure.text.logger.slf4j.ComponentLoggerProvider, found multiple
Caused by: java.lang.NoClassDefFoundError: Could not initialize class net.kyori.adventure.text.logger.slf4j.Handler

I found that there are two AutoService Impl classes for ComponentLoggerProvider

I just added jarJar(implementation('net.kyori:adventure-platform-neoforge:6.8.0')) to dependencies in build.gradle and didn't do anything else but running client

brittle falcon
#

does that happen in prod or just in dev? could be that MDG broke it in dev with their changes for 1.21.11

#

because I have not had any reports of that from users

prime vault
#

having two Component classes while modding is sad :( (mojmaps)

pastel briar
#

I am trying to set up Adventure and Minimessage for neoforge but it is always crashing. I suppose its because my mod is serverside but can also run on the client.

latent dawnBOT
pastel briar
latent dawnBOT
pastel briar
#

Version in this case is 6.7.0

radiant barn
#

mod-shared is not neoforge

#

read the docs

pastel briar
#

I did

radiant barn
#

read better

#

in case you missed it

pastel briar
#

alr

#

back to this now ig
Dev (local:E:7aab3f60) lost connection: Internal Exception: java.lang.ExceptionInInitializerError

#

but I suppose thats not related

radiant barn
#

might be, might not be

#

We're not telepathic here

pastel briar
latent dawnBOT
pastel briar
#

because I got no clue

unkempt minnow
#

Mojang squashes exceptions in networking, you'd need a mod or something to get them to show

pastel briar
unkempt minnow
#

Nope

pastel briar
#

do you have a clue what may have caused this?

#

the only event I have is a LivingDeathEvent

unkempt minnow
#

No idea, all I can see is that an error occured in the network stack which caused the player to be booted

pastel briar
#

I disabled all events including the Config setup and it still says the same thing -.-

hexed venture
#

if you get the actual exception we can look further

pastel briar
pastel briar
#

well how

#

I dont know any mod that does this

unkempt minnow
#

I know that there exists ones for fabric, not really involved in the modding scene so I'm not aware of any personally for neoforge but I'd imagine there is probably one, if not it's potentially a simple mixin away

pastel briar
#

I could try using sinytra

#

so if you remember the fabric mod name then you can tell me

unkempt minnow
#

I lost it, I think they stopped updating it at some point

pastel briar
#

I've gone through the commits and it seems everything broke when I added Adventure and Minimessage

hexed venture
#

we'd be happy to look into it when you know what the issue is

pastel briar
#

without it I can enter a world on the latest commit

hexed venture
#

okay fab, once you've worked out what the issue is you can post that here

pastel briar
#

Ok so just adding this to the build.gradle.kts results in this issue:

jarJar("net.kyori:adventure-platform-neoforge:${property("deps.adventure")}")```

I haven't set up audiences but even if I do the same thing happens
cobalt voidBOT
radiant barn
#

and even if we did, you haven't given enough information to be useful

#

you're just wasting everyone's time without a stacktrace

pastel briar
pastel briar
# cobalt void

Also what do you mean unsupported
I can also start it in 1.21.11 on 6.8.0

radiant barn
#

6.7.0 is unsupported

radiant barn
#

the version you mentioned before

pastel briar
#

I got something new, not a stacktrace though:

[20:22:45] [Server thread/INFO] [minecraft/ServerLoginPacketListenerImpl]: Dev (local:E:98538d8b) lost connection: Internal Exception: org.spongepowered.asm.mixin.transformer.throwables.MixinTransformerError: An unexpected critical error was encountered
[20:22:45] [Render thread/WARN] [minecraft/ClientCommonPacketListenerImpl]: Client disconnected with reason: Internal Exception: org.spongepowered.asm.mixin.transformer.throwables.MixinTransformerError: An unexpected critical error was encountered```
#

And this issue only occurrs on 1.21.10 and .11

#

so adventure 6.7.0+

#

And I searched for such mods that show the stack traces but they are either for versions that currently work or for a version that is not supported by sinytra

radiant barn
#

I mean I think you can just set a breakpoint at the right part of the chsnnel handler too

pastel briar
#

🤔

#

Good idea

pastel briar
#

I also just downloaded a fresh neoforge 1.21.11 mod template from their website and added adventure. Still the same issue occurrs. However, this only happens in an IDE. When I build the mod and put it into a modpack everything works. Nevertheless this needs to be resolved somehow because otherwise it will get pretty annoying testing the mod

hexed venture
#

You're just gonna keep getting the same answer here, let us know the actual error and we can investigate

pastel briar
#

Well I don’t know how. I tried breakpoints, searching for mods and so on

#

If the issue is 100% reproducible then why can’t someone here try it as well?

unkempt minnow
#

Personally, not dealt with modding environments in eons and so not really inclined to invest the time it would take to set everything up to get to the point of being able to test it, especially if I have to rip in to get debug info, was hoping somebody more competent with the platform would be able to get that info

brazen sigil
#

One difference I noticed between launching 1.21.4 and 1.21.11 is that .4 (which works) doesn't have this part in the logs that 1.21.11 does:

[21:22:30] [main/INFO] [ne.ne.fm.lo.FMLLoader/]: Building game content classloader:
 - adventure_platform_neoforge (jar(/home/.../adventure-platform-neoforge-6.8.0.jar))
 - devauth (jar(/home/.../DevAuth-neoforge-1.2.2.jar))
 - loot_table_modifier (composite(folder(/home/.../build/resources/main)))
 - minecraft (composite(jar(/home/.../neoforge-21.11.27-beta-client-extra-aka-minecraft-resources.jar), filtered(jar(/home/.../neoforge-21.11.27-beta.jar))))
 - mixinextras.neoforge (jar(/home/.../neoforge-21.11.27-beta.jar > mixinextras-neoforge-0.5.0.jar))
 - monkeylib538 (jar(/home/.../monkeylib538-neoforge-1.21.11-3.0.0-beta.2.1769800141701+local+neoforge+1.21.11.jar))
 - neoforge (composite(filtered(jar(/home/.../neoforge-21.11.27-beta.jar))))
 - net.kyori.adventure.platform.mod.shared (jar(/home/.../adventure-platform-mod-shared-6.8.0.jar))
 - net.neoforged.fml.generated (empty(VirtualJar/net.neoforged.fml.generated))
[21:22:30] [main/INFO] [ne.ne.fm.lo.FMLLoader/]: Built game content classloader in 13ms

Which I'm guessing could be related?

#

do adventure-platform-neoforge and adventure-platform-mod-shared both possibly contain the service files?

#

hm nope, doesn't look like it

#

ah no they do

#

in platform-neoforge, the services just come from a JIJ, which is why I didn't seem them initally

#

Yeah so adventure-platform-neoforge JIJ includes:

  • net.kyori.adventure-platform-mod-shared-6.8.0.jar - Contains net.kyori.adventure.text.logger.slf4j.ComponentLoggerProvider
  • net.kyori.adventure-platform-neoforge-services-6.8.0.jar - Contains net.kyori.adventure.text.logger.slf4j.ComponentLoggerProvider
#

that's also true for 6.3.0, but it on 1.21.4 works perfectly fine

#

that I'm not quite sure about why though

#

could be related to the fact that below and including 1.21.8, neoforge required the use of additionalRuntimeClasspath to add something to the runtime classpath, but above 1.21.9, it "will load anything available on the classpath in development"?

#

it is definitely related to how stuff's done in the dev env because I just built my mods, threw them into a new prism instance of 1.21.11 neoforge with the latest adventure from modrinth and everything looks to be working

brazen sigil
brazen sigil
#

downloaded an empty template. 1.21.8 works, 1.21.9 crashes

#

that definitely lines up with my theory of some change related to additionalRuntimeClasspath being removed, as that's the version that was done in

pastel briar
brazen sigil
#

Yep i know that much

brazen sigil
#

I guess it's not fully broken, so I can continue with getting rid of my own text wrapper, but yeah would be nice if this could be figured out at some point. I also made a [post on the neoforge discord about this](#1185197721477468160 message), but haven't got any response from them yet

pastel briar
brazen sigil
#

do you have fabric api?

pastel briar
#

of course

#

the issue is that they use fabric-particles-v1-db4807d3-4.0.14+7feeb73304 which doesnt have that class. But I am more confused about the fact that it worked before and now suddenly it doesnt anymore

brazen sigil
#

I always exclude fabric-api when depending on projects

#

having multiple versions is bad

#

so like
⁨```gradle
modImplementation("net.kyori:adventure-platform-fabric:${project.adventure_version}") {
exclude(group: "net.fabricmc.fabric-api")
}

pastel briar
#

ok, let me try

brazen sigil
#

and then depend on it myself separately

pastel briar
#

i've checked manually now

brazen sigil
#

dunno about that then ¯_(ツ)_/¯

steep light
#

Will adventure create a platform also for hytale?

hexed venture
#

It's possible, I'm not against it - but they are nowhere near a stabilised/released API

rare pike
#

I have a mod which I want to make compatible with Minecraft 1.21 - 1.21.11 but my only issue right now is Adventure, which I want to use for Minimessage. Since each Minecraft version has a different Adveture version, I get errors if I try to use modImplementation(include("net.kyori:adventure-platform-fabric:6.8.0")!!) in 1.21, for example.

Is there any way I can make my mod compatible for 1.21.x while keeping Minimessage support? I am developing it for Fabric and my intention is to make it available from 1.21 to 1.21.11

radiant barn
#

depend on the -platform-fabric dep as an external module, and have users grab it from iirc modrinth

rare pike
#

Yes but which version do I depend on so as not to get errors?

radiant barn
#

just have a wide version range in your fmj

#

each version of MC will have a different adventure-platform-fabric version

rare pike
#

Oh so basically I have multiple modules, each with its own platform version, and then the user "provides" it, right?

radiant barn
#

well the api across the versions is the same for the most part, just MC is what changes

rare pike
#

Yeah that's what I mean, a common module but then each version module has different mc & adventure versions

radiant barn
#

ya

rare pike
#

I've found a workaround to just have 1 module, which is serialize and deserialize from json and shade the latest version of adventure:

public net.minecraft.network.chat.Component asNative(Component component) {
    return ComponentSerialization.CODEC.parse(JsonOps.INSTANCE, gsonSerializer.serializeToTree(component)).getOrThrow();
}

public Component asAdventure(net.minecraft.network.chat.Component component) {
    return gsonSerializer.deserializeFromTree(ComponentSerialization.CODEC.encodeStart(JsonOps.INSTANCE, component).getOrThrow());
}

How terrible is this and why?

radiant barn
#

well the json format has changed between different MC versions

rare pike
#

That makes sense, tho it seems to work on both 1.21 and 1.21.11

#

Thanks abby!

ember token
#

Didn't it change in 1.21.5 or so?

#

I think it was the hover event?

#

Oh wow old comment

paper steeple
#

I'm a month late though

brazen sigil
#

is there a dev build for 26.1 available anywhre I could depend on while trying ti figure out the changes to my own mods?

hexed venture
#

nobody has started work on 26.1 anywhere yet

#

adventure-platform might work as is, adventure-platform-mod probably not

radiant barn
brazen sigil
#

is that 26.1 branch automatically published anywhere by ci? I currently pushed it into mavenLocal, but having it somewhere public would be nice too, mainly so actions can build it

olive temple
brazen sigil
olive temple
#

artifact would be net.kyori:adventure-platform-mod-shared:6.9.0-SNAPSHOT

brazen sigil
#

ah I see, thanks! Seems like it was able to find the artifact from there :D

pastel briar
#

Hello, does anyone know which adventure versions work with Fabric and NeoForge 1.21.1 and .4?

#

or where I can get that information from

olive temple
latent dawnBOT
olive temple
#

the table is in the dropdown on the red block

pastel briar
amber flame
#

Deperecated stuff was removed and classes were moved to sealed interfaces

radiant barn
#

adventure 5.x has not been released yet, so fabric and neoforge do not distribute it yet

brazen sigil
#

the 26.1 build's been working fine for me in dev, is there anything it's missing for a modrinth release?

radiant barn
#

adventure 5.0

brazen sigil
#

and that is... gonna take a while still?

cobalt voidBOT
brazen sigil
#

I may just JIJ the snapshot build then tater

radiant barn
#

no

#

you'll just cause problems later on

brazen sigil
#

but... I wanna 26.1 sad_tater

heady egret
#

then do it yourself 🙂

brazen sigil
radiant barn
#

be patient, people have lives

#

people using different -SNAPSHOT versions

#

floader has no way to determine which -SNAPSHOT is newer if they're both targeting the same release so you can get version conflicts

brazen sigil
#

Riiiight, hm

jagged scaffold
radiant barn
#

the whole point is that snapshots aren't widely distributed

#

since there is the potential for new additions to change before release

gaunt cloud
#

Can we have a full release now? If we haven’t had one. Didn’t check

gaunt cloud
#

Nice. Thanks!

tall wedge
#

Is there any plan to release an adventure-platform-bukkit to accompany Adventure 5.0.1?

radiant barn
#

not from us

rose cave
#

platform-bukkit has been something community-handled for a while now. Plus, it's generally pretty easy to just either a) support paper only or b) shove non-paper support into places it doesn't belong.

left pawn
#

hi im using adventure-platform-bukkit to color and send components for spigot, but i would also like to color the display name of an item. is this possible? im asking because ItemStack/ItemMeta doesnt have displayName(Component) on spigot

rose cave
#

You could detect if it's one of the couple percent of spigot users and use the legacy converter, stripping other details from it.

left pawn
#

so basically there is no itemstack wrapper or something

woeful fox
#

no

#

iirc there was some other community library for additional things, but in the end it's either going to use the legacy serializer, or use internals which will be downgraded to legacy the very second a plugin uses ItemMeta anyway given you're running on Spigot and Hopes

#

which are pretty much your two solutions anyway

left pawn
#

thanks, this worked:

private static final LegacyComponentSerializer SERIALIZER = LegacyComponentSerializer.builder().hexColors().useUnusualXRepeatedCharacterHexFormat().build();
public static String toSpigotDisplayName(Component component) {
    return SERIALIZER.serialize(component);
}
fringe tide
#

hey after 5.0.0 is adventure-platform outdated?

#

it no send chat message :/

#

if revert, it works

radiant barn
rose cave
fringe tide
fringe tide
radiant barn
#

i think the plan is to archive the repo

#

anyone can maintain it independently

fringe tide
#

is there any known maintained version maybe?

#

also bungeecord support :/

rose cave
# fringe tide not really helpful when relocating adventure

Certainly! But if writing a paper plugin, which is the majority of folks that have been using it, it's unnecessary to shade/relocate. That's all I meant. If that's not you, writing for something like bungee instead, that's not gonna be the way to go certainly. 😄

fringe tide
#

"thats not gonna be the way to go certainly" is outrageous

#

im not even going to bother explaining why💀

rose cave
scarlet canopy
#

Did adventure-platform-bukkit drop support for 1.8.8 on 5.0.1? Because messages aren't being sent now but if I go back to 4.24.0 they work perfectly.

unkempt minnow
#

it's not even been touched?

olive temple
#

I don't think platform-bukkit was updated to 5.x to begin with

scarlet canopy
unkempt minnow
#

Basically, yes

olive temple
scarlet canopy
#

oh well

#

in that case what should I do? Do I just make myself a fork or what.

unkempt minnow
#

afaik 3rd party bindings have generally been maintained by others for a while now

olive temple
#

but you can contribute 5.x support if you want

scarlet canopy
olive temple
scarlet canopy
#

mhm

hexed venture
#

idk why you need to update to adventure 5.x in this case

#

you're using legacy software just keep using it

scarlet canopy
#

i mean, i wanna have my libraries up to date.

olive temple
#

I mean, you don't really benefit from the changes in 5.x

scarlet canopy
#

well yes

hexed venture
#

having stuff be up to date just for the sake it of doesn't make any sense

scarlet canopy
#

but think if there's another major in the future that changes the structure.

hexed venture
#

and also, you're using 1.8 lol so

scarlet canopy
#

i don't only do development for 1.8.8

#

i do make stuff in 1.21.x

olive temple
#

Adventure works best when the platform supports it natively

#

so, ideally you should look into making a 1.8.8 fork which supports Adventure rather than depending on platform-bukkit which just makes things awkward

#

though 1.8.8 was before mappings and codecs were a thing so I bet it's gonna be fun to implement

scarlet canopy
#

yes, i'll definitelly have a travel with that 🤣

#

well, thanks for giving me advice on this whilst using a +10 year old version.

#

thought i would just get denied at first and get told up to update

olive temple
#

well, unlike Paper, adventure is kind of version independent

hexed venture
#

yeah ^

#

i think it's likely we will officially end support for adventure-platform soon (not adventure-platform-mod) anyway fwiw

#

nobody wants to maintain it

scarlet canopy
#

so adventure will just become a normal text library that which objetive is to be implemented everywhere i guess

unkempt minnow
#

I mean, it already is a normal text/UI library

hexed venture
#

that's always been adventure anyway

scarlet canopy
#

well yes but most focused on minecraft no?

unkempt minnow
#

it just provided on the side bindings for platforms which don't offer native support, like modding platforms

#

it still is focused on minecraft

#

just we will no longer be the maintainers of the bindings for 3rd party non-mod platforms

#

mod platforms generally have community members and such contributing fixes to them

scarlet canopy
#

mhm, alright. cool talk with yall. i'll get back to checking on my options now.

hoary patio
#

oof I maintain a plugin that supports 1.8.8-26.1.2 and I just saw that the new adventure api is not compatible with the platform-bukkit KEKW well salute ig

hexed venture
#

Nobody is forcing you to 😅