コード例 #1
0
        public static void Postfix(PingInstance instance)
        {
            // Only beacons are synced here (not mission, vehicle or other signals) because spawning is handled differently for non-droppable entities
            if (!instance || !instance.GetComponent <Beacon>())
            {
                return;
            }

            PingRenamed packet = new(NitroxEntity.GetId(instance.gameObject), instance.GetLabel(), SerializationHelper.GetBytes(instance.gameObject));

            NitroxServiceLocator.LocateService <IPacketSender>().Send(packet);
        }