Removed Many Things

This commit is contained in:
CortexCore
2024-08-13 18:42:51 +08:00
parent c563c539a5
commit 79985ad6f5
1363 changed files with 5892 additions and 71512 deletions

View File

@@ -9,7 +9,7 @@ using UnityEngine;
namespace BITKit.Net.Http
{
[CustomType(typeof(IHttpListenerService))]
public class UnityBasedHttpListenerService : EntityBehavior,IHttpListenerService
public class UnityBasedHttpListenerService : MonoBehaviour,IHttpListenerService
{
[SerializeField] private int port = 8080;
[SerializeField] private bool autoStart = true;
@@ -29,16 +29,12 @@ namespace BITKit.Net.Http
remove => _service.OnRequest -= value;
}
public override void OnStart()
private void Start()
{
if (!autoStart) return;
_service.Port = port;
_service.Start();
}
public override void OnDestroyComponent()
{
_service.Stop();
destroyCancellationToken.Register(_service.Stop);
}
void IHttpListenerService.Start()