51 lines
1.0 KiB
C#
51 lines
1.0 KiB
C#
|
using System.Collections;
|
||
|
using System.Collections.Generic;
|
||
|
using UnityEngine;
|
||
|
using BITKit;
|
||
|
using Unity.Netcode;
|
||
|
namespace BITKit.Entities
|
||
|
{
|
||
|
public class EntityNetComponent : NetworkBehaviour, IEntityComponent
|
||
|
{
|
||
|
public IEntity entity { get; set; }
|
||
|
public bool isLocalPlayer => IsLocalPlayer;
|
||
|
|
||
|
public virtual void Initialize(IEntity entity)
|
||
|
{
|
||
|
this.entity = entity;
|
||
|
}
|
||
|
public virtual void OnAwake()
|
||
|
{
|
||
|
}
|
||
|
|
||
|
public virtual void OnDestroyComponent()
|
||
|
{
|
||
|
}
|
||
|
|
||
|
public virtual void OnFixedUpdate(float deltaTime)
|
||
|
{
|
||
|
}
|
||
|
|
||
|
public virtual void OnLateUpdate(float deltaTime)
|
||
|
{
|
||
|
}
|
||
|
|
||
|
public virtual void OnSetOverride(bool value)
|
||
|
{
|
||
|
}
|
||
|
|
||
|
public virtual void OnSpawn()
|
||
|
{
|
||
|
}
|
||
|
public virtual void OnDespawn()
|
||
|
{
|
||
|
}
|
||
|
public virtual void OnStart()
|
||
|
{
|
||
|
}
|
||
|
|
||
|
public virtual void OnUpdate(float deltaTime)
|
||
|
{
|
||
|
}
|
||
|
}
|
||
|
}
|