|
@@ -19,9 +19,15 @@ namespace Logging.Data
|
|
|
private readonly float velocityY;
|
|
|
private readonly float velocityZ;
|
|
|
private readonly int collisionCounter;
|
|
|
+ private readonly int coinCounter;
|
|
|
+ private readonly int hasFinished;
|
|
|
+ private readonly int hasFinishedSlalom1;
|
|
|
+ private readonly int hasFinishedSlalom2;
|
|
|
+ private readonly string condition;
|
|
|
|
|
|
public BikeGameObjectDataLog(long timestamp, float positionX, float positionY, float positionZ, float rotationX,
|
|
|
- float rotationY, float rotationZ, float velocityX, float velocityY, float velocityZ, int collisionCounter)
|
|
|
+ float rotationY, float rotationZ, float velocityX, float velocityY, float velocityZ, int collisionCounter, int coinCounter,
|
|
|
+ int hasFinished, int hasFinishedSlalom1, int hasFinishedSlalom2, string condition)
|
|
|
{
|
|
|
this.timestamp = timestamp;
|
|
|
this.positionX = positionX;
|
|
@@ -34,6 +40,11 @@ namespace Logging.Data
|
|
|
this.velocityY = velocityY;
|
|
|
this.velocityZ = velocityZ;
|
|
|
this.collisionCounter = collisionCounter;
|
|
|
+ this.coinCounter = coinCounter;
|
|
|
+ this.hasFinished = hasFinished;
|
|
|
+ this.hasFinishedSlalom1 = hasFinishedSlalom1;
|
|
|
+ this.hasFinishedSlalom2 = hasFinishedSlalom2;
|
|
|
+ this.condition = condition;
|
|
|
}
|
|
|
|
|
|
public KeyValuePair<long, string[]> Serialize()
|
|
@@ -50,7 +61,12 @@ namespace Logging.Data
|
|
|
velocityX.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
velocityY.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
velocityZ.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
- collisionCounter.ToString("F6", CultureInfo.InvariantCulture)
|
|
|
+ collisionCounter.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
+ coinCounter.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
+ hasFinished.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
+ hasFinishedSlalom1.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
+ hasFinishedSlalom2.ToString("F6", CultureInfo.InvariantCulture),
|
|
|
+ condition,
|
|
|
});
|
|
|
}
|
|
|
}
|
|
@@ -80,7 +96,14 @@ namespace Logging.Data
|
|
|
Log(new BikeGameObjectDataLog(Helpers.RoundToLong(Time.time * 1000),
|
|
|
pos.x, pos.y, pos.z,
|
|
|
rot.x, rot.y, rot.z,
|
|
|
- velocity.x, velocity.y, velocity.z, playerStats.collisionCounter));
|
|
|
+ velocity.x, velocity.y, velocity.z,
|
|
|
+ playerStats.collisionCounter,
|
|
|
+ playerStats.coinCounter,
|
|
|
+ playerStats.hasFinished,
|
|
|
+ playerStats.hasFinishedSlalom1,
|
|
|
+ playerStats.hasFinishedSlalom2,
|
|
|
+ playerStats.condition
|
|
|
+ ));
|
|
|
}
|
|
|
|
|
|
public override IEnumerable<BikeGameObjectDataLog> ReadLog(IEnumerable<IEnumerable<string>> lines)
|