File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
Assets/HoloToolkit/Sharing/Tests Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -46,24 +46,30 @@ void Update()
4646 }
4747
4848 /// <summary>
49- /// Called when a new user is leaving .
49+ /// Called when an existing user leaves the session .
5050 /// </summary>
5151 /// <param name="sender"></param>
5252 /// <param name="e"></param>
5353 private void Instance_SessionLeft ( object sender , SharingSessionTracker . SessionLeftEventArgs e )
5454 {
55- RemoveRemoteHead ( this . remoteHeads [ e . exitingUserId ] . HeadObject ) ;
56- this . remoteHeads . Remove ( e . exitingUserId ) ;
55+ if ( e . exitingUserId != SharingStage . Instance . Manager . GetLocalUser ( ) . GetID ( ) )
56+ {
57+ RemoveRemoteHead ( this . remoteHeads [ e . exitingUserId ] . HeadObject ) ;
58+ this . remoteHeads . Remove ( e . exitingUserId ) ;
59+ }
5760 }
5861
5962 /// <summary>
60- /// Called when a user is joining .
63+ /// Called when a remote user is joins the session .
6164 /// </summary>
6265 /// <param name="sender"></param>
6366 /// <param name="e"></param>
6467 private void Instance_SessionJoined ( object sender , SharingSessionTracker . SessionJoinedEventArgs e )
6568 {
66- GetRemoteHeadInfo ( e . joiningUser . GetID ( ) ) ;
69+ if ( e . joiningUser . GetID ( ) != SharingStage . Instance . Manager . GetLocalUser ( ) . GetID ( ) )
70+ {
71+ GetRemoteHeadInfo ( e . joiningUser . GetID ( ) ) ;
72+ }
6773 }
6874
6975 /// <summary>
You can’t perform that action at this time.
0 commit comments