Cardinal-Components-API icon indicating copy to clipboard operation
Cardinal-Components-API copied to clipboard

Invalid player data when trying to make a ServerPlayer component

Open skerit opened this issue 3 years ago • 1 comments

I made a component for players. This is how I registered it:

    @Override
    public void registerEntityComponentFactories(EntityComponentFactoryRegistry registry) {
        registry.registerForPlayers(CONTESTANT, ContestantComponent::new, RespawnCopyStrategy.ALWAYS_COPY);
    }

But when I connect I get this:

[13:04:30] [Server thread/INFO]: com.mojang.authlib.GameProfile@6b31139d[id=e8fe9186-72a2-3849-be6c-529f6e798e3c,name=Skerit,properties={},legacy=false] (/127.0.0.1:49998) lost connection: Invalid player data

The constructor doesn't even seem to get called.

skerit avatar Oct 04 '21 11:10 skerit

Could you link your mod source so I can see what's going wrong ?

Pyrofab avatar Oct 10 '21 13:10 Pyrofab