{!See https://docs.google.com/document/d/1takg_GmIBBKKTj-GHZCwzxohpQz7Bhekivkk72kYMtE/edit for reference implementation of OneTrust, dataLayer and GTM} {!OneTrust Cookies Consent} {!OneTrust Cookies Consent end} {!dataLayer initialization push} {!dataLayer initialization push end} {!Google Tag Manager} {!Google Tag Manager end} Method FinalizePrefabComponents | Netcode for Entities | 1.1.0-pre.3
docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method FinalizePrefabComponents

    FinalizePrefabComponents(Config, EntityManager, Entity, GhostType, NativeArray<Entity>, NativeList<ComponentType>, NativeArray<int>, NetcodeConversionTarget, NativeArray<GhostPrefabType>)

    Strip components which are not used, and add the ones which should always be present on a ghost prefab

    Declaration
    public static void FinalizePrefabComponents(GhostPrefabCreation.Config ghostConfig, EntityManager entityManager, Entity rootEntity, GhostType ghostType, NativeArray<Entity> linkedEntities, NativeList<ComponentType> allComponents, NativeArray<int> componentCounts, NetcodeConversionTarget target, NativeArray<GhostPrefabType> prefabTypes)
    Parameters
    Type Name Description
    GhostPrefabCreation.Config ghostConfig

    Configuration used when creating ghost prefabs.

    EntityManager entityManager

    Used to validate which components exists on rootEntity

    Entity rootEntity

    Components existing on this entity, like GhostOwner is used to configure the result.

    GhostType ghostType

    Component storing the guid of the prefab the ghost was created from.

    NativeArray<Entity> linkedEntities

    List of all linked entities to the rootEntity

    NativeList<ComponentType> allComponents

    List of all component types.

    NativeArray<int> componentCounts

    List of number of components on each index.

    NetcodeConversionTarget target

    NetcodeConversionTarget

    NativeArray<GhostPrefabType> prefabTypes

    List of different types of GhostPrefabType to created.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)