Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
car
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
SparkProjects
car
Commits
8ff2941f
Commit
8ff2941f
authored
Jun 04, 2025
by
haiyoucuv
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
init
parent
5f7fbf4b
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
289 additions
and
47 deletions
+289
-47
level3.prefab
assets/Bundles/MainGame/Levels/level3.prefab
+3
-3
Car8.prefab
assets/Bundles/MainGame/prefab/Car8.prefab
+282
-34
CarCarColorsComponent.ts
...ripts/Scenes/MainGame/Components/CarCarColorsComponent.ts
+1
-8
RoleCarColorsComponent.ts
...ipts/Scenes/MainGame/Components/RoleCarColorsComponent.ts
+2
-2
CarCarColorsSysterm.ts
...s/Scripts/Scenes/MainGame/Systerms/CarCarColorsSysterm.ts
+1
-0
No files found.
assets/Bundles/MainGame/Levels/level3.prefab
View file @
8ff2941f
...
...
@@ -3495,9 +3495,9 @@
"value": {
"__type__": "cc.Quat",
"x": 0,
"y":
-0.8660254037844386
,
"y":
0.49999999999999994
,
"z": 0,
"w": 0.
5000000000000001
"w": 0.
8660254037844387
}
},
{
...
...
@@ -3511,7 +3511,7 @@
"value": {
"__type__": "cc.Vec3",
"x": 0,
"y":
-12
0,
"y":
6
0,
"z": 0
}
},
...
...
assets/Bundles/MainGame/prefab/Car8.prefab
View file @
8ff2941f
...
...
@@ -28,23 +28,23 @@
"__id__": 71
},
{
"__id__": 1
0
3
"__id__": 1
1
3
}
],
"_active": true,
"_components": [
{
"__id__": 1
0
8
"__id__": 1
1
8
},
{
"__id__": 1
1
0
"__id__": 1
2
0
},
{
"__id__": 1
1
2
"__id__": 1
2
2
}
],
"_prefab": {
"__id__": 1
2
4
"__id__": 1
3
4
},
"_lpos": {
"__type__": "cc.Vec3",
...
...
@@ -959,12 +959,18 @@
},
{
"__id__": 97
},
{
"__id__": 102
},
{
"__id__": 107
}
],
"_active": true,
"_components": [],
"_prefab": {
"__id__": 1
0
2
"__id__": 1
1
2
},
"_lpos": {
"__type__": "cc.Vec3",
...
...
@@ -1721,6 +1727,248 @@
"targetOverrides": null,
"nestedPrefabInstanceRoots": null
},
{
"__type__": "cc.Node",
"_name": "Cube-006",
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 71
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 103
}
],
"_prefab": {
"__id__": 106
},
"_lpos": {
"__type__": "cc.Vec3",
"x": 0.25,
"y": 0.859,
"z": 1.16
},
"_lrot": {
"__type__": "cc.Quat",
"x": 0,
"y": 0,
"z": 0,
"w": 1
},
"_lscale": {
"__type__": "cc.Vec3",
"x": 1,
"y": 1,
"z": 1
},
"_mobility": 0,
"_layer": 1073741824,
"_euler": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_id": ""
},
{
"__type__": "cc.MeshRenderer",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 102
},
"_enabled": true,
"__prefab": {
"__id__": 104
},
"_materials": [
{
"__uuid__": "087d3ec0-23db-4b57-88c8-12e83b579ddc",
"__expectedType__": "cc.Material"
}
],
"_visFlags": 0,
"bakeSettings": {
"__id__": 105
},
"_mesh": {
"__uuid__": "c8349573-cd69-452d-acda-15354882576c@bc06f",
"__expectedType__": "cc.Mesh"
},
"_shadowCastingMode": 0,
"_shadowReceivingMode": 1,
"_shadowBias": 0,
"_shadowNormalBias": 0,
"_reflectionProbeId": -1,
"_reflectionProbeBlendId": -1,
"_reflectionProbeBlendWeight": 0,
"_enabledGlobalStandardSkinObject": false,
"_enableMorph": true,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "66jvpCTrNON45yQaw27xmY"
},
{
"__type__": "cc.ModelBakeSettings",
"texture": null,
"uvParam": {
"__type__": "cc.Vec4",
"x": 0,
"y": 0,
"z": 0,
"w": 0
},
"_bakeable": false,
"_castShadow": false,
"_receiveShadow": false,
"_recieveShadow": false,
"_lightmapSize": 64,
"_useLightProbe": false,
"_bakeToLightProbe": true,
"_reflectionProbeType": 0,
"_bakeToReflectionProbe": true
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__id__": 0
},
"fileId": "f3thH0Mz5IXZthzMqgtQqH",
"instance": null,
"targetOverrides": null,
"nestedPrefabInstanceRoots": null
},
{
"__type__": "cc.Node",
"_name": "Cube-007",
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 71
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 108
}
],
"_prefab": {
"__id__": 111
},
"_lpos": {
"__type__": "cc.Vec3",
"x": -0.25,
"y": 0.859,
"z": 1.16
},
"_lrot": {
"__type__": "cc.Quat",
"x": 0,
"y": 0,
"z": 0,
"w": 1
},
"_lscale": {
"__type__": "cc.Vec3",
"x": 1,
"y": 1,
"z": 1
},
"_mobility": 0,
"_layer": 1073741824,
"_euler": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_id": ""
},
{
"__type__": "cc.MeshRenderer",
"_name": "",
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 107
},
"_enabled": true,
"__prefab": {
"__id__": 109
},
"_materials": [
{
"__uuid__": "087d3ec0-23db-4b57-88c8-12e83b579ddc",
"__expectedType__": "cc.Material"
}
],
"_visFlags": 0,
"bakeSettings": {
"__id__": 110
},
"_mesh": {
"__uuid__": "c8349573-cd69-452d-acda-15354882576c@bc06f",
"__expectedType__": "cc.Mesh"
},
"_shadowCastingMode": 0,
"_shadowReceivingMode": 1,
"_shadowBias": 0,
"_shadowNormalBias": 0,
"_reflectionProbeId": -1,
"_reflectionProbeBlendId": -1,
"_reflectionProbeBlendWeight": 0,
"_enabledGlobalStandardSkinObject": false,
"_enableMorph": true,
"_id": ""
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "05yB7N43lLc6opUBnXERQr"
},
{
"__type__": "cc.ModelBakeSettings",
"texture": null,
"uvParam": {
"__type__": "cc.Vec4",
"x": 0,
"y": 0,
"z": 0,
"w": 0
},
"_bakeable": false,
"_castShadow": false,
"_receiveShadow": false,
"_recieveShadow": false,
"_lightmapSize": 64,
"_useLightProbe": false,
"_bakeToLightProbe": true,
"_reflectionProbeType": 0,
"_bakeToReflectionProbe": true
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__id__": 0
},
"fileId": "cem5hE7e9IEZTImmrN7J2q",
"instance": null,
"targetOverrides": null,
"nestedPrefabInstanceRoots": null
},
{
"__type__": "cc.PrefabInfo",
"root": {
...
...
@@ -1746,11 +1994,11 @@
"_active": true,
"_components": [
{
"__id__": 1
0
4
"__id__": 1
1
4
}
],
"_prefab": {
"__id__": 1
0
7
"__id__": 1
1
7
},
"_lpos": {
"__type__": "cc.Vec3",
...
...
@@ -1787,11 +2035,11 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 1
0
3
"__id__": 1
1
3
},
"_enabled": true,
"__prefab": {
"__id__": 1
0
5
"__id__": 1
1
5
},
"_materials": [
{
...
...
@@ -1801,7 +2049,7 @@
],
"_visFlags": 0,
"bakeSettings": {
"__id__": 1
0
6
"__id__": 1
1
6
},
"_mesh": {
"__uuid__": "1263d74c-8167-4928-91a6-4e2672411f47@2e76e",
...
...
@@ -1865,7 +2113,7 @@
},
"_enabled": true,
"__prefab": {
"__id__": 1
0
9
"__id__": 1
1
9
},
"_group": 2,
"_type": 4,
...
...
@@ -1902,7 +2150,7 @@
},
"_enabled": true,
"__prefab": {
"__id__": 1
1
1
"__id__": 1
2
1
},
"_material": null,
"_isTrigger": true,
...
...
@@ -1934,7 +2182,7 @@
},
"_enabled": true,
"__prefab": {
"__id__": 1
1
3
"__id__": 1
2
3
},
"carType": 2,
"_carColor": 5,
...
...
@@ -1973,10 +2221,10 @@
}
],
"bodyMesh": {
"__id__": 1
1
4
"__id__": 1
2
4
},
"top": {
"__id__": 1
1
7
"__id__": 1
2
7
},
"_id": ""
},
...
...
@@ -1990,11 +2238,11 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 1
1
5
"__id__": 1
2
5
},
"_enabled": true,
"__prefab": {
"__id__": 1
2
2
"__id__": 1
3
2
},
"_materials": [
{
...
...
@@ -2008,7 +2256,7 @@
],
"_visFlags": 0,
"bakeSettings": {
"__id__": 1
2
3
"__id__": 1
3
3
},
"_mesh": {
"__uuid__": "8e9c0e2b-bb1f-424d-bbe2-b63e83bea2db@fe082",
...
...
@@ -2035,17 +2283,17 @@
},
"_children": [
{
"__id__": 1
1
6
"__id__": 1
2
6
}
],
"_active": true,
"_components": [
{
"__id__": 1
1
4
"__id__": 1
2
4
}
],
"_prefab": {
"__id__": 1
2
1
"__id__": 1
3
1
},
"_lpos": {
"__type__": "cc.Vec3",
...
...
@@ -2082,17 +2330,17 @@
"_objFlags": 0,
"__editorExtras__": {},
"_parent": {
"__id__": 1
1
5
"__id__": 1
2
5
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
1
7
"__id__": 1
2
7
}
],
"_prefab": {
"__id__": 1
2
0
"__id__": 1
3
0
},
"_lpos": {
"__type__": "cc.Vec3",
...
...
@@ -2129,11 +2377,11 @@
"_objFlags": 0,
"__editorExtras__": {},
"node": {
"__id__": 1
1
6
"__id__": 1
2
6
},
"_enabled": true,
"__prefab": {
"__id__": 1
1
8
"__id__": 1
2
8
},
"_materials": [
{
...
...
@@ -2143,7 +2391,7 @@
],
"_visFlags": 0,
"bakeSettings": {
"__id__": 1
1
9
"__id__": 1
2
9
},
"_mesh": {
"__uuid__": "8e9c0e2b-bb1f-424d-bbe2-b63e83bea2db@b4725",
...
...
@@ -2246,10 +2494,10 @@
"instance": null,
"targetOverrides": [
{
"__id__": 1
2
5
"__id__": 1
3
5
},
{
"__id__": 1
2
7
"__id__": 1
3
7
}
],
"nestedPrefabInstanceRoots": [
...
...
@@ -2273,7 +2521,7 @@
{
"__type__": "cc.TargetOverrideInfo",
"source": {
"__id__": 1
1
2
"__id__": 1
2
2
},
"sourceInfo": null,
"propertyPath": [
...
...
@@ -2283,7 +2531,7 @@
"__id__": 2
},
"targetInfo": {
"__id__": 1
2
6
"__id__": 1
3
6
}
},
{
...
...
@@ -2295,7 +2543,7 @@
{
"__type__": "cc.TargetOverrideInfo",
"source": {
"__id__": 1
1
2
"__id__": 1
2
2
},
"sourceInfo": null,
"propertyPath": [
...
...
@@ -2305,7 +2553,7 @@
"__id__": 2
},
"targetInfo": {
"__id__": 1
2
8
"__id__": 1
3
8
}
},
{
...
...
assets/Scripts/Scenes/MainGame/Components/CarCarColorsComponent.ts
View file @
8ff2941f
...
...
@@ -95,14 +95,7 @@ export class CarCarColorsComponent extends Component {
this
.
tweenCount
+=
1
this
.
roleNum
+=
1
if
(
this
.
carType
===
CarTypes
.
CAR8
)
{
this
.
isFull
=
this
.
roleNum
>=
8
}
else
if
(
this
.
carType
===
CarTypes
.
CAR6
)
{
this
.
isFull
=
this
.
roleNum
>=
6
}
else
if
(
this
.
carType
===
CarTypes
.
CAR10
)
{
this
.
isFull
=
this
.
roleNum
>=
10
}
this
.
isFull
=
this
.
roleNum
>=
this
.
node
.
getChildByName
(
"Seets"
).
children
.
length
;
return
this
.
isFull
}
...
...
assets/Scripts/Scenes/MainGame/Components/RoleCarColorsComponent.ts
View file @
8ff2941f
...
...
@@ -45,7 +45,7 @@ export class RoleCarColorsComponent extends Component {
playWalk
()
{
if
(
this
.
status
===
"walk"
)
return
;
this
.
node
.
children
[
0
].
setScale
(
1
0
,
10
,
10
);
this
.
node
.
children
[
0
].
setScale
(
1
2
,
12
,
12
);
this
.
status
=
"walk"
;
this
.
animation
.
play
(
"run"
);
}
...
...
@@ -58,7 +58,7 @@ export class RoleCarColorsComponent extends Component {
playIdle
()
{
if
(
this
.
status
===
"idle"
)
return
this
.
node
.
children
[
0
].
setScale
(
1
0
,
10
,
10
);
this
.
node
.
children
[
0
].
setScale
(
1
2
,
12
,
12
);
this
.
status
=
"idle"
;
const
names
=
[
"idel_1"
,
"idel_2"
,
"idel_3"
];
this
.
animation
.
play
(
names
[
randomRangeInt
(
0
,
4
)]);
...
...
assets/Scripts/Scenes/MainGame/Systerms/CarCarColorsSysterm.ts
View file @
8ff2941f
...
...
@@ -39,6 +39,7 @@ export class CarCarColorsSysterm extends Component {
}
for
(;
len
--
;)
{
console
.
log
(
`添加车座
${
color
}
${
len
}
`
)
this
.
carSeats
.
push
(
color
)
}
}
...
...
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