Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
car-sim-remaster
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
9631059
car-sim-remaster
Commits
7bacb786
Commit
7bacb786
authored
May 16, 2020
by
kash
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
checkpoint is changed
parent
cfacc7b0
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
2744 additions
and
2503 deletions
+2744
-2503
Assembly-CSharp-Editor-firstpass.csproj
Assembly-CSharp-Editor-firstpass.csproj
+599
-586
Assembly-CSharp-Editor.csproj
Assembly-CSharp-Editor.csproj
+605
-592
Assembly-CSharp-firstpass.csproj
Assembly-CSharp-firstpass.csproj
+658
-651
Assembly-CSharp.csproj
Assembly-CSharp.csproj
+649
-642
SampleScene.unity
Assets/Scenes/SampleScene.unity
+171
-13
IKD_DemoController.cs
...TheGameOn/IK Driver/Scripts/Utility/IKD_DemoController.cs
+2
-0
IKD_VehicleController_LeftSteering (1) Variant.prefab
...abs/IKD_VehicleController_LeftSteering (1) Variant.prefab
+1
-1
final orginal.prefab
Assets/prefabs/final orginal.prefab
+15
-15
CarCustom.cs
Assets/scripts/CarCustom.cs
+7
-0
CheckPointBlock.cs
Assets/scripts/CheckPointBlock.cs
+13
-2
Respawner.cs
Assets/scripts/Respawner.cs
+12
-1
CarSimulation.sln
CarSimulation.sln
+12
-0
No files found.
Assembly-CSharp-Editor-firstpass.csproj
View file @
7bacb786
This diff is collapsed.
Click to expand it.
Assembly-CSharp-Editor.csproj
View file @
7bacb786
This diff is collapsed.
Click to expand it.
Assembly-CSharp-firstpass.csproj
View file @
7bacb786
This diff is collapsed.
Click to expand it.
Assembly-CSharp.csproj
View file @
7bacb786
This diff is collapsed.
Click to expand it.
Assets/Scenes/SampleScene.unity
View file @
7bacb786
...
...
@@ -212,7 +212,7 @@ Transform:
m_LocalScale
:
{
x
:
1000.0001
,
y
:
1
,
z
:
999.9999
}
m_Children
:
[]
m_Father
:
{
fileID
:
0
}
m_RootOrder
:
6
m_RootOrder
:
8
m_LocalEulerAnglesHint
:
{
x
:
0.611
,
y
:
0.0050000004
,
z
:
0.84700006
}
---
!u!1001
&698900617
PrefabInstance
:
...
...
@@ -269,7 +269,7 @@ PrefabInstance:
-
target
:
{
fileID
:
2070773664156325756
,
guid
:
916384947382a4841bf79597a9e136ab
,
type
:
3
}
propertyPath
:
m_RootOrder
value
:
2
value
:
3
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
2070773664156325756
,
guid
:
916384947382a4841bf79597a9e136ab
,
type
:
3
}
...
...
@@ -313,6 +313,90 @@ PrefabInstance:
objectReference
:
{
fileID
:
0
}
m_RemovedComponents
:
[]
m_SourcePrefab
:
{
fileID
:
100100000
,
guid
:
916384947382a4841bf79597a9e136ab
,
type
:
3
}
---
!u!1001
&704967053
PrefabInstance
:
m_ObjectHideFlags
:
0
serializedVersion
:
2
m_Modification
:
m_TransformParent
:
{
fileID
:
0
}
m_Modifications
:
-
target
:
{
fileID
:
6517492368474291616
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_Name
value
:
final orginal (2)
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291616
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_IsActive
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalPosition.x
value
:
-86.529755
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalPosition.y
value
:
0.1
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalPosition.z
value
:
98.76987
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalRotation.x
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalRotation.y
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalRotation.z
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalRotation.w
value
:
1
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_RootOrder
value
:
1
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalEulerAnglesHint.x
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalEulerAnglesHint.y
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_LocalEulerAnglesHint.z
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492369421744767
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_AnchorMax.x
value
:
1
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492369421744767
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_AnchorMax.y
value
:
1
objectReference
:
{
fileID
:
0
}
m_RemovedComponents
:
[]
m_SourcePrefab
:
{
fileID
:
100100000
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
---
!u!1
&705507993
GameObject
:
m_ObjectHideFlags
:
0
...
...
@@ -376,7 +460,7 @@ Light:
m_Cookie
:
{
fileID
:
0
}
m_DrawHalo
:
0
m_Flare
:
{
fileID
:
0
}
m_RenderMode
:
0
m_RenderMode
:
2
m_CullingMask
:
serializedVersion
:
2
m_Bits
:
4294967295
...
...
@@ -403,7 +487,7 @@ Transform:
m_LocalScale
:
{
x
:
1
,
y
:
1
,
z
:
1
}
m_Children
:
[]
m_Father
:
{
fileID
:
0
}
m_RootOrder
:
3
m_RootOrder
:
5
m_LocalEulerAnglesHint
:
{
x
:
50
,
y
:
-30
,
z
:
0
}
---
!u!1
&921569260
stripped
GameObject
:
...
...
@@ -423,8 +507,8 @@ MonoBehaviour:
m_Script
:
{
fileID
:
11500000
,
guid
:
fd8f749340a45ff4599bef5d4126805f
,
type
:
3
}
m_Name
:
m_EditorClassIdentifier
:
respawn
:
32
playerCar
:
{
fileID
:
0
}
respawn
:
256
firstPointComeBack
:
257
---
!u!1
&1040609189
GameObject
:
m_ObjectHideFlags
:
0
...
...
@@ -518,6 +602,80 @@ Transform:
m_Father
:
{
fileID
:
2008584242
}
m_RootOrder
:
4
m_LocalEulerAnglesHint
:
{
x
:
0
,
y
:
0
,
z
:
0
}
---
!u!1001
&1244552652
PrefabInstance
:
m_ObjectHideFlags
:
0
serializedVersion
:
2
m_Modification
:
m_TransformParent
:
{
fileID
:
0
}
m_Modifications
:
-
target
:
{
fileID
:
482569686955208340
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_Name
value
:
checkPoint (1)
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6766326031438728971
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
carPosition
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalPosition.x
value
:
-16.27
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalPosition.y
value
:
2.18
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalPosition.z
value
:
29.405954
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalRotation.x
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalRotation.y
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalRotation.z
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalRotation.w
value
:
1
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_RootOrder
value
:
1
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalEulerAnglesHint.x
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalEulerAnglesHint.y
value
:
0
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalEulerAnglesHint.z
value
:
0
objectReference
:
{
fileID
:
0
}
m_RemovedComponents
:
[]
m_SourcePrefab
:
{
fileID
:
100100000
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
---
!u!1001
&1281597507
PrefabInstance
:
m_ObjectHideFlags
:
0
...
...
@@ -1096,7 +1254,7 @@ Transform:
m_LocalScale
:
{
x
:
1
,
y
:
1
,
z
:
1
}
m_Children
:
[]
m_Father
:
{
fileID
:
0
}
m_RootOrder
:
5
m_RootOrder
:
7
m_LocalEulerAnglesHint
:
{
x
:
0
,
y
:
0
,
z
:
0
}
---
!u!1
&1991534405
GameObject
:
...
...
@@ -1226,7 +1384,7 @@ Transform:
-
{
fileID
:
1614892422
}
-
{
fileID
:
1389580375
}
m_Father
:
{
fileID
:
0
}
m_RootOrder
:
7
m_RootOrder
:
9
m_LocalEulerAnglesHint
:
{
x
:
0
,
y
:
0
,
z
:
0
}
---
!u!1001
&2047104779
PrefabInstance
:
...
...
@@ -1568,7 +1726,7 @@ PrefabInstance:
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
propertyPath
:
m_RootOrder
value
:
1
value
:
2
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
6517492368474291627
,
guid
:
93ab9d7bcd8b80744ab77a800f1db95b
,
type
:
3
}
...
...
@@ -1677,17 +1835,17 @@ PrefabInstance:
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalPosition.x
value
:
-3
7.9
value
:
-3
9.37
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalPosition.y
value
:
4.75
value
:
1.7
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_LocalPosition.z
value
:
1
73
value
:
1
69.8
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
...
...
@@ -1712,7 +1870,7 @@ PrefabInstance:
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
propertyPath
:
m_RootOrder
value
:
4
value
:
5
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
8768170946503470804
,
guid
:
56244b3d420d5a3459e68449d1f30fbf
,
type
:
3
}
...
...
Assets/TurnTheGameOn/IK Driver/Scripts/Utility/IKD_DemoController.cs
View file @
7bacb786
...
...
@@ -15,6 +15,8 @@ namespace TurnTheGameOn.IKDriver
void
Awake
()
{
CheckPointBlock
.
startPos
=
spawnPoint
.
position
;
CheckPointBlock
.
startRotation
=
spawnPoint
.
rotation
;
if
(
instance
==
null
)
{
instance
=
this
;
...
...
Assets/prefabs/IKD_VehicleController_LeftSteering (1) Variant.prefab
View file @
7bacb786
...
...
@@ -25,7 +25,7 @@ PrefabInstance:
m_Modifications
:
-
target
:
{
fileID
:
1000011867238672
,
guid
:
69b0f3c24e475f845af6f1c0c6a6cb9c
,
type
:
3
}
propertyPath
:
m_Name
value
:
IKD_VehicleController_LeftSteering (1)
value
:
IKD_VehicleController_LeftSteering (1)
Variant
objectReference
:
{
fileID
:
0
}
-
target
:
{
fileID
:
4000012522471688
,
guid
:
69b0f3c24e475f845af6f1c0c6a6cb9c
,
type
:
3
}
propertyPath
:
m_LocalPosition.x
...
...
Assets/prefabs/final orginal.prefab
View file @
7bacb786
...
...
@@ -1829,7 +1829,7 @@ Transform:
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492368203522143
}
m_LocalRotation
:
{
x
:
-0
,
y
:
-0
,
z
:
1.6007105e-10
,
w
:
1
}
m_LocalPosition
:
{
x
:
-0
.001999421
,
y
:
-0.0050002486
,
z
:
0.65099543
}
m_LocalPosition
:
{
x
:
-0
,
y
:
-0.05
,
z
:
0.65099543
}
m_LocalScale
:
{
x
:
0.745
,
y
:
0.7449999
,
z
:
0.74499977
}
m_Children
:
-
{
fileID
:
6517492368741194658
}
...
...
@@ -3925,9 +3925,9 @@ MonoBehaviour:
m_Script
:
{
fileID
:
11500000
,
guid
:
01f5ea7715eedc646ba52b708224b72b
,
type
:
3
}
m_Name
:
m_EditorClassIdentifier
:
naturalFreaquency
:
1
0
dampingRatio
:
1.5
forceshift
:
0
naturalFreaquency
:
1
3.1
dampingRatio
:
3
forceshift
:
0
.2
setSus
:
1
---
!u!114
&4444491943193057865
MonoBehaviour
:
...
...
@@ -4700,7 +4700,7 @@ AudioListener:
m_PrefabInstance
:
{
fileID
:
0
}
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492368601468568
}
m_Enabled
:
1
m_Enabled
:
0
---
!u!1
&6517492368607147318
GameObject
:
m_ObjectHideFlags
:
0
...
...
@@ -10166,8 +10166,8 @@ Transform:
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492368692776198
}
m_LocalRotation
:
{
x
:
-0
,
y
:
-0
,
z
:
4.024514e-10
,
w
:
1
}
m_LocalPosition
:
{
x
:
-1.0849601
,
y
:
0.
70719963
,
z
:
-2.8024435
}
m_LocalScale
:
{
x
:
1.0000001
,
y
:
1
,
z
:
0.9999996
}
m_LocalPosition
:
{
x
:
-1.0849601
,
y
:
0.
66
,
z
:
-2.802412
}
m_LocalScale
:
{
x
:
0.8
,
y
:
0.8
,
z
:
0.8
}
m_Children
:
[]
m_Father
:
{
fileID
:
6517492368203522136
}
m_RootOrder
:
3
...
...
@@ -10515,8 +10515,8 @@ Transform:
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492368741194657
}
m_LocalRotation
:
{
x
:
-0
,
y
:
-0
,
z
:
4.024514e-10
,
w
:
1
}
m_LocalPosition
:
{
x
:
1.1166323
,
y
:
0.6
5859133
,
z
:
0.9659908
}
m_LocalScale
:
{
x
:
1.0000001
,
y
:
1
,
z
:
0.9999996
}
m_LocalPosition
:
{
x
:
1.1166323
,
y
:
0.6
6
,
z
:
0.9659908
}
m_LocalScale
:
{
x
:
0.8
,
y
:
0.8
,
z
:
0.8
}
m_Children
:
[]
m_Father
:
{
fileID
:
6517492368203522136
}
m_RootOrder
:
0
...
...
@@ -11016,7 +11016,7 @@ AudioListener:
m_PrefabInstance
:
{
fileID
:
0
}
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492368844175641
}
m_Enabled
:
1
m_Enabled
:
0
---
!u!1
&6517492368884086041
GameObject
:
m_ObjectHideFlags
:
0
...
...
@@ -11421,7 +11421,7 @@ AudioListener:
m_PrefabInstance
:
{
fileID
:
0
}
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492369058466485
}
m_Enabled
:
1
m_Enabled
:
0
---
!u!1
&6517492369093988314
GameObject
:
m_ObjectHideFlags
:
0
...
...
@@ -17571,8 +17571,8 @@ Transform:
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492369344569333
}
m_LocalRotation
:
{
x
:
-0
,
y
:
-0
,
z
:
4.024514e-10
,
w
:
1
}
m_LocalPosition
:
{
x
:
-1.087161
,
y
:
0.6
5950435
,
z
:
0.9659606
}
m_LocalScale
:
{
x
:
1.0000001
,
y
:
1
,
z
:
0.9999996
}
m_LocalPosition
:
{
x
:
-1.087161
,
y
:
0.6
6
,
z
:
0.9659908
}
m_LocalScale
:
{
x
:
0.8
,
y
:
0.8
,
z
:
0.8
}
m_Children
:
[]
m_Father
:
{
fileID
:
6517492368203522136
}
m_RootOrder
:
1
...
...
@@ -18689,8 +18689,8 @@ Transform:
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
6517492369559257458
}
m_LocalRotation
:
{
x
:
-0
,
y
:
-0
,
z
:
4.024514e-10
,
w
:
1
}
m_LocalPosition
:
{
x
:
1.118831
,
y
:
0.
70624083
,
z
:
-2.802412
}
m_LocalScale
:
{
x
:
1.0000001
,
y
:
1
,
z
:
0.9999996
}
m_LocalPosition
:
{
x
:
1.118831
,
y
:
0.
66
,
z
:
-2.802412
}
m_LocalScale
:
{
x
:
0.8
,
y
:
0.8
,
z
:
0.8
}
m_Children
:
[]
m_Father
:
{
fileID
:
6517492368203522136
}
m_RootOrder
:
2
...
...
Assets/scripts/CarCustom.cs
View file @
7bacb786
...
...
@@ -8,6 +8,7 @@ public class CarCustom : MonoBehaviour
private
void
Start
()
{
Respawner
.
myLoader
+=
respawn
;
Respawner
.
comeBackToStart
+=
spawnFirstPlace
;
}
public
void
respawn
()
...
...
@@ -21,4 +22,10 @@ public class CarCustom : MonoBehaviour
{
Respawner
.
myLoader
-=
respawn
;
}
public
void
spawnFirstPlace
()
{
transform
.
position
=
CheckPointBlock
.
position
;
transform
.
rotation
=
CheckPointBlock
.
rotaion
;
}
}
Assets/scripts/CheckPointBlock.cs
View file @
7bacb786
...
...
@@ -6,6 +6,9 @@ public class CheckPointBlock : MonoBehaviour
{
public
static
Vector3
position
;
public
static
Quaternion
rotaion
;
public
static
Vector3
startPos
;
public
static
Quaternion
startRotation
;
public
bool
carPosition
;
// Start is called before the first frame update
void
Start
()
{
...
...
@@ -22,8 +25,16 @@ public class CheckPointBlock : MonoBehaviour
{
if
(
other
.
tag
==
"Player"
)
{
CheckPointBlock
.
position
=
this
.
transform
.
position
;
CheckPointBlock
.
rotaion
=
this
.
transform
.
rotation
;
if
(
carPosition
)
{
CheckPointBlock
.
position
=
other
.
transform
.
position
;
CheckPointBlock
.
rotaion
=
other
.
transform
.
rotation
;
}
else
{
CheckPointBlock
.
position
=
this
.
transform
.
position
+
Vector3
.
up
*
0.2f
;
CheckPointBlock
.
rotaion
=
this
.
transform
.
rotation
;
}
Debug
.
Log
(
"check point"
);
}
}
...
...
Assets/scripts/Respawner.cs
View file @
7bacb786
...
...
@@ -6,8 +6,10 @@ using UnityEngine;
public
class
Respawner
:
MonoBehaviour
{
public
KeyCode
respawn
;
public
KeyCode
firstPointComeBack
;
public
static
Action
myLoader
;
public
static
Action
comeBackToStart
;
void
Update
()
...
...
@@ -17,6 +19,15 @@ public class Respawner : MonoBehaviour
if
(
myLoader
!=
null
)
myLoader
();
}
if
(
Input
.
GetKeyDown
(
firstPointComeBack
))
{
if
(
comeBackToStart
!=
null
)
comeBackToStart
();
}
}
}
CarSimulation.sln
View file @
7bacb786
...
...
@@ -3,6 +3,10 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp", "Assembly-CSharp.csproj", "{44D98F77-9C9E-A550-30C0-1838473E3E46}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp-firstpass", "Assembly-CSharp-firstpass.csproj", "{39424FBA-72DC-78AB-BF56-A627E86AD9B1}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp-Editor-firstpass", "Assembly-CSharp-Editor-firstpass.csproj", "{F10F4906-99B8-E8E7-F752-EF7B4ED69D61}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp-Editor", "Assembly-CSharp-Editor.csproj", "{56E6D49F-D179-E3A5-5661-AE2C6E05FDC6}"
EndProject
Global
...
...
@@ -15,6 +19,14 @@ Global
{44D98F77-9C9E-A550-30C0-1838473E3E46}.Debug|Any CPU.Build.0 = Debug|Any CPU
{44D98F77-9C9E-A550-30C0-1838473E3E46}.Release|Any CPU.ActiveCfg = Release|Any CPU
{44D98F77-9C9E-A550-30C0-1838473E3E46}.Release|Any CPU.Build.0 = Release|Any CPU
{39424FBA-72DC-78AB-BF56-A627E86AD9B1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{39424FBA-72DC-78AB-BF56-A627E86AD9B1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{39424FBA-72DC-78AB-BF56-A627E86AD9B1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{39424FBA-72DC-78AB-BF56-A627E86AD9B1}.Release|Any CPU.Build.0 = Release|Any CPU
{F10F4906-99B8-E8E7-F752-EF7B4ED69D61}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F10F4906-99B8-E8E7-F752-EF7B4ED69D61}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F10F4906-99B8-E8E7-F752-EF7B4ED69D61}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F10F4906-99B8-E8E7-F752-EF7B4ED69D61}.Release|Any CPU.Build.0 = Release|Any CPU
{56E6D49F-D179-E3A5-5661-AE2C6E05FDC6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{56E6D49F-D179-E3A5-5661-AE2C6E05FDC6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{56E6D49F-D179-E3A5-5661-AE2C6E05FDC6}.Release|Any CPU.ActiveCfg = Release|Any CPU
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment