public RetrievePropCMD(string propId, PrefabContentKey propContentKey, PropUser propUser, long ownerId, bool isOwnerLocalPlayer, Action <Prop> onPropInstantiatedHandler = null, System.Action onCompleteHandler = null)
 {
     this.propId                    = propId;
     this.propContentKey            = propContentKey;
     this.propUser                  = propUser;
     this.ownerId                   = ownerId;
     this.isOwnerLocalPlayer        = isOwnerLocalPlayer;
     this.onPropInstantiatedHandler = onPropInstantiatedHandler;
     this.onCompleteHandler         = onCompleteHandler;
     avatarView = propUser.GetComponent <AvatarView>();
 }
Example #2
0
 public void Start()
 {
     if (!SceneRefs.ZoneLocalPlayerManager.LocalPlayerGameObject.IsDestroyed())
     {
         propUser = SceneRefs.ZoneLocalPlayerManager.LocalPlayerGameObject.GetComponent <PropUser>();
         if (PersistWhenSitting)
         {
             locoEventBroadcaster = propUser.GetComponent <LocomotionEventBroadcaster>();
             locoEventBroadcaster.OnControllerChangedEvent += onControllerChangedEvent;
         }
         propUser.EPropUseStarted += onPropUseStarted;
     }
 }