Search Unity

Unity netcode allocating GC on "heartbeats"

Discussion in 'Multiplayer' started by Ximaxer, Apr 19, 2022.

  1. Ximaxer

    Ximaxer

    Joined:
    Nov 27, 2021
    Posts:
    1
    So I've been creating an top-down zelda like MMO lately and my editor keeps showing large(since they're per frame) 40/50B of GC allocation on MessagingSystem.DeserializeAndHandle.ClientRpcMessage on client side.
    180/130B of GC allocation on NetworkAnimator.SendAnimStateClientRPC on server side.
    How could I provide animations so that it wouldn't create these 130B of GC allocation on the server and how would I fix the messaging system on the client side since it's sending these messages even when the character is not moving?
    I'm using Unity netcode.
     
    Last edited: Apr 19, 2022