https://github.com/DragonGamerDevelopers/NewFantasyMod/blob/1.15.2/src/main/java/mod/dragonita/fantasymod/customthings/ModidPacketHandler.java#L22-L35
it is better to extract this into its own class and name it "PanicMessage" ModidPacketHandler is a bad name for it
https://github.com/DragonGamerDevelopers/NewFantasyMod/blob/1.15.2/src/main/java/mod/dragonita/fantasymod/customthings/ModidPacketHandler.java#L30
needs also the message, "PanicMessage" in this case
public void handle(PanicMessage message, Supplier<NetworkEvent.Context> context)
https://github.com/DragonGamerDevelopers/NewFantasyMod/blob/1.15.2/src/main/java/mod/dragonita/fantasymod/Main.java#L75
where you do 505156459 it is better to have do ID++ and ID is a static field
https://github.com/MinecraftForge/MinecraftForge/blob/1.15.x/src/main/java/net/minecraftforge/fml/network/simple/SimpleChannel.java#L112-L125
use this to send a message to the client