视角切换&小地图模糊问题解决
This commit is contained in:
1 parent
9bc3864790
commit
e4d4333357
30 files changed
+3746
-2965
No files matched your search
@@ -7,17 +7,21 @@ namespace Assets.Scenes.Ride.Scripts
|
||||
public class PlayerController : AbstractPlayer
|
||||
{
|
||||
#region 骑行逻辑
|
||||
TrailRenderer trail;
|
||||
|
||||
protected override void Init()
|
||||
protected override void Init()
|
||||
{
|
||||
base.Init();
|
||||
totalDistance = mainController.selectParamModel.EndDistance;
|
||||
currentlatlong = mainController.GetCenterCoordinate();
|
||||
TrailRenderer trail = FindObjectOfType<TrailRenderer>();
|
||||
trail = FindObjectOfType<TrailRenderer>();
|
||||
trail.startWidth = 1f;
|
||||
trail.endWidth = 1f;
|
||||
trail.startColor = new Color(0.9764706f, 0.1882353f, 0.5254902f, 0.65f);
|
||||
trail.endColor = new Color(0.9764706f, 0.1882353f, 0.5254902f, 0.65f);
|
||||
trail.startColor = new Color(0.9764706f, 0.1882353f, 0.5254902f, 1f);
|
||||
trail.endColor = new Color(0.9764706f, 0.1882353f, 0.5254902f, 1f);
|
||||
//var color7 = Resources.Load<Material>("UI/Material/color7");
|
||||
//var Graph2 = Resources.Load<Material>("UI/Material/3dGraph2");
|
||||
//trail.materials = new Material[] { color7};
|
||||
}
|
||||
TargetData targetData;
|
||||
/// <summary>
|
||||
@@ -41,6 +45,9 @@ namespace Assets.Scenes.Ride.Scripts
|
||||
speed = Helper.CalculateSpeed(elevation, currentSlope, power, weight, bicycleWeight);
|
||||
distance = mainController.UpdateDistance(speed);
|
||||
totalDistance += distance;
|
||||
|
||||
//preDistance EndDistance
|
||||
|
||||
if (!stopRecord)
|
||||
{
|
||||
//记录骑行数据
|
||||
@@ -58,7 +65,8 @@ namespace Assets.Scenes.Ride.Scripts
|
||||
_Lon = currentlatlong.y,
|
||||
_TotalClimb = totalClimb,
|
||||
};
|
||||
|
||||
recorderData.PreDistance = TotalDistance-Distance;
|
||||
recorderData.EndDistance = TotalDistance;
|
||||
recorderData.RiderDatas.Add(targetData);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user