1
This commit is contained in:
@@ -6,9 +6,8 @@ using UnityEngine;
|
||||
|
||||
namespace BITKit.Entities.Player
|
||||
{
|
||||
public class LocalPlayerComponent : EntityComponent
|
||||
public class LocalPlayerBehavior : EntityBehavior
|
||||
{
|
||||
public override Type BaseType => typeof(LocalPlayerComponent);
|
||||
private IEntityPlayerComponent[] playerComponents;
|
||||
private CancellationTokenSource initializeCancellationTokenSource;
|
||||
private CancellationTokenSource disposeCancellationTokenSource;
|
||||
@@ -31,7 +30,7 @@ namespace BITKit.Entities.Player
|
||||
{
|
||||
x.OnPlayerInitialized();
|
||||
}
|
||||
UnityPlayerServiceService.Register((Entity)entity);
|
||||
UnityPlayerServiceService.Register((Entity)UnityEntity);
|
||||
}
|
||||
public override async void OnDestroyComponent()
|
||||
{
|
||||
@@ -50,7 +49,7 @@ namespace BITKit.Entities.Player
|
||||
x.OnPlayerDisposed();
|
||||
}
|
||||
disposeCancellationTokenSource.Dispose();
|
||||
UnityPlayerServiceService.UnRegister((Entity)entity);
|
||||
UnityPlayerServiceService.UnRegister((Entity)UnityEntity);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user