NetOuterComponent.cs 835 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. namespace ETModel
  2. {
  3. [ObjectSystem]
  4. public class NetOuterComponentAwakeSystem : AwakeSystem<NetOuterComponent>
  5. {
  6. public override void Awake(NetOuterComponent self)
  7. {
  8. self.Awake();
  9. }
  10. }
  11. [ObjectSystem]
  12. public class NetOuterComponentStartSystem : StartSystem<NetOuterComponent>
  13. {
  14. public override void Start(NetOuterComponent self)
  15. {
  16. self.Start();
  17. }
  18. }
  19. [ObjectSystem]
  20. public class NetOuterComponentUpdateSystem : UpdateSystem<NetOuterComponent>
  21. {
  22. public override void Update(NetOuterComponent self)
  23. {
  24. self.Update();
  25. }
  26. }
  27. public class NetOuterComponent : NetworkComponent
  28. {
  29. public void Awake()
  30. {
  31. this.Awake(NetworkProtocol.KCP);
  32. this.MessagePacker = new ProtobufPacker();
  33. this.MessageDispatcher = new ClientDispatcher();
  34. }
  35. public new void Update()
  36. {
  37. base.Update();
  38. }
  39. }
  40. }