This repository was archived by the owner on Sep 15, 2024. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -11,7 +11,6 @@ public enum ClientPacketOpcode
1111 LobbyGameStart ,
1212 PlayerDirectionPressed ,
1313 PlayerDirectionReleased ,
14- PlayerPosition ,
1514 ProcessDelta
1615 }
1716
Original file line number Diff line number Diff line change @@ -11,8 +11,6 @@ namespace Game
1111 public class ClientPlayer : OtherPlayer
1212 {
1313 private float Speed = 250f ;
14-
15- private Timer TimerNotifyServerClientPosition { get ; set ; }
1614 private Timer TimerNotifyServerProcessDelta { get ; set ; }
1715 private float Delta { get ; set ; }
1816
@@ -23,11 +21,6 @@ public override void _Ready()
2321
2422 if ( GameClient . Running )
2523 {
26- TimerNotifyServerClientPosition = new Timer ( 2000 ) ;
27- TimerNotifyServerClientPosition . Elapsed += TimerNotifyServerClientPositionCallback ;
28- TimerNotifyServerClientPosition . AutoReset = true ;
29- TimerNotifyServerClientPosition . Enabled = true ;
30-
3124 if ( GameClient . IsHost )
3225 {
3326 TimerNotifyServerProcessDelta = new Timer ( 3000 ) ;
@@ -38,14 +31,6 @@ public override void _Ready()
3831 }
3932 }
4033
41- public async void TimerNotifyServerClientPositionCallback ( System . Object source , ElapsedEventArgs args )
42- {
43- await GameClient . Send ( ClientPacketOpcode . PlayerPosition , new CPacketPlayerPosition
44- {
45- Position = Position
46- } ) ;
47- }
48-
4934 public async void TimerNotifyServerProcessDeltaCallback ( System . Object source , ElapsedEventArgs args )
5035 {
5136 await GameClient . Send ( ClientPacketOpcode . ProcessDelta , new CPacketProcessDelta
You can’t perform that action at this time.
0 commit comments