netwo
This commit is contained in:
@@ -164,7 +164,6 @@ namespace Game
|
||||
//rigidBody.TriggerExit += OnTriggerExit;
|
||||
|
||||
startupTime = Time.TimeSinceStartup;
|
||||
Console.Print("hai: " + playerActor.hai);
|
||||
}
|
||||
|
||||
public void SetInput(uint playerId)
|
||||
@@ -178,7 +177,7 @@ namespace Game
|
||||
{
|
||||
Console.Print("local player?: " + playerId.ToString());
|
||||
string demoPath = System.IO.Path.Combine(AssetManager.DemoPath, $"{DateTimeOffset.Now.UtcTicks}.gdem");
|
||||
input = new PlayerInputLocal(demoPath); // TODO: support recording
|
||||
input = new PlayerInputLocal(playerActor, demoPath); // TODO: support recording
|
||||
|
||||
}
|
||||
else
|
||||
@@ -193,7 +192,7 @@ namespace Game
|
||||
input = new PlayerInputDemo(demoFile);
|
||||
|
||||
/*Actor.Position = input.GetCurrentActorState().position;
|
||||
currentVelocity = input.GetCurrentActorState().velocity;
|
||||
currentVelocity = input.GetCurrentActorState().velocity; f
|
||||
SetCameraEulerAngles(input.GetCurrentActorState().viewAngles);*/
|
||||
Actor.Position = input.GetCurrentInputState().verificationPosition;
|
||||
//rootActor.Orientation = input.GetCurrentInputState().verificationOrientation;
|
||||
@@ -205,8 +204,8 @@ namespace Game
|
||||
{
|
||||
//var playerId = NetworkReplicator.GetObjectOwnerClientId(this.Parent);
|
||||
//SetInput(playerId);
|
||||
Console.Print("hai: " + playerActor.hai);
|
||||
SetInput(playerActor.PlayerId);
|
||||
//Console.Print("hai: " + playerActor.hai);
|
||||
//SetInput(playerActor.PlayerId);
|
||||
}
|
||||
public override void OnDisable()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user