fix: Gravity changers working, gravity strength now in character properties
This commit is contained in:
parent
9e96946b1a
commit
8eca56c0fd
@ -13,13 +13,13 @@ MonoBehaviour:
|
|||||||
m_Name: DefaultPrefabObjects
|
m_Name: DefaultPrefabObjects
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_prefabs:
|
_prefabs:
|
||||||
|
- {fileID: 6141811525297683108, guid: abf4376f1c6f28241b1125c0eac87199, type: 3}
|
||||||
|
- {fileID: 6527384552577148640, guid: 7b71eecaf6568a847b4b8415852f9e98, type: 3}
|
||||||
|
- {fileID: 6696145061262954739, guid: 6bef8667f8847d440b83722af55e8d58, type: 3}
|
||||||
- {fileID: 4320456058255827552, guid: 65cd4fa5e050652409dd9b062365c7e8, type: 3}
|
- {fileID: 4320456058255827552, guid: 65cd4fa5e050652409dd9b062365c7e8, type: 3}
|
||||||
- {fileID: 394654179909484550, guid: 9f3e27e33167d704e941e42ded557111, type: 3}
|
- {fileID: 394654179909484550, guid: 9f3e27e33167d704e941e42ded557111, type: 3}
|
||||||
- {fileID: 394654179909484550, guid: 5934082513feac04a9b875fc86abe70b, type: 3}
|
- {fileID: 394654179909484550, guid: 5934082513feac04a9b875fc86abe70b, type: 3}
|
||||||
- {fileID: 394654179909484550, guid: 46f84e56340e83e4ba7c6abbccd2ae3f, type: 3}
|
- {fileID: 394654179909484550, guid: 46f84e56340e83e4ba7c6abbccd2ae3f, type: 3}
|
||||||
- {fileID: 6141811525297683108, guid: abf4376f1c6f28241b1125c0eac87199, type: 3}
|
|
||||||
- {fileID: 6527384552577148640, guid: 7b71eecaf6568a847b4b8415852f9e98, type: 3}
|
|
||||||
- {fileID: 6696145061262954739, guid: 6bef8667f8847d440b83722af55e8d58, type: 3}
|
|
||||||
- {fileID: 8475222101369129519, guid: 8cf33e8e99a9b0c4c8f29ff725650de6, type: 3}
|
- {fileID: 8475222101369129519, guid: 8cf33e8e99a9b0c4c8f29ff725650de6, type: 3}
|
||||||
- {fileID: 4512293259955182956, guid: 44611030e61220d42ab7c37ba3c0ea92, type: 3}
|
- {fileID: 4512293259955182956, guid: 44611030e61220d42ab7c37ba3c0ea92, type: 3}
|
||||||
- {fileID: 4512293259955182956, guid: 0d6d0f48b03b17f49a6340103cd9b9d0, type: 3}
|
- {fileID: 4512293259955182956, guid: 0d6d0f48b03b17f49a6340103cd9b9d0, type: 3}
|
||||||
|
|||||||
@ -13,6 +13,7 @@ Material:
|
|||||||
m_ModifiedSerializedProperties: 0
|
m_ModifiedSerializedProperties: 0
|
||||||
m_ValidKeywords:
|
m_ValidKeywords:
|
||||||
- _ALPHAPREMULTIPLY_ON
|
- _ALPHAPREMULTIPLY_ON
|
||||||
|
- _ENVIRONMENTREFLECTIONS_OFF
|
||||||
- _MANUAL_RIPPLE
|
- _MANUAL_RIPPLE
|
||||||
- _OCCLUSIONMAP
|
- _OCCLUSIONMAP
|
||||||
- _SPECULARHIGHLIGHTS_OFF
|
- _SPECULARHIGHLIGHTS_OFF
|
||||||
|
|||||||
@ -13,6 +13,7 @@ Material:
|
|||||||
m_ModifiedSerializedProperties: 0
|
m_ModifiedSerializedProperties: 0
|
||||||
m_ValidKeywords:
|
m_ValidKeywords:
|
||||||
- _ALPHAPREMULTIPLY_ON
|
- _ALPHAPREMULTIPLY_ON
|
||||||
|
- _ENVIRONMENTREFLECTIONS_OFF
|
||||||
- _MANUAL_RIPPLE
|
- _MANUAL_RIPPLE
|
||||||
- _OCCLUSIONMAP
|
- _OCCLUSIONMAP
|
||||||
- _SPECULARHIGHLIGHTS_OFF
|
- _SPECULARHIGHLIGHTS_OFF
|
||||||
|
|||||||
@ -13,6 +13,7 @@ Material:
|
|||||||
m_ModifiedSerializedProperties: 0
|
m_ModifiedSerializedProperties: 0
|
||||||
m_ValidKeywords:
|
m_ValidKeywords:
|
||||||
- _ALPHAPREMULTIPLY_ON
|
- _ALPHAPREMULTIPLY_ON
|
||||||
|
- _ENVIRONMENTREFLECTIONS_OFF
|
||||||
- _MANUAL_RIPPLE
|
- _MANUAL_RIPPLE
|
||||||
- _OCCLUSIONMAP
|
- _OCCLUSIONMAP
|
||||||
- _SPECULARHIGHLIGHTS_OFF
|
- _SPECULARHIGHLIGHTS_OFF
|
||||||
|
|||||||
@ -26,6 +26,7 @@ Material:
|
|||||||
m_ModifiedSerializedProperties: 0
|
m_ModifiedSerializedProperties: 0
|
||||||
m_ValidKeywords:
|
m_ValidKeywords:
|
||||||
- _ALPHAPREMULTIPLY_ON
|
- _ALPHAPREMULTIPLY_ON
|
||||||
|
- _ENVIRONMENTREFLECTIONS_OFF
|
||||||
- _MANUAL_RIPPLE
|
- _MANUAL_RIPPLE
|
||||||
- _OCCLUSIONMAP
|
- _OCCLUSIONMAP
|
||||||
- _SPECULARHIGHLIGHTS_OFF
|
- _SPECULARHIGHLIGHTS_OFF
|
||||||
@ -129,7 +130,7 @@ Material:
|
|||||||
- _DstBlendAlpha: 10
|
- _DstBlendAlpha: 10
|
||||||
- _Emission: 0
|
- _Emission: 0
|
||||||
- _EnvironmentReflections: 1
|
- _EnvironmentReflections: 1
|
||||||
- _EnvironmentalReflections: 0
|
- _EnvironmentalReflections: 1
|
||||||
- _Frequency: 155
|
- _Frequency: 155
|
||||||
- _GlossMapScale: 0
|
- _GlossMapScale: 0
|
||||||
- _Glossiness: 0
|
- _Glossiness: 0
|
||||||
@ -142,7 +143,7 @@ Material:
|
|||||||
- _ManualRippleFrequency: 20
|
- _ManualRippleFrequency: 20
|
||||||
- _ManualRippleRadius: 2.5
|
- _ManualRippleRadius: 2.5
|
||||||
- _MaxWaveDistortion: 1.13
|
- _MaxWaveDistortion: 1.13
|
||||||
- _Metallic: 0.88
|
- _Metallic: 0.406
|
||||||
- _MetallicSpecGlossMapToggle: 0
|
- _MetallicSpecGlossMapToggle: 0
|
||||||
- _MetallicSpecToggle: 0
|
- _MetallicSpecToggle: 0
|
||||||
- _NormalMapToggle: 0
|
- _NormalMapToggle: 0
|
||||||
@ -151,7 +152,7 @@ Material:
|
|||||||
- _Parallax: 0.005
|
- _Parallax: 0.005
|
||||||
- _QueueOffset: 0
|
- _QueueOffset: 0
|
||||||
- _ReceiveShadows: 1
|
- _ReceiveShadows: 1
|
||||||
- _Smoothness: 0.906
|
- _Smoothness: 1
|
||||||
- _SmoothnessSource: 0
|
- _SmoothnessSource: 0
|
||||||
- _SmoothnessTextureChannel: 1
|
- _SmoothnessTextureChannel: 1
|
||||||
- _SpecularHighlights: 1
|
- _SpecularHighlights: 1
|
||||||
@ -190,7 +191,7 @@ Material:
|
|||||||
- _ImpactOrigin: {r: 1, g: 0, b: 0, a: 0}
|
- _ImpactOrigin: {r: 1, g: 0, b: 0, a: 0}
|
||||||
- _ManualRippleOrigin: {r: 1, g: 0, b: 0, a: 0}
|
- _ManualRippleOrigin: {r: 1, g: 0, b: 0, a: 0}
|
||||||
- _ModelOrigin: {r: 0, g: 0, b: 0, a: 0}
|
- _ModelOrigin: {r: 0, g: 0, b: 0, a: 0}
|
||||||
- _SpecColor: {r: 0.990566, g: 0.990566, b: 0.990566, a: 1}
|
- _SpecColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
- _WaveOrigin: {r: 1, g: 0, b: 0, a: 0}
|
- _WaveOrigin: {r: 1, g: 0, b: 0, a: 0}
|
||||||
- _impact_origin: {r: 1, g: 0, b: 0, a: 1}
|
- _impact_origin: {r: 1, g: 0, b: 0, a: 1}
|
||||||
- _rotation: {r: 0.1, g: 0, b: 0, a: 1}
|
- _rotation: {r: 0.1, g: 0, b: 0, a: 1}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 9615c7fd8e252c145b562238bcfc1b23
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@ -32,6 +32,7 @@ Transform:
|
|||||||
m_LocalScale: {x: 3, y: 3, z: 3}
|
m_LocalScale: {x: 3, y: 3, z: 3}
|
||||||
m_ConstrainProportionsScale: 1
|
m_ConstrainProportionsScale: 1
|
||||||
m_Children:
|
m_Children:
|
||||||
|
- {fileID: 4274613733215928132}
|
||||||
- {fileID: 3847966118591952769}
|
- {fileID: 3847966118591952769}
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
@ -76,19 +77,20 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 42bb47879381c4f498a115b2b84b191a, type: 3}
|
m_Script: {fileID: 11500000, guid: 42bb47879381c4f498a115b2b84b191a, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
forcesManager: {fileID: 0}
|
ForcesManager: {fileID: 0}
|
||||||
renderedZoneObject: {fileID: 3847966118592310179}
|
RenderedZoneObject: {fileID: 3847966118592310179}
|
||||||
|
GravityEffect: {fileID: 2798249376021352391}
|
||||||
GravityColors:
|
GravityColors:
|
||||||
- gravity: 0
|
- gravity: 0
|
||||||
color: {r: 0.20188677, g: 1, b: 0.27700332, a: 0.27450982}
|
color: {r: 0.20188677, g: 1, b: 0.27700332, a: 0.3529412}
|
||||||
- gravity: 1
|
- gravity: 1
|
||||||
color: {r: 0.81708485, g: 0.20943397, b: 1, a: 0.27450982}
|
color: {r: 0.81708485, g: 0.20943397, b: 1, a: 0.3529412}
|
||||||
- gravity: 2
|
- gravity: 2
|
||||||
color: {r: 1, g: 0.2396226, b: 0.55570096, a: 0.27450982}
|
color: {r: 1, g: 0.2396226, b: 0.55570096, a: 0.3529412}
|
||||||
- gravity: 3
|
- gravity: 3
|
||||||
color: {r: 0.25471687, g: 0.77203095, b: 1, a: 0.27450982}
|
color: {r: 0.25471687, g: 0.77203095, b: 1, a: 0.3529412}
|
||||||
- gravity: 4
|
- gravity: 4
|
||||||
color: {r: 1, g: 0.4656382, b: 0.2471698, a: 0.27450982}
|
color: {r: 1, g: 0.4656382, b: 0.2471698, a: 0.3529412}
|
||||||
_gravity: 0
|
_gravity: 0
|
||||||
--- !u!1001 &4147390443820438502
|
--- !u!1001 &4147390443820438502
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
@ -169,3 +171,158 @@ GameObject:
|
|||||||
m_CorrespondingSourceObject: {fileID: 930210402018179141, guid: 42641a1e05f4e084bae7d69b644dfd81, type: 3}
|
m_CorrespondingSourceObject: {fileID: 930210402018179141, guid: 42641a1e05f4e084bae7d69b644dfd81, type: 3}
|
||||||
m_PrefabInstance: {fileID: 4147390443820438502}
|
m_PrefabInstance: {fileID: 4147390443820438502}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
--- !u!1001 &7276724944824422886
|
||||||
|
PrefabInstance:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Modification:
|
||||||
|
serializedVersion: 3
|
||||||
|
m_TransformParent: {fileID: 5300185106086715317}
|
||||||
|
m_Modifications:
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: lengthInSec
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: ShapeModule.type
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: moveWithTransform
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.x.scalar
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.y.scalar
|
||||||
|
value: -1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.z.scalar
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: ShapeModule.m_Position.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: ShapeModule.m_Position.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: ShapeModule.m_Position.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: ShapeModule.m_Rotation.x
|
||||||
|
value: -0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: ShapeModule.radius.value
|
||||||
|
value: 1.5
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: ShapeModule.radiusThickness
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.inWorldSpace
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.radial.scalar
|
||||||
|
value: 0.2
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: InitialModule.maxNumParticles
|
||||||
|
value: 80
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.orbitalX.scalar
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.orbitalY.scalar
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.orbitalZ.scalar
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: InitialModule.startSpeed.scalar
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: EmissionModule.rateOverTime.scalar
|
||||||
|
value: 10
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: InitialModule.startLifetime.scalar
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: VelocityModule.speedModifier.scalar
|
||||||
|
value: 5
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 5747506880537754056, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_Name
|
||||||
|
value: Gravity Line Particles Sphere
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.w
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
m_RemovedComponents: []
|
||||||
|
m_RemovedGameObjects: []
|
||||||
|
m_AddedGameObjects: []
|
||||||
|
m_AddedComponents: []
|
||||||
|
m_SourcePrefab: {fileID: 100100000, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
--- !u!198 &2798249376021352391 stripped
|
||||||
|
ParticleSystem:
|
||||||
|
m_CorrespondingSourceObject: {fileID: 4767480441459301921, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
m_PrefabInstance: {fileID: 7276724944824422886}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
--- !u!4 &4274613733215928132 stripped
|
||||||
|
Transform:
|
||||||
|
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 9615c7fd8e252c145b562238bcfc1b23, type: 3}
|
||||||
|
m_PrefabInstance: {fileID: 7276724944824422886}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
|||||||
@ -206,9 +206,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &1372816401649438144
|
--- !u!1 &1372816401649438144
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -341,17 +338,13 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 0
|
Props: {fileID: 0}
|
||||||
_addedNetworkObject: {fileID: 4320456058255827552}
|
CameraOperator: {fileID: 0}
|
||||||
_networkObjectCache: {fileID: 4320456058255827552}
|
BoostEffect: {fileID: 0}
|
||||||
props: {fileID: 11400000, guid: 046eba218bb1e8946bee79bd55fd4bdd, type: 2}
|
GravityEffect: {fileID: 0}
|
||||||
boostUI: {fileID: 0}
|
JetFlameEffect: {fileID: 0}
|
||||||
cameraOperator: {fileID: 0}
|
SmokeTrailEffect: {fileID: 0}
|
||||||
boostEffect: {fileID: 7234768050496314884}
|
BodyMeshRenderer: {fileID: 0}
|
||||||
gravityEffect: {fileID: 4872706334040053047}
|
|
||||||
jetFlameEffect: {fileID: 4832079438170929303}
|
|
||||||
smokeTrailEffect: {fileID: 3500843490324877803}
|
|
||||||
fireController: {fileID: 6551228186126772357}
|
|
||||||
--- !u!114 &6551228186126772357
|
--- !u!114 &6551228186126772357
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -426,7 +419,6 @@ MonoBehaviour:
|
|||||||
<ComponentIndex>k__BackingField: 0
|
<ComponentIndex>k__BackingField: 0
|
||||||
<PredictedSpawn>k__BackingField: {fileID: 0}
|
<PredictedSpawn>k__BackingField: {fileID: 0}
|
||||||
_networkBehaviours:
|
_networkBehaviours:
|
||||||
- {fileID: 2704141135220834432}
|
|
||||||
- {fileID: 7840113418566161560}
|
- {fileID: 7840113418566161560}
|
||||||
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
||||||
<NestedRootNetworkBehaviours>k__BackingField: []
|
<NestedRootNetworkBehaviours>k__BackingField: []
|
||||||
@ -443,16 +435,21 @@ MonoBehaviour:
|
|||||||
_enablePrediction: 0
|
_enablePrediction: 0
|
||||||
_predictionType: 0
|
_predictionType: 0
|
||||||
_graphicalObject: {fileID: 0}
|
_graphicalObject: {fileID: 0}
|
||||||
|
_detachGraphicalObject: 0
|
||||||
_enableStateForwarding: 1
|
_enableStateForwarding: 1
|
||||||
_networkTransform: {fileID: 0}
|
_networkTransform: {fileID: 0}
|
||||||
_ownerInterpolation: 1
|
_ownerInterpolation: 1
|
||||||
|
_ownerSmoothedProperties: 255
|
||||||
|
_adaptiveInterpolation: 3
|
||||||
|
_spectatorSmoothedProperties: 255
|
||||||
|
_spectatorInterpolation: 2
|
||||||
_enableTeleport: 0
|
_enableTeleport: 0
|
||||||
_teleportThreshold: 1
|
_teleportThreshold: 1
|
||||||
<PrefabId>k__BackingField: 5
|
<PrefabId>k__BackingField: 9
|
||||||
<SpawnableCollectionId>k__BackingField: 0
|
<SpawnableCollectionId>k__BackingField: 0
|
||||||
_scenePathHash: 0
|
_scenePathHash: 0
|
||||||
<SceneId>k__BackingField: 0
|
<SceneId>k__BackingField: 0
|
||||||
<AssetPathHash>k__BackingField: 13364203004141276529
|
<AssetPathHash>k__BackingField: 16354951339476624532
|
||||||
--- !u!114 &7840113418566161560
|
--- !u!114 &7840113418566161560
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -465,7 +462,7 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 1
|
_componentIndexCache: 0
|
||||||
_addedNetworkObject: {fileID: 4320456058255827552}
|
_addedNetworkObject: {fileID: 4320456058255827552}
|
||||||
_networkObjectCache: {fileID: 4320456058255827552}
|
_networkObjectCache: {fileID: 4320456058255827552}
|
||||||
_componentConfiguration: 0
|
_componentConfiguration: 0
|
||||||
@ -567,9 +564,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &6980644068169889807
|
--- !u!1 &6980644068169889807
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -639,9 +633,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 0
|
tackleKind: 0
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &7841776443744888956
|
--- !u!1 &7841776443744888956
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -752,11 +743,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
||||||
--- !u!198 &4872706334040053047 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 4767480441459301921, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 123332957444049686}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &6780256004419462580 stripped
|
--- !u!4 &6780256004419462580 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
||||||
@ -835,11 +821,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
||||||
--- !u!198 &7234768050496314884 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 7931003585827073002, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 754241372986275310}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &7971143227516595385 stripped
|
--- !u!4 &7971143227516595385 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
||||||
@ -1092,11 +1073,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
||||||
m_PrefabInstance: {fileID: 2003113329371731864}
|
m_PrefabInstance: {fileID: 2003113329371731864}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &4832079438170929303 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 6395817701140918031, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 2003113329371731864}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &3400143175839768829
|
--- !u!1001 &3400143175839768829
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -1154,11 +1130,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
||||||
--- !u!198 &3500843490324877803 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 2286353817893630230, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 3400143175839768829}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &4542710706480618604 stripped
|
--- !u!4 &4542710706480618604 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
||||||
@ -182,17 +182,13 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 0
|
Props: {fileID: 0}
|
||||||
_addedNetworkObject: {fileID: 394654179909484550}
|
CameraOperator: {fileID: 0}
|
||||||
_networkObjectCache: {fileID: 394654179909484550}
|
BoostEffect: {fileID: 0}
|
||||||
props: {fileID: 11400000, guid: 8a085cd94fb766846992f4cbfd013aa7, type: 2}
|
GravityEffect: {fileID: 0}
|
||||||
boostUI: {fileID: 0}
|
JetFlameEffect: {fileID: 0}
|
||||||
cameraOperator: {fileID: 0}
|
SmokeTrailEffect: {fileID: 0}
|
||||||
boostEffect: {fileID: 7760749495303355546}
|
BodyMeshRenderer: {fileID: 0}
|
||||||
gravityEffect: {fileID: 8590080437221755141}
|
|
||||||
jetFlameEffect: {fileID: 3312185522185408775}
|
|
||||||
smokeTrailEffect: {fileID: 978131449706323191}
|
|
||||||
fireController: {fileID: 0}
|
|
||||||
--- !u!114 &394654179909484550
|
--- !u!114 &394654179909484550
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -209,7 +205,6 @@ MonoBehaviour:
|
|||||||
<ComponentIndex>k__BackingField: 0
|
<ComponentIndex>k__BackingField: 0
|
||||||
<PredictedSpawn>k__BackingField: {fileID: 0}
|
<PredictedSpawn>k__BackingField: {fileID: 0}
|
||||||
_networkBehaviours:
|
_networkBehaviours:
|
||||||
- {fileID: 2704141135220834432}
|
|
||||||
- {fileID: 8307104301583811584}
|
- {fileID: 8307104301583811584}
|
||||||
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
||||||
<NestedRootNetworkBehaviours>k__BackingField: []
|
<NestedRootNetworkBehaviours>k__BackingField: []
|
||||||
@ -226,16 +221,21 @@ MonoBehaviour:
|
|||||||
_enablePrediction: 0
|
_enablePrediction: 0
|
||||||
_predictionType: 0
|
_predictionType: 0
|
||||||
_graphicalObject: {fileID: 0}
|
_graphicalObject: {fileID: 0}
|
||||||
|
_detachGraphicalObject: 0
|
||||||
_enableStateForwarding: 1
|
_enableStateForwarding: 1
|
||||||
_networkTransform: {fileID: 0}
|
_networkTransform: {fileID: 0}
|
||||||
_ownerInterpolation: 1
|
_ownerInterpolation: 1
|
||||||
|
_ownerSmoothedProperties: 255
|
||||||
|
_adaptiveInterpolation: 3
|
||||||
|
_spectatorSmoothedProperties: 255
|
||||||
|
_spectatorInterpolation: 2
|
||||||
_enableTeleport: 0
|
_enableTeleport: 0
|
||||||
_teleportThreshold: 1
|
_teleportThreshold: 1
|
||||||
<PrefabId>k__BackingField: 11
|
<PrefabId>k__BackingField: 2
|
||||||
<SpawnableCollectionId>k__BackingField: 0
|
<SpawnableCollectionId>k__BackingField: 0
|
||||||
_scenePathHash: 0
|
_scenePathHash: 0
|
||||||
<SceneId>k__BackingField: 0
|
<SceneId>k__BackingField: 0
|
||||||
<AssetPathHash>k__BackingField: 5551583836262103703
|
<AssetPathHash>k__BackingField: 2797995355616760398
|
||||||
--- !u!114 &8307104301583811584
|
--- !u!114 &8307104301583811584
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -248,7 +248,7 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 1
|
_componentIndexCache: 0
|
||||||
_addedNetworkObject: {fileID: 394654179909484550}
|
_addedNetworkObject: {fileID: 394654179909484550}
|
||||||
_networkObjectCache: {fileID: 394654179909484550}
|
_networkObjectCache: {fileID: 394654179909484550}
|
||||||
_componentConfiguration: 0
|
_componentConfiguration: 0
|
||||||
@ -403,9 +403,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &7931096401578265872
|
--- !u!1 &7931096401578265872
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -475,9 +472,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &8148123273009086921
|
--- !u!1 &8148123273009086921
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -547,9 +541,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 0
|
tackleKind: 0
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &9047713688665039503
|
--- !u!1 &9047713688665039503
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -665,11 +656,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
||||||
m_PrefabInstance: {fileID: 406218082282592112}
|
m_PrefabInstance: {fileID: 406218082282592112}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &7760749495303355546 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 7931003585827073002, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 406218082282592112}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &1308797000485596641
|
--- !u!1001 &1308797000485596641
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -732,11 +718,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
||||||
m_PrefabInstance: {fileID: 1308797000485596641}
|
m_PrefabInstance: {fileID: 1308797000485596641}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &978131449706323191 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 2286353817893630230, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 1308797000485596641}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &1578594390765257941
|
--- !u!1001 &1578594390765257941
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -909,11 +890,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
||||||
m_PrefabInstance: {fileID: 3827891006853830436}
|
m_PrefabInstance: {fileID: 3827891006853830436}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &8590080437221755141 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 4767480441459301921, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 3827891006853830436}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &8445865029439684104
|
--- !u!1001 &8445865029439684104
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -1335,11 +1311,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
||||||
--- !u!198 &3312185522185408775 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 6395817701140918031, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 8445865029439684104}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &4918238313528133406 stripped
|
--- !u!4 &4918238313528133406 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
||||||
@ -182,17 +182,13 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 0
|
Props: {fileID: 0}
|
||||||
_addedNetworkObject: {fileID: 394654179909484550}
|
CameraOperator: {fileID: 0}
|
||||||
_networkObjectCache: {fileID: 394654179909484550}
|
BoostEffect: {fileID: 0}
|
||||||
props: {fileID: 11400000, guid: 38b05003293b5c24abcb9b8491dd5c45, type: 2}
|
GravityEffect: {fileID: 0}
|
||||||
boostUI: {fileID: 0}
|
JetFlameEffect: {fileID: 0}
|
||||||
cameraOperator: {fileID: 0}
|
SmokeTrailEffect: {fileID: 0}
|
||||||
boostEffect: {fileID: 7760749495303355546}
|
BodyMeshRenderer: {fileID: 0}
|
||||||
gravityEffect: {fileID: 2930093712651127642}
|
|
||||||
jetFlameEffect: {fileID: 3312185522185408775}
|
|
||||||
smokeTrailEffect: {fileID: 978131449706323191}
|
|
||||||
fireController: {fileID: 0}
|
|
||||||
--- !u!114 &394654179909484550
|
--- !u!114 &394654179909484550
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -209,7 +205,6 @@ MonoBehaviour:
|
|||||||
<ComponentIndex>k__BackingField: 0
|
<ComponentIndex>k__BackingField: 0
|
||||||
<PredictedSpawn>k__BackingField: {fileID: 0}
|
<PredictedSpawn>k__BackingField: {fileID: 0}
|
||||||
_networkBehaviours:
|
_networkBehaviours:
|
||||||
- {fileID: 2704141135220834432}
|
|
||||||
- {fileID: 8307104301583811584}
|
- {fileID: 8307104301583811584}
|
||||||
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
||||||
<NestedRootNetworkBehaviours>k__BackingField: []
|
<NestedRootNetworkBehaviours>k__BackingField: []
|
||||||
@ -226,16 +221,21 @@ MonoBehaviour:
|
|||||||
_enablePrediction: 0
|
_enablePrediction: 0
|
||||||
_predictionType: 0
|
_predictionType: 0
|
||||||
_graphicalObject: {fileID: 0}
|
_graphicalObject: {fileID: 0}
|
||||||
|
_detachGraphicalObject: 0
|
||||||
_enableStateForwarding: 1
|
_enableStateForwarding: 1
|
||||||
_networkTransform: {fileID: 0}
|
_networkTransform: {fileID: 0}
|
||||||
_ownerInterpolation: 1
|
_ownerInterpolation: 1
|
||||||
|
_ownerSmoothedProperties: 255
|
||||||
|
_adaptiveInterpolation: 3
|
||||||
|
_spectatorSmoothedProperties: 255
|
||||||
|
_spectatorInterpolation: 2
|
||||||
_enableTeleport: 0
|
_enableTeleport: 0
|
||||||
_teleportThreshold: 1
|
_teleportThreshold: 1
|
||||||
<PrefabId>k__BackingField: 9
|
<PrefabId>k__BackingField: 6
|
||||||
<SpawnableCollectionId>k__BackingField: 0
|
<SpawnableCollectionId>k__BackingField: 0
|
||||||
_scenePathHash: 0
|
_scenePathHash: 0
|
||||||
<SceneId>k__BackingField: 0
|
<SceneId>k__BackingField: 0
|
||||||
<AssetPathHash>k__BackingField: 10015891062238479949
|
<AssetPathHash>k__BackingField: 6698779595108695616
|
||||||
--- !u!114 &8307104301583811584
|
--- !u!114 &8307104301583811584
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -248,7 +248,7 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 1
|
_componentIndexCache: 0
|
||||||
_addedNetworkObject: {fileID: 394654179909484550}
|
_addedNetworkObject: {fileID: 394654179909484550}
|
||||||
_networkObjectCache: {fileID: 394654179909484550}
|
_networkObjectCache: {fileID: 394654179909484550}
|
||||||
_componentConfiguration: 0
|
_componentConfiguration: 0
|
||||||
@ -403,9 +403,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &7931096401578265872
|
--- !u!1 &7931096401578265872
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -475,9 +472,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &8148123273009086921
|
--- !u!1 &8148123273009086921
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -547,9 +541,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 0
|
tackleKind: 0
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &9047713688665039503
|
--- !u!1 &9047713688665039503
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -665,11 +656,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
||||||
m_PrefabInstance: {fileID: 406218082282592112}
|
m_PrefabInstance: {fileID: 406218082282592112}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &7760749495303355546 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 7931003585827073002, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 406218082282592112}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &1308797000485596641
|
--- !u!1001 &1308797000485596641
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -732,11 +718,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
||||||
m_PrefabInstance: {fileID: 1308797000485596641}
|
m_PrefabInstance: {fileID: 1308797000485596641}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &978131449706323191 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 2286353817893630230, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 1308797000485596641}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &1578594390765257941
|
--- !u!1001 &1578594390765257941
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -904,11 +885,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
||||||
--- !u!198 &2930093712651127642 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 4767480441459301921, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 7674334455437251963}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &3832232075009489881 stripped
|
--- !u!4 &3832232075009489881 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
||||||
@ -1335,11 +1311,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
||||||
--- !u!198 &3312185522185408775 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 6395817701140918031, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 8445865029439684104}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &4918238313528133406 stripped
|
--- !u!4 &4918238313528133406 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
||||||
@ -182,17 +182,13 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
m_Script: {fileID: 11500000, guid: 2b6244fd2a6ceee4ab8504fadf75ae20, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 0
|
Props: {fileID: 0}
|
||||||
_addedNetworkObject: {fileID: 394654179909484550}
|
CameraOperator: {fileID: 0}
|
||||||
_networkObjectCache: {fileID: 394654179909484550}
|
BoostEffect: {fileID: 0}
|
||||||
props: {fileID: 11400000, guid: 04ffb42925f036949866663c0311ac6b, type: 2}
|
GravityEffect: {fileID: 0}
|
||||||
boostUI: {fileID: 0}
|
JetFlameEffect: {fileID: 0}
|
||||||
cameraOperator: {fileID: 0}
|
SmokeTrailEffect: {fileID: 0}
|
||||||
boostEffect: {fileID: 7760749495303355546}
|
BodyMeshRenderer: {fileID: 0}
|
||||||
gravityEffect: {fileID: 5356225948148490788}
|
|
||||||
jetFlameEffect: {fileID: 3312185522185408775}
|
|
||||||
smokeTrailEffect: {fileID: 978131449706323191}
|
|
||||||
fireController: {fileID: 0}
|
|
||||||
--- !u!114 &394654179909484550
|
--- !u!114 &394654179909484550
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -209,7 +205,6 @@ MonoBehaviour:
|
|||||||
<ComponentIndex>k__BackingField: 0
|
<ComponentIndex>k__BackingField: 0
|
||||||
<PredictedSpawn>k__BackingField: {fileID: 0}
|
<PredictedSpawn>k__BackingField: {fileID: 0}
|
||||||
_networkBehaviours:
|
_networkBehaviours:
|
||||||
- {fileID: 2704141135220834432}
|
|
||||||
- {fileID: 8307104301583811584}
|
- {fileID: 8307104301583811584}
|
||||||
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
<SerializedRootNetworkBehaviour>k__BackingField: {fileID: 0}
|
||||||
<NestedRootNetworkBehaviours>k__BackingField: []
|
<NestedRootNetworkBehaviours>k__BackingField: []
|
||||||
@ -226,16 +221,21 @@ MonoBehaviour:
|
|||||||
_enablePrediction: 0
|
_enablePrediction: 0
|
||||||
_predictionType: 0
|
_predictionType: 0
|
||||||
_graphicalObject: {fileID: 0}
|
_graphicalObject: {fileID: 0}
|
||||||
|
_detachGraphicalObject: 0
|
||||||
_enableStateForwarding: 1
|
_enableStateForwarding: 1
|
||||||
_networkTransform: {fileID: 0}
|
_networkTransform: {fileID: 0}
|
||||||
_ownerInterpolation: 1
|
_ownerInterpolation: 1
|
||||||
|
_ownerSmoothedProperties: 255
|
||||||
|
_adaptiveInterpolation: 3
|
||||||
|
_spectatorSmoothedProperties: 255
|
||||||
|
_spectatorInterpolation: 2
|
||||||
_enableTeleport: 0
|
_enableTeleport: 0
|
||||||
_teleportThreshold: 1
|
_teleportThreshold: 1
|
||||||
<PrefabId>k__BackingField: 1
|
<PrefabId>k__BackingField: 3
|
||||||
<SpawnableCollectionId>k__BackingField: 0
|
<SpawnableCollectionId>k__BackingField: 0
|
||||||
_scenePathHash: 0
|
_scenePathHash: 0
|
||||||
<SceneId>k__BackingField: 0
|
<SceneId>k__BackingField: 0
|
||||||
<AssetPathHash>k__BackingField: 5851826624730448275
|
<AssetPathHash>k__BackingField: 12197567711296960114
|
||||||
--- !u!114 &8307104301583811584
|
--- !u!114 &8307104301583811584
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -248,7 +248,7 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
m_Script: {fileID: 11500000, guid: a2836e36774ca1c4bbbee976e17b649c, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
_componentIndexCache: 1
|
_componentIndexCache: 0
|
||||||
_addedNetworkObject: {fileID: 394654179909484550}
|
_addedNetworkObject: {fileID: 394654179909484550}
|
||||||
_networkObjectCache: {fileID: 394654179909484550}
|
_networkObjectCache: {fileID: 394654179909484550}
|
||||||
_componentConfiguration: 0
|
_componentConfiguration: 0
|
||||||
@ -403,9 +403,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &7931096401578265872
|
--- !u!1 &7931096401578265872
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -475,9 +472,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 1
|
tackleKind: 1
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &8148123273009086921
|
--- !u!1 &8148123273009086921
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -547,9 +541,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
tackleKind: 0
|
tackleKind: 0
|
||||||
TackleResponse:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
--- !u!1 &9047713688665039503
|
--- !u!1 &9047713688665039503
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -665,11 +656,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
m_CorrespondingSourceObject: {fileID: 7271248515473135959, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
||||||
m_PrefabInstance: {fileID: 406218082282592112}
|
m_PrefabInstance: {fileID: 406218082282592112}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &7760749495303355546 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 7931003585827073002, guid: 24a81306cc1fbbd4b8f10022e2d6ee0d, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 406218082282592112}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &611466096646765573
|
--- !u!1001 &611466096646765573
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -731,11 +717,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
||||||
--- !u!198 &5356225948148490788 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 4767480441459301921, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 611466096646765573}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &6328183573752812199 stripped
|
--- !u!4 &6328183573752812199 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
m_CorrespondingSourceObject: {fileID: 6894558316197621410, guid: 5075d8b26bc537c439b56964f382020e, type: 3}
|
||||||
@ -803,11 +784,6 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
m_CorrespondingSourceObject: {fileID: 1163423376577002641, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
||||||
m_PrefabInstance: {fileID: 1308797000485596641}
|
m_PrefabInstance: {fileID: 1308797000485596641}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!198 &978131449706323191 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 2286353817893630230, guid: 98bf6d3624da8d54fbe33787e003ef60, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 1308797000485596641}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &1578594390765257941
|
--- !u!1001 &1578594390765257941
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -1335,11 +1311,6 @@ PrefabInstance:
|
|||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
||||||
--- !u!198 &3312185522185408775 stripped
|
|
||||||
ParticleSystem:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 6395817701140918031, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 8445865029439684104}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!4 &4918238313528133406 stripped
|
--- !u!4 &4918238313528133406 stripped
|
||||||
Transform:
|
Transform:
|
||||||
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
m_CorrespondingSourceObject: {fileID: 3563661011899316502, guid: a85c082f5fc6ca4428f78f385e6b42a9, type: 3}
|
||||||
@ -76,7 +76,6 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 456d6ebbd09c16d488cbe8451ae0e5f6, type: 3}
|
m_Script: {fileID: 11500000, guid: 456d6ebbd09c16d488cbe8451ae0e5f6, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
forcesManager: {fileID: 0}
|
|
||||||
renderedZoneObject: {fileID: 5479003418548602625}
|
renderedZoneObject: {fileID: 5479003418548602625}
|
||||||
NimbleZoneColors:
|
NimbleZoneColors:
|
||||||
- gravity: 0
|
- gravity: 0
|
||||||
@ -84,11 +83,11 @@ MonoBehaviour:
|
|||||||
- gravity: 1
|
- gravity: 1
|
||||||
color: {r: 0.81708485, g: 0.20943397, b: 1, a: 0.27450982}
|
color: {r: 0.81708485, g: 0.20943397, b: 1, a: 0.27450982}
|
||||||
- gravity: 2
|
- gravity: 2
|
||||||
color: {r: 1, g: 0.2396226, b: 0.55570096, a: 0.27450982}
|
color: {r: 1, g: 0.2396226, b: 0.55570096, a: 0.54901963}
|
||||||
- gravity: 3
|
- gravity: 3
|
||||||
color: {r: 0.25471687, g: 0.77203095, b: 1, a: 0.27450982}
|
color: {r: 0.25471687, g: 0.77203095, b: 1, a: 0.54901963}
|
||||||
- gravity: 4
|
- gravity: 4
|
||||||
color: {r: 1, g: 0.4656382, b: 0.2471698, a: 0.27450982}
|
color: {r: 1, g: 0.4656382, b: 0.2471698, a: 0.54901963}
|
||||||
outsideGravityFunction: 0
|
outsideGravityFunction: 0
|
||||||
zone: 0
|
zone: 0
|
||||||
rippleFrequency: 12
|
rippleFrequency: 12
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -1020,6 +1020,10 @@ PrefabInstance:
|
|||||||
serializedVersion: 3
|
serializedVersion: 3
|
||||||
m_TransformParent: {fileID: 592057803}
|
m_TransformParent: {fileID: 592057803}
|
||||||
m_Modifications:
|
m_Modifications:
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.y.scalar
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: m_Name
|
propertyPath: m_Name
|
||||||
value: Gravity Changer (1)
|
value: Gravity Changer (1)
|
||||||
@ -1069,7 +1073,7 @@ PrefabInstance:
|
|||||||
value: 1
|
value: 1
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: forcesManager
|
propertyPath: ForcesManager
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 1659830376}
|
objectReference: {fileID: 1659830376}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
@ -1495,6 +1499,18 @@ PrefabInstance:
|
|||||||
serializedVersion: 3
|
serializedVersion: 3
|
||||||
m_TransformParent: {fileID: 592057803}
|
m_TransformParent: {fileID: 592057803}
|
||||||
m_Modifications:
|
m_Modifications:
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.y.scalar
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: InitialModule.startSpeed.scalar
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.speedModifier.scalar
|
||||||
|
value: 2
|
||||||
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: m_Name
|
propertyPath: m_Name
|
||||||
value: Gravity Changer (4)
|
value: Gravity Changer (4)
|
||||||
@ -1541,10 +1557,10 @@ PrefabInstance:
|
|||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: _gravity
|
propertyPath: _gravity
|
||||||
value: 2
|
value: 4
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: forcesManager
|
propertyPath: ForcesManager
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 1659830376}
|
objectReference: {fileID: 1659830376}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
@ -4775,7 +4791,7 @@ PrefabInstance:
|
|||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: forcesManager
|
propertyPath: ForcesManager
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 1659830376}
|
objectReference: {fileID: 1659830376}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
@ -5592,6 +5608,18 @@ PrefabInstance:
|
|||||||
serializedVersion: 3
|
serializedVersion: 3
|
||||||
m_TransformParent: {fileID: 592057803}
|
m_TransformParent: {fileID: 592057803}
|
||||||
m_Modifications:
|
m_Modifications:
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.y.scalar
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: InitialModule.startSpeed.scalar
|
||||||
|
value: -1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.speedModifier.scalar
|
||||||
|
value: 2
|
||||||
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: m_Name
|
propertyPath: m_Name
|
||||||
value: Gravity Changer (3)
|
value: Gravity Changer (3)
|
||||||
@ -5638,10 +5666,10 @@ PrefabInstance:
|
|||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: _gravity
|
propertyPath: _gravity
|
||||||
value: 4
|
value: 3
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: forcesManager
|
propertyPath: ForcesManager
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 1659830376}
|
objectReference: {fileID: 1659830376}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
@ -5732,6 +5760,38 @@ PrefabInstance:
|
|||||||
serializedVersion: 3
|
serializedVersion: 3
|
||||||
m_TransformParent: {fileID: 592057803}
|
m_TransformParent: {fileID: 592057803}
|
||||||
m_Modifications:
|
m_Modifications:
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.y.scalar
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.orbitalX.scalar
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.orbitalY.scalar
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.orbitalZ.scalar
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: InitialModule.startSpeed.scalar
|
||||||
|
value: 0.1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: EmissionModule.rateOverTime.scalar
|
||||||
|
value: 5
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: InitialModule.startLifetime.scalar
|
||||||
|
value: 8
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2798249376021352391, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
|
propertyPath: VelocityModule.speedModifier.scalar
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 3680835022977216242, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: m_Name
|
propertyPath: m_Name
|
||||||
value: Gravity Changer (2)
|
value: Gravity Changer (2)
|
||||||
@ -5778,10 +5838,10 @@ PrefabInstance:
|
|||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: _gravity
|
propertyPath: _gravity
|
||||||
value: 3
|
value: 2
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
- target: {fileID: 6433935702469069213, guid: 6926b3895381aea48b807d579c1ce6a0, type: 3}
|
||||||
propertyPath: forcesManager
|
propertyPath: ForcesManager
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 1659830376}
|
objectReference: {fileID: 1659830376}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
|
|||||||
@ -12,51 +12,53 @@ public class BaseShipProperties : ScriptableObject
|
|||||||
{
|
{
|
||||||
[Header("Basic Movement")]
|
[Header("Basic Movement")]
|
||||||
[Tooltip("The acceleration applied on thrust input.")]
|
[Tooltip("The acceleration applied on thrust input.")]
|
||||||
public float thrustAcceleration = 2000;
|
public float ThrustAcceleration = 2000;
|
||||||
[Tooltip("The velocity with which the character can rotate around it's center.")]
|
[Tooltip("The velocity with which the character can rotate around it's center.")]
|
||||||
public float steerVelocity = 360;
|
public float SteerVelocity = 360;
|
||||||
[Header("Max Velocity & Drag")]
|
[Header("Max Velocity & Drag")]
|
||||||
[Tooltip("The standard limit of character velocity.")]
|
[Tooltip("The standard limit of character velocity.")]
|
||||||
public float normalMaxVelocity = 15f;
|
public float NormalMaxVelocity = 15f;
|
||||||
[Tooltip("The absolute maximum of character velocity (enforced by drag).")]
|
[Tooltip("The absolute maximum of character velocity (enforced by drag).")]
|
||||||
public float absolutMaxVelocity = 25f;
|
public float AbsolutMaxVelocity = 25f;
|
||||||
[Tooltip("The drag which acts opposite to the characters movement direction normally.")]
|
[Tooltip("The drag which acts opposite to the characters movement direction normally.")]
|
||||||
public float normalDrag = 5f;
|
public float NormalDrag = 5f;
|
||||||
[Tooltip("The maximum drag which can act opposite to the characters movement direction.")]
|
[Tooltip("The maximum drag which can act opposite to the characters movement direction.")]
|
||||||
public float maximumDrag = 10f;
|
public float MaximumDrag = 10f;
|
||||||
[Tooltip("The drag which acts opposite to the characters rotation direction normally.")]
|
[Tooltip("The drag which acts opposite to the characters rotation direction normally.")]
|
||||||
public float torqueDrag = 0.2f;
|
public float TorqueDrag = 0.2f;
|
||||||
|
[Header("Gravity Strength")]
|
||||||
|
public float GravityStrength = 30f;
|
||||||
[Header("Anti-Drift")]
|
[Header("Anti-Drift")]
|
||||||
[Tooltip("The amount to which the drift of the character is reduced when anti-drift is active.")]
|
[Tooltip("The amount to which the drift of the character is reduced when anti-drift is active.")]
|
||||||
public float antiDriftAmount = 12;
|
public float AntiDriftAmount = 12;
|
||||||
[Tooltip("The amount to which the drift of the character is always reduced.")]
|
[Tooltip("The amount to which the drift of the character is always reduced.")]
|
||||||
public float minAntiDriftFactor = 0.03f;
|
public float MinAntiDriftFactor = 0.03f;
|
||||||
[Header("Boost")]
|
[Header("Boost")]
|
||||||
[Tooltip("The time which is used up when a player uses boost.")]
|
[Tooltip("The time which is used up when a player uses boost.")]
|
||||||
public float maxBoostCapacity = 3.3f;
|
public float MaxBoostCapacity = 3.3f;
|
||||||
[Tooltip("The point at which a player can boost again when boost is reloading.")]
|
[Tooltip("The point at which a player can boost again when boost is reloading.")]
|
||||||
public float minBoostCapacity = 0.15f;
|
public float MinBoostCapacity = 0.15f;
|
||||||
[Tooltip("The factor with which the thrust is multiplied while boosting.")]
|
[Tooltip("The factor with which the thrust is multiplied while boosting.")]
|
||||||
public float boostMagnitude = 1.5f;
|
public float BoostMagnitude = 1.5f;
|
||||||
[Tooltip("The flat tax on the boost when outside of a recharging zone (capacity -= rate * time in seconds).")]
|
[Tooltip("The flat tax on the boost when outside of a recharging zone (capacity -= rate * time in seconds).")]
|
||||||
public float outsideBoostRate = 0.0f;
|
public float OutsideBoostRate = 0.0f;
|
||||||
[Tooltip("The factor of gravity which is eliminated by boosting (1 = no gravity).")]
|
[Tooltip("The factor of gravity which is eliminated by boosting (1 = no gravity).")]
|
||||||
public float boostAntiGravityFactor = 0.33f;
|
public float BoostAntiGravityFactor = 0.33f;
|
||||||
[Header("Stun & Tackle")]
|
[Header("Stun & Tackle")]
|
||||||
[Tooltip("The factor by which the player looses control over the character when being stunned (0 = no control).")]
|
[Tooltip("The factor by which the player looses control over the character when being stunned (0 = no control).")]
|
||||||
public float stunLooseControlFactor = 0.1f;
|
public float StunLooseControlFactor = 0.1f;
|
||||||
[Tooltip("Time until the tackling player can be tackled again")]
|
[Tooltip("Time until the tackling player can be tackled again")]
|
||||||
public float tacklingGraceTime = 0.6f;
|
public float TacklingGraceTime = 0.6f;
|
||||||
[Tooltip("Time until the tackled player can be tackled again")]
|
[Tooltip("Time until the tackled player can be tackled again")]
|
||||||
public float tackledGraceTime = 0.6f;
|
public float TackledGraceTime = 0.6f;
|
||||||
[Tooltip("The time it takes for a critically stunned character to be controlable again.")]
|
[Tooltip("The time it takes for a critically stunned character to be controlable again.")]
|
||||||
public float tackledCriticalStunTime = 0.6f;
|
public float TackledCriticalStunTime = 0.6f;
|
||||||
[Tooltip("The time it takes for a normally stunned character to be controlable again.")]
|
[Tooltip("The time it takes for a normally stunned character to be controlable again.")]
|
||||||
public float tackledBodyStunTime = 0.3f;
|
public float TackledBodyStunTime = 0.3f;
|
||||||
[Tooltip("The power with which the character is tackled away, when hit critically.")]
|
[Tooltip("The power with which the character is tackled away, when hit critically.")]
|
||||||
public float criticalTacklePowerFactor = 60f;
|
public float CriticalTacklePowerFactor = 60f;
|
||||||
[Tooltip("The power with which the character is tackled away, when hit normally.")]
|
[Tooltip("The power with which the character is tackled away, when hit normally.")]
|
||||||
public float normalTacklePowerFactor = 40f;
|
public float NormalTacklePowerFactor = 40f;
|
||||||
[Header("Ship sounds")]
|
[Header("Ship sounds")]
|
||||||
public ShipAudio audio;
|
public ShipAudio Audio;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -9,174 +9,159 @@ using UnityEngine;
|
|||||||
public class ShipProperties : ScriptableObject
|
public class ShipProperties : ScriptableObject
|
||||||
{
|
{
|
||||||
[Tooltip("The base properties for all ships.")]
|
[Tooltip("The base properties for all ships.")]
|
||||||
public BaseShipProperties baseProps;
|
public BaseShipProperties BaseProps;
|
||||||
[Tooltip("Prefab which contains the whole ship gameobject.")]
|
[Tooltip("Prefab which contains the whole ship gameobject.")]
|
||||||
public GameObject shipPrefab = null;
|
public GameObject ShipPrefab = null;
|
||||||
[Tooltip("Object which relays the user input to the ships state.")]
|
[Tooltip("Object which relays the user input to the ships state.")]
|
||||||
public ShipInputHandler shipInput = null;
|
public ShipInputHandler ShipInput = null;
|
||||||
[Tooltip("Name of the ship (relevant to UI and lore context).")]
|
[Tooltip("Name of the ship (relevant to UI and lore context).")]
|
||||||
public string shipName = "SpaceyMcShipface";
|
public string ShipName = "SpaceyMcShipface";
|
||||||
[Tooltip("The main color of the ship.")]
|
[Tooltip("The main color of the ship.")]
|
||||||
public Color shipHullColor = Color.magenta;
|
public Color ShipHullColor = Color.magenta;
|
||||||
|
|
||||||
[Tooltip("The acceleration applied on thrust input.")]
|
[Tooltip("The acceleration applied on thrust input.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float thrustAccelerationModifier = 1;
|
public float thrustAccelerationModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float thrustAcceleration
|
public float ThrustAcceleration => BaseProps.ThrustAcceleration * thrustAccelerationModifier;
|
||||||
{ get => baseProps.thrustAcceleration * thrustAccelerationModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The velocity with which the character can rotate around it's center.")]
|
[Tooltip("The velocity with which the character can rotate around it's center.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float steerVelocityModifier = 1;
|
public float steerVelocityModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float steerVelocity
|
public float SteerVelocity => BaseProps.SteerVelocity * steerVelocityModifier;
|
||||||
{ get => baseProps.steerVelocity * steerVelocityModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The standard limit of character velocity.")]
|
[Tooltip("The standard limit of character velocity.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float normalMaxVelocityModifier = 1;
|
public float normalMaxVelocityModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float normalMaxVelocity
|
public float NormalMaxVelocity => BaseProps.NormalMaxVelocity * normalMaxVelocityModifier;
|
||||||
{ get => baseProps.normalMaxVelocity * normalMaxVelocityModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The absolute maximum of character velocity (enforced by drag).")]
|
[Tooltip("The absolute maximum of character velocity (enforced by drag).")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float absolutMaxVelocityModifier = 1;
|
public float absolutMaxVelocityModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float absolutMaxVelocity
|
public float AbsolutMaxVelocity => BaseProps.AbsolutMaxVelocity * absolutMaxVelocityModifier;
|
||||||
{ get => baseProps.absolutMaxVelocity * absolutMaxVelocityModifier; }
|
|
||||||
|
[Tooltip("The strength of gravity acting on a character.")]
|
||||||
|
[Range(0.0f, 10.0f)]
|
||||||
|
public float gravityStrengthModifier = 1;
|
||||||
|
[HideInInspector]
|
||||||
|
public float GravitStrength => BaseProps.GravityStrength * gravityStrengthModifier;
|
||||||
|
|
||||||
[Tooltip("The amount to which the drift of the character is reduced when anti-drift is active.")]
|
[Tooltip("The amount to which the drift of the character is reduced when anti-drift is active.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float antiDriftAmountModifier = 1;
|
public float antiDriftAmountModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float antiDriftAmount
|
public float AntiDriftAmount => BaseProps.AntiDriftAmount * antiDriftAmountModifier;
|
||||||
{ get => baseProps.antiDriftAmount * antiDriftAmountModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The amount to which the drift of the character is always reduced.")]
|
[Tooltip("The amount to which the drift of the character is always reduced.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float minAntiDriftFactorModifier = 1;
|
public float minAntiDriftFactorModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float minAntiDriftFactor
|
public float MinAntiDriftFactor => BaseProps.MinAntiDriftFactor * minAntiDriftFactorModifier;
|
||||||
{ get => baseProps.minAntiDriftFactor * minAntiDriftFactorModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The drag which acts opposite to the characters movement direction normally.")]
|
[Tooltip("The drag which acts opposite to the characters movement direction normally.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float normalDragModifier = 1;
|
public float normalDragModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float normalDrag
|
public float NormalDrag => BaseProps.NormalDrag * normalDragModifier;
|
||||||
{ get => baseProps.normalDrag * normalDragModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The maximum drag which can act opposite to the characters movement direction.")]
|
[Tooltip("The maximum drag which can act opposite to the characters movement direction.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float maximumDragModifier = 1;
|
public float maximumDragModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float maximumDrag
|
public float MaximumDrag => BaseProps.MaximumDrag * maximumDragModifier;
|
||||||
{ get => baseProps.maximumDrag * maximumDragModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The drag which acts opposite to the characters rotation direction normally.")]
|
[Tooltip("The drag which acts opposite to the characters rotation direction normally.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float torqueDragModifier = 1;
|
public float torqueDragModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float torqueDrag
|
public float TorqueDrag => BaseProps.TorqueDrag * torqueDragModifier;
|
||||||
{ get => baseProps.torqueDrag * torqueDragModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The time which is used up when a player uses boost.")]
|
[Tooltip("The time which is used up when a player uses boost.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float maxBoostCapacityModifier = 1;
|
public float maxBoostCapacityModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float maxBoostCapacity
|
public float MaxBoostCapacity => BaseProps.MaxBoostCapacity * maxBoostCapacityModifier;
|
||||||
{ get => baseProps.maxBoostCapacity * maxBoostCapacityModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The point at which a player can boost again when boost is reloading.")]
|
[Tooltip("The point at which a player can boost again when boost is reloading.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float minBoostCapacityModifier = 1;
|
public float minBoostCapacityModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float minBoostCapacity
|
public float MinBoostCapacity => BaseProps.MinBoostCapacity * minBoostCapacityModifier;
|
||||||
{ get => baseProps.minBoostCapacity * minBoostCapacityModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The factor with which the thrust is multiplied while boosting.")]
|
[Tooltip("The factor with which the thrust is multiplied while boosting.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float boostMagnitudeModifier = 1;
|
public float boostMagnitudeModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float boostMagnitude
|
public float BoostMagnitude => BaseProps.BoostMagnitude * boostMagnitudeModifier;
|
||||||
{ get => baseProps.boostMagnitude * boostMagnitudeModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The flat tax on the boost when outside of a recharging zone (capacity -= rate * time in seconds).")]
|
[Tooltip("The flat tax on the boost when outside of a recharging zone (capacity -= rate * time in seconds).")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float outsideBoostRateModifier = 1;
|
public float outsideBoostRateModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float outsideBoostRate
|
public float OutsideBoostRate => BaseProps.OutsideBoostRate * outsideBoostRateModifier;
|
||||||
{ get => baseProps.outsideBoostRate * outsideBoostRateModifier; }
|
|
||||||
|
|
||||||
|
|
||||||
[Tooltip("The factor of gravity which is eliminated by boosting (1 = no gravity).")]
|
[Tooltip("The factor of gravity which is eliminated by boosting (1 = no gravity).")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float boostAntiGravityFactorModifier = 1;
|
public float boostAntiGravityFactorModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float boostAntiGravityFactor
|
public float BoostAntiGravityFactor => BaseProps.BoostAntiGravityFactor * boostAntiGravityFactorModifier;
|
||||||
{ get => baseProps.boostAntiGravityFactor * boostAntiGravityFactorModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The factor by which the player looses control over the character when being stunned (0 = no control).")]
|
[Tooltip("The factor by which the player looses control over the character when being stunned (0 = no control).")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float stunLooseControlFactorModifier = 1;
|
public float stunLooseControlFactorModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float stunLooseControlFactor
|
public float StunLooseControlFactor => BaseProps.StunLooseControlFactor * stunLooseControlFactorModifier;
|
||||||
{ get => baseProps.stunLooseControlFactor * stunLooseControlFactorModifier; }
|
|
||||||
|
|
||||||
[Tooltip("Time until the tackling player can be tackled again")]
|
[Tooltip("Time until the tackling player can be tackled again")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float tacklingGraceTimeModifier = 1;
|
public float tacklingGraceTimeModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float tacklingGraceTime
|
public float TacklingGraceTime => BaseProps.TacklingGraceTime * tacklingGraceTimeModifier;
|
||||||
{ get => baseProps.tacklingGraceTime * tacklingGraceTimeModifier; }
|
|
||||||
[Tooltip("Time until the tackled player can be tackled again")]
|
[Tooltip("Time until the tackled player can be tackled again")]
|
||||||
|
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float tackledGraceTimeModifier = 1;
|
public float tackledGraceTimeModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float tackledGraceTime
|
public float TackledGraceTime => BaseProps.TackledGraceTime * tackledGraceTimeModifier;
|
||||||
{ get => baseProps.tackledGraceTime * tackledGraceTimeModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The time it takes for a critically stunned character to be controlable again.")]
|
[Tooltip("The time it takes for a critically stunned character to be controlable again.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float tackleCriticalStunTimeModifier = 1;
|
public float tackleCriticalStunTimeModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float tackledCriticalStunTime
|
public float TackledCriticalStunTime => BaseProps.TackledCriticalStunTime * tackleCriticalStunTimeModifier;
|
||||||
{ get => baseProps.tackledCriticalStunTime * tackleCriticalStunTimeModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The time it takes for a normally stunned character to be controlable again.")]
|
[Tooltip("The time it takes for a normally stunned character to be controlable again.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float tackleBodyStunTimeModifier = 1;
|
public float tackleBodyStunTimeModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float tackledBodyStunTime
|
public float TackledBodyStunTime => BaseProps.TackledBodyStunTime * tackleBodyStunTimeModifier;
|
||||||
{ get => baseProps.tackledBodyStunTime * tackleBodyStunTimeModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The power with which the character is tackled away, when hit critically.")]
|
[Tooltip("The power with which the character is tackled away, when hit critically.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float criticalTacklePowerFactorModifier = 1;
|
public float criticalTacklePowerFactorModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float criticalTacklePowerFactor
|
public float CriticalTacklePowerFactor => BaseProps.CriticalTacklePowerFactor * criticalTacklePowerFactorModifier;
|
||||||
{ get => baseProps.criticalTacklePowerFactor * criticalTacklePowerFactorModifier; }
|
|
||||||
|
|
||||||
[Tooltip("The power with which the character is tackled away, when hit normally.")]
|
[Tooltip("The power with which the character is tackled away, when hit normally.")]
|
||||||
[Range(0.0f, 10.0f)]
|
[Range(0.0f, 10.0f)]
|
||||||
public float normalTacklePowerFactorModifier = 1;
|
public float normalTacklePowerFactorModifier = 1;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public float normalTacklePowerFactor
|
public float NormalTacklePowerFactor => BaseProps.NormalTacklePowerFactor * normalTacklePowerFactorModifier;
|
||||||
{ get => baseProps.normalTacklePowerFactor * normalTacklePowerFactorModifier; }
|
|
||||||
|
|
||||||
[Tooltip("Overwrite the default ship sounds or leave empty")]
|
[Tooltip("Overwrite the default ship sounds or leave empty")]
|
||||||
public ShipAudio alternativeShipSounds;
|
public ShipAudio alternativeShipSounds;
|
||||||
[HideInInspector]
|
[HideInInspector]
|
||||||
public ShipAudio audio
|
public ShipAudio Audio
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
if (alternativeShipSounds == null)
|
if (alternativeShipSounds == null)
|
||||||
{
|
{
|
||||||
return baseProps.audio;
|
return BaseProps.Audio;
|
||||||
}
|
}
|
||||||
return alternativeShipSounds;
|
return alternativeShipSounds;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -12,25 +12,26 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: d4e63b7217e6a2f499d6da3911f6da33, type: 3}
|
m_Script: {fileID: 11500000, guid: d4e63b7217e6a2f499d6da3911f6da33, type: 3}
|
||||||
m_Name: BaseShip
|
m_Name: BaseShip
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
thrustAcceleration: 1300
|
ThrustAcceleration: 2000
|
||||||
steerVelocity: 360
|
SteerVelocity: 360
|
||||||
normalMaxVelocity: 19
|
NormalMaxVelocity: 15
|
||||||
absolutMaxVelocity: 29
|
AbsolutMaxVelocity: 25
|
||||||
normalDrag: 5
|
NormalDrag: 5
|
||||||
maximumDrag: 10
|
MaximumDrag: 10
|
||||||
torqueDrag: 0.2
|
TorqueDrag: 0.2
|
||||||
antiDriftAmount: 8
|
GravityStrength: 30
|
||||||
minAntiDriftFactor: 0.5
|
AntiDriftAmount: 12
|
||||||
maxBoostCapacity: 4
|
MinAntiDriftFactor: 0.03
|
||||||
minBoostCapacity: 0.5
|
MaxBoostCapacity: 3.3
|
||||||
boostMagnitude: 2
|
MinBoostCapacity: 0.15
|
||||||
outsideBoostRate: 0
|
BoostMagnitude: 1.5
|
||||||
boostAntiGravityFactor: 0.8
|
OutsideBoostRate: 0
|
||||||
stunLooseControlFactor: 0.1
|
BoostAntiGravityFactor: 0.33
|
||||||
tacklingGraceTime: 0.6
|
StunLooseControlFactor: 0.1
|
||||||
tackledGraceTime: 0.3
|
TacklingGraceTime: 0.6
|
||||||
tackledCriticalStunTime: 0.6
|
TackledGraceTime: 0.6
|
||||||
tackledBodyStunTime: 0.3
|
TackledCriticalStunTime: 0.6
|
||||||
criticalTacklePowerFactor: 300
|
TackledBodyStunTime: 0.3
|
||||||
normalTacklePowerFactor: 300
|
CriticalTacklePowerFactor: 60
|
||||||
audio: {fileID: 11400000, guid: 96db7e9f041aed7459cb776fddee1741, type: 2}
|
NormalTacklePowerFactor: 40
|
||||||
|
Audio: {fileID: 11400000, guid: 96db7e9f041aed7459cb776fddee1741, type: 2}
|
||||||
|
|||||||
@ -12,14 +12,15 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
||||||
m_Name: BlueShip
|
m_Name: BlueShip
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
baseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
BaseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
||||||
shipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
ShipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
||||||
shipName: Blue Blitz
|
ShipName: Blue Blitz
|
||||||
shipHullColor: {r: 0, g: 0.62125206, b: 1, a: 1}
|
ShipHullColor: {r: 0, g: 0.3522544, b: 1, a: 1}
|
||||||
thrustAccelerationModifier: 1
|
thrustAccelerationModifier: 1
|
||||||
steerVelocityModifier: 1
|
steerVelocityModifier: 1
|
||||||
normalMaxVelocityModifier: 1
|
normalMaxVelocityModifier: 1
|
||||||
absolutMaxVelocityModifier: 1
|
absolutMaxVelocityModifier: 1
|
||||||
|
gravityStrengthModifier: 1
|
||||||
antiDriftAmountModifier: 1
|
antiDriftAmountModifier: 1
|
||||||
minAntiDriftFactorModifier: 1
|
minAntiDriftFactorModifier: 1
|
||||||
normalDragModifier: 1
|
normalDragModifier: 1
|
||||||
@ -31,7 +32,10 @@ MonoBehaviour:
|
|||||||
outsideBoostRateModifier: 1
|
outsideBoostRateModifier: 1
|
||||||
boostAntiGravityFactorModifier: 1
|
boostAntiGravityFactorModifier: 1
|
||||||
stunLooseControlFactorModifier: 1
|
stunLooseControlFactorModifier: 1
|
||||||
|
tacklingGraceTimeModifier: 1
|
||||||
|
tackledGraceTimeModifier: 1
|
||||||
tackleCriticalStunTimeModifier: 1
|
tackleCriticalStunTimeModifier: 1
|
||||||
tackleBodyStunTimeModifier: 1
|
tackleBodyStunTimeModifier: 1
|
||||||
criticalTacklePowerFactorModifier: 1
|
criticalTacklePowerFactorModifier: 1
|
||||||
normalTacklePowerFactorModifier: 1
|
normalTacklePowerFactorModifier: 1
|
||||||
|
alternativeShipSounds: {fileID: 0}
|
||||||
|
|||||||
@ -12,14 +12,15 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
||||||
m_Name: GreenShip
|
m_Name: GreenShip
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
baseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
BaseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
||||||
shipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
ShipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
||||||
shipName: Green Danger
|
ShipName: Green Danger
|
||||||
shipHullColor: {r: 0, g: 1, b: 0.40690804, a: 1}
|
ShipHullColor: {r: 0.0276097, g: 0.81886786, b: 0, a: 1}
|
||||||
thrustAccelerationModifier: 1
|
thrustAccelerationModifier: 1
|
||||||
steerVelocityModifier: 1
|
steerVelocityModifier: 1
|
||||||
normalMaxVelocityModifier: 1
|
normalMaxVelocityModifier: 1
|
||||||
absolutMaxVelocityModifier: 1
|
absolutMaxVelocityModifier: 1
|
||||||
|
gravityStrengthModifier: 1
|
||||||
antiDriftAmountModifier: 1
|
antiDriftAmountModifier: 1
|
||||||
minAntiDriftFactorModifier: 1
|
minAntiDriftFactorModifier: 1
|
||||||
normalDragModifier: 1
|
normalDragModifier: 1
|
||||||
@ -31,7 +32,10 @@ MonoBehaviour:
|
|||||||
outsideBoostRateModifier: 1
|
outsideBoostRateModifier: 1
|
||||||
boostAntiGravityFactorModifier: 1
|
boostAntiGravityFactorModifier: 1
|
||||||
stunLooseControlFactorModifier: 1
|
stunLooseControlFactorModifier: 1
|
||||||
|
tacklingGraceTimeModifier: 1
|
||||||
|
tackledGraceTimeModifier: 1
|
||||||
tackleCriticalStunTimeModifier: 1
|
tackleCriticalStunTimeModifier: 1
|
||||||
tackleBodyStunTimeModifier: 1
|
tackleBodyStunTimeModifier: 1
|
||||||
criticalTacklePowerFactorModifier: 1
|
criticalTacklePowerFactorModifier: 1
|
||||||
normalTacklePowerFactorModifier: 1
|
normalTacklePowerFactorModifier: 1
|
||||||
|
alternativeShipSounds: {fileID: 0}
|
||||||
|
|||||||
@ -12,14 +12,15 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
||||||
m_Name: PurpleShip
|
m_Name: PurpleShip
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
baseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
BaseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
||||||
shipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
ShipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
||||||
shipName: Purple Haze
|
ShipName: Purple Burglar
|
||||||
shipHullColor: {r: 0.6345311, g: 0.17924517, b: 1, a: 1}
|
ShipHullColor: {r: 0.69604963, g: 0, b: 0.8490566, a: 1}
|
||||||
thrustAccelerationModifier: 1
|
thrustAccelerationModifier: 1
|
||||||
steerVelocityModifier: 1
|
steerVelocityModifier: 1
|
||||||
normalMaxVelocityModifier: 1
|
normalMaxVelocityModifier: 1
|
||||||
absolutMaxVelocityModifier: 1
|
absolutMaxVelocityModifier: 1
|
||||||
|
gravityStrengthModifier: 1
|
||||||
antiDriftAmountModifier: 1
|
antiDriftAmountModifier: 1
|
||||||
minAntiDriftFactorModifier: 1
|
minAntiDriftFactorModifier: 1
|
||||||
normalDragModifier: 1
|
normalDragModifier: 1
|
||||||
@ -31,7 +32,10 @@ MonoBehaviour:
|
|||||||
outsideBoostRateModifier: 1
|
outsideBoostRateModifier: 1
|
||||||
boostAntiGravityFactorModifier: 1
|
boostAntiGravityFactorModifier: 1
|
||||||
stunLooseControlFactorModifier: 1
|
stunLooseControlFactorModifier: 1
|
||||||
|
tacklingGraceTimeModifier: 1
|
||||||
|
tackledGraceTimeModifier: 1
|
||||||
tackleCriticalStunTimeModifier: 1
|
tackleCriticalStunTimeModifier: 1
|
||||||
tackleBodyStunTimeModifier: 1
|
tackleBodyStunTimeModifier: 1
|
||||||
criticalTacklePowerFactorModifier: 1
|
criticalTacklePowerFactorModifier: 1
|
||||||
normalTacklePowerFactorModifier: 1
|
normalTacklePowerFactorModifier: 1
|
||||||
|
alternativeShipSounds: {fileID: 0}
|
||||||
|
|||||||
@ -12,14 +12,15 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
m_Script: {fileID: 11500000, guid: f5cabb9de76fbfa49b5ccac30cd25c68, type: 3}
|
||||||
m_Name: RedShip
|
m_Name: RedShip
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
baseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
BaseProps: {fileID: 11400000, guid: 8bb9b96c7ef17e94bbd897292f08cd4e, type: 2}
|
||||||
shipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
ShipPrefab: {fileID: 1372816401649438144, guid: 75db4d0681fa51f4bb6106997f11022e, type: 3}
|
||||||
shipName: Red Menace
|
ShipName: Red Menace
|
||||||
shipHullColor: {r: 0.9924528, g: 0.18470371, b: 0.1404413, a: 1}
|
ShipHullColor: {r: 1, g: 0.13396227, b: 0.15771939, a: 1}
|
||||||
thrustAccelerationModifier: 1
|
thrustAccelerationModifier: 1
|
||||||
steerVelocityModifier: 1
|
steerVelocityModifier: 1
|
||||||
normalMaxVelocityModifier: 1
|
normalMaxVelocityModifier: 1
|
||||||
absolutMaxVelocityModifier: 1
|
absolutMaxVelocityModifier: 1
|
||||||
|
gravityStrengthModifier: 1
|
||||||
antiDriftAmountModifier: 1
|
antiDriftAmountModifier: 1
|
||||||
minAntiDriftFactorModifier: 1
|
minAntiDriftFactorModifier: 1
|
||||||
normalDragModifier: 1
|
normalDragModifier: 1
|
||||||
@ -31,7 +32,10 @@ MonoBehaviour:
|
|||||||
outsideBoostRateModifier: 1
|
outsideBoostRateModifier: 1
|
||||||
boostAntiGravityFactorModifier: 1
|
boostAntiGravityFactorModifier: 1
|
||||||
stunLooseControlFactorModifier: 1
|
stunLooseControlFactorModifier: 1
|
||||||
|
tacklingGraceTimeModifier: 1
|
||||||
|
tackledGraceTimeModifier: 1
|
||||||
tackleCriticalStunTimeModifier: 1
|
tackleCriticalStunTimeModifier: 1
|
||||||
tackleBodyStunTimeModifier: 1
|
tackleBodyStunTimeModifier: 1
|
||||||
criticalTacklePowerFactorModifier: 1
|
criticalTacklePowerFactorModifier: 1
|
||||||
normalTacklePowerFactorModifier: 1
|
normalTacklePowerFactorModifier: 1
|
||||||
|
alternativeShipSounds: {fileID: 0}
|
||||||
|
|||||||
@ -86,7 +86,7 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
InstanceID = gameObject.GetInstanceID();
|
InstanceID = gameObject.GetInstanceID();
|
||||||
state.boostCapacity = props.maxBoostCapacity;
|
state.boostCapacity = props.MaxBoostCapacity;
|
||||||
// boostUI.SetMinBoostRatio(props.minBoostCapacity / props.maxBoostCapacity);
|
// boostUI.SetMinBoostRatio(props.minBoostCapacity / props.maxBoostCapacity);
|
||||||
// GameManager.GM.RegisterPlayer(this);
|
// GameManager.GM.RegisterPlayer(this);
|
||||||
cameraOperator.AddCharacter(smoothedRepresentation);
|
cameraOperator.AddCharacter(smoothedRepresentation);
|
||||||
@ -140,7 +140,7 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
{
|
{
|
||||||
//Debug.Log("inupdatemove " + currentThrustInput);
|
//Debug.Log("inupdatemove " + currentThrustInput);
|
||||||
// Player rotation is always possible and same speed
|
// Player rotation is always possible and same speed
|
||||||
transform.Rotate(0, 0, (float)(-props.steerVelocity * rd.Steer * 2 * TimeManager.TickDelta));
|
transform.Rotate(0, 0, (float)(-props.SteerVelocity * rd.Steer * 2 * TimeManager.TickDelta));
|
||||||
//PredictionRigidbody.AddTorque(new Vector3(0, 0, -props.steerVelocity * rd.Steer * Time.deltaTime));
|
//PredictionRigidbody.AddTorque(new Vector3(0, 0, -props.steerVelocity * rd.Steer * Time.deltaTime));
|
||||||
|
|
||||||
// // Get and apply the current Gravity
|
// // Get and apply the current Gravity
|
||||||
@ -148,10 +148,10 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
state.currentGravity = forceManager.GetGravityForInstance(InstanceID)(gravitySource, transform);
|
state.currentGravity = forceManager.GetGravityForInstance(InstanceID)(gravitySource, transform);
|
||||||
PredictionRigidbody.AddForce(state.currentGravity, ForceMode.Acceleration);
|
PredictionRigidbody.AddForce(state.currentGravity, ForceMode.Acceleration);
|
||||||
|
|
||||||
float stunFactor = isCriticalTackle ? props.stunLooseControlFactor : 1f;
|
float stunFactor = isCriticalTackle ? props.StunLooseControlFactor : 1f;
|
||||||
|
|
||||||
float thrust = IsBoosting(rd.Boost) ? 1f : rd.Thrust;
|
float thrust = IsBoosting(rd.Boost) ? 1f : rd.Thrust;
|
||||||
Vector3 acceleration = props.thrustAcceleration * thrust * (float)TimeManager.TickDelta
|
Vector3 acceleration = props.ThrustAcceleration * thrust * (float)TimeManager.TickDelta
|
||||||
* transform.up * stunFactor * 2;
|
* transform.up * stunFactor * 2;
|
||||||
|
|
||||||
Vector3 currentVelocity = body.velocity;
|
Vector3 currentVelocity = body.velocity;
|
||||||
@ -175,20 +175,20 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (currentVelocity.magnitude <= props.normalMaxVelocity || IsBoosting(rd.Boost)
|
if (currentVelocity.magnitude <= props.NormalMaxVelocity || IsBoosting(rd.Boost)
|
||||||
|| zone != Zone.NimbleZone)
|
|| zone != Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
PredictionRigidbody.AddForce(boostedAcceleration, ForceMode.Acceleration);
|
PredictionRigidbody.AddForce(boostedAcceleration, ForceMode.Acceleration);
|
||||||
|
|
||||||
}
|
}
|
||||||
if (currentVelocity.magnitude >= props.absolutMaxVelocity && zone == Zone.NimbleZone)
|
if (currentVelocity.magnitude >= props.AbsolutMaxVelocity && zone == Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
body.velocity = body.velocity.normalized * props.absolutMaxVelocity;
|
body.velocity = body.velocity.normalized * props.AbsolutMaxVelocity;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Default torque drag
|
// Default torque drag
|
||||||
PredictionRigidbody.AddRelativeTorque(body.angularVelocity * -props.torqueDrag, ForceMode.Acceleration);
|
PredictionRigidbody.AddRelativeTorque(body.angularVelocity * -props.TorqueDrag, ForceMode.Acceleration);
|
||||||
|
|
||||||
// Debug.DrawRay(transform.position, transform.up * (currentVelocity.magnitude + 3) * 0.5f,
|
// Debug.DrawRay(transform.position, transform.up * (currentVelocity.magnitude + 3) * 0.5f,
|
||||||
// Color.black);
|
// Color.black);
|
||||||
@ -260,17 +260,17 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
|
|
||||||
//Debug.Log("inupdatemove " + currentThrustInput);
|
//Debug.Log("inupdatemove " + currentThrustInput);
|
||||||
// Player rotation is always possible and same speed
|
// Player rotation is always possible and same speed
|
||||||
transform.Rotate(0, 0, -props.steerVelocity * input.steerInput * Time.deltaTime);
|
transform.Rotate(0, 0, -props.SteerVelocity * input.steerInput * Time.deltaTime);
|
||||||
|
|
||||||
// Get and apply the current Gravity
|
// Get and apply the current Gravity
|
||||||
Transform gravitySource = forceManager.GetGravitySourceForInstance(InstanceID);
|
Transform gravitySource = forceManager.GetGravitySourceForInstance(InstanceID);
|
||||||
state.currentGravity = forceManager.GetGravityForInstance(InstanceID)(gravitySource, transform);
|
state.currentGravity = forceManager.GetGravityForInstance(InstanceID)(gravitySource, transform);
|
||||||
body.AddForce(state.currentGravity, ForceMode.Acceleration);
|
body.AddForce(state.currentGravity, ForceMode.Acceleration);
|
||||||
|
|
||||||
float stunFactor = isCriticalTackle ? props.stunLooseControlFactor : 1f;
|
float stunFactor = isCriticalTackle ? props.StunLooseControlFactor : 1f;
|
||||||
|
|
||||||
float thrust = IsBoosting(input.boostInput) ? 1f : input.thrustInput;
|
float thrust = IsBoosting(input.boostInput) ? 1f : input.thrustInput;
|
||||||
Vector3 acceleration = props.thrustAcceleration * thrust * Time.deltaTime
|
Vector3 acceleration = props.ThrustAcceleration * thrust * Time.deltaTime
|
||||||
* transform.up * stunFactor;
|
* transform.up * stunFactor;
|
||||||
|
|
||||||
Vector3 currentVelocity = body.velocity;
|
Vector3 currentVelocity = body.velocity;
|
||||||
@ -294,20 +294,20 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (currentVelocity.magnitude <= props.normalMaxVelocity || IsBoosting(input.boostInput)
|
if (currentVelocity.magnitude <= props.NormalMaxVelocity || IsBoosting(input.boostInput)
|
||||||
|| zone != Zone.NimbleZone)
|
|| zone != Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
body.AddForce(boostedAcceleration, ForceMode.Acceleration);
|
body.AddForce(boostedAcceleration, ForceMode.Acceleration);
|
||||||
|
|
||||||
}
|
}
|
||||||
if (currentVelocity.magnitude >= props.absolutMaxVelocity && zone == Zone.NimbleZone)
|
if (currentVelocity.magnitude >= props.AbsolutMaxVelocity && zone == Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
body.velocity = body.velocity.normalized * props.absolutMaxVelocity;
|
body.velocity = body.velocity.normalized * props.AbsolutMaxVelocity;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Default torque drag
|
// Default torque drag
|
||||||
body.AddRelativeTorque(body.angularVelocity * -props.torqueDrag, ForceMode.Acceleration);
|
body.AddRelativeTorque(body.angularVelocity * -props.TorqueDrag, ForceMode.Acceleration);
|
||||||
|
|
||||||
Debug.DrawRay(transform.position, transform.up * (currentVelocity.magnitude + 3) * 0.5f,
|
Debug.DrawRay(transform.position, transform.up * (currentVelocity.magnitude + 3) * 0.5f,
|
||||||
Color.black);
|
Color.black);
|
||||||
@ -336,16 +336,16 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
}
|
}
|
||||||
|
|
||||||
antiDriftVelocity = Vector3.Reflect(-driftVelocity, up) - driftVelocity;
|
antiDriftVelocity = Vector3.Reflect(-driftVelocity, up) - driftVelocity;
|
||||||
antiDriftFactor = Mathf.InverseLerp(props.absolutMaxVelocity, props.normalMaxVelocity,
|
antiDriftFactor = Mathf.InverseLerp(props.AbsolutMaxVelocity, props.NormalMaxVelocity,
|
||||||
currentVelocity.magnitude);
|
currentVelocity.magnitude);
|
||||||
|
|
||||||
antiDriftFactor = Mathf.Max(antiDriftFactor, props.minAntiDriftFactor);
|
antiDriftFactor = Mathf.Max(antiDriftFactor, props.MinAntiDriftFactor);
|
||||||
|
|
||||||
Debug.DrawRay(transform.position, currentVelocity.normalized * currentVelocity.magnitude * 2, Color.cyan);
|
Debug.DrawRay(transform.position, currentVelocity.normalized * currentVelocity.magnitude * 2, Color.cyan);
|
||||||
Debug.DrawRay(transform.position, driftVelocity.normalized * 5, Color.red);
|
Debug.DrawRay(transform.position, driftVelocity.normalized * 5, Color.red);
|
||||||
Debug.DrawRay(transform.position, antiDriftVelocity.normalized * 5, Color.green);
|
Debug.DrawRay(transform.position, antiDriftVelocity.normalized * 5, Color.green);
|
||||||
|
|
||||||
return antiDriftVelocity * props.antiDriftAmount * antiDriftFactor;
|
return antiDriftVelocity * props.AntiDriftAmount * antiDriftFactor;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -357,19 +357,19 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
Vector3 DragDecceleration(Vector3 currentVelocity, Zone zone)
|
Vector3 DragDecceleration(Vector3 currentVelocity, Zone zone)
|
||||||
{
|
{
|
||||||
Vector3 drag = new Vector3();
|
Vector3 drag = new Vector3();
|
||||||
float minDragFactor = Mathf.InverseLerp(props.absolutMaxVelocity, props.normalMaxVelocity,
|
float minDragFactor = Mathf.InverseLerp(props.AbsolutMaxVelocity, props.NormalMaxVelocity,
|
||||||
currentVelocity.magnitude);
|
currentVelocity.magnitude);
|
||||||
|
|
||||||
float normalDragFactor = Mathf.InverseLerp(props.normalMaxVelocity, 0,
|
float normalDragFactor = Mathf.InverseLerp(props.NormalMaxVelocity, 0,
|
||||||
currentVelocity.magnitude);
|
currentVelocity.magnitude);
|
||||||
|
|
||||||
if (!IsBoosting(input.boostInput) && zone == Zone.NimbleZone)
|
if (!IsBoosting(input.boostInput) && zone == Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
drag -= currentVelocity.normalized * props.normalDrag;
|
drag -= currentVelocity.normalized * props.NormalDrag;
|
||||||
}
|
}
|
||||||
if (currentVelocity.magnitude >= props.normalMaxVelocity && zone == Zone.NimbleZone)
|
if (currentVelocity.magnitude >= props.NormalMaxVelocity && zone == Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
drag -= currentVelocity.normalized * props.maximumDrag;
|
drag -= currentVelocity.normalized * props.MaximumDrag;
|
||||||
}
|
}
|
||||||
return drag;
|
return drag;
|
||||||
}
|
}
|
||||||
@ -395,8 +395,8 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
{
|
{
|
||||||
if (IsBoosting(input.boostInput))
|
if (IsBoosting(input.boostInput))
|
||||||
{
|
{
|
||||||
acceleration *= props.boostMagnitude;
|
acceleration *= props.BoostMagnitude;
|
||||||
acceleration -= currentGravity * props.boostAntiGravityFactor;
|
acceleration -= currentGravity * props.BoostAntiGravityFactor;
|
||||||
}
|
}
|
||||||
return acceleration;
|
return acceleration;
|
||||||
}
|
}
|
||||||
@ -407,14 +407,14 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
/// <param name="deltaTime">Time delta of the current frame</param>
|
/// <param name="deltaTime">Time delta of the current frame</param>
|
||||||
void BoostStateUpdate(float deltaTime)
|
void BoostStateUpdate(float deltaTime)
|
||||||
{
|
{
|
||||||
BoostUI.UpdateFill(Math.Min(state.boostCapacity / props.maxBoostCapacity, 1));
|
BoostUI.UpdateFill(Math.Min(state.boostCapacity / props.MaxBoostCapacity, 1));
|
||||||
if (IsBoosting(input.boostInput))
|
if (IsBoosting(input.boostInput))
|
||||||
{
|
{
|
||||||
state.boostCapacity -= deltaTime;
|
state.boostCapacity -= deltaTime;
|
||||||
}
|
}
|
||||||
if (canBoost && zone == Zone.OutsideZone)
|
if (canBoost && zone == Zone.OutsideZone)
|
||||||
{
|
{
|
||||||
state.boostCapacity -= deltaTime * props.outsideBoostRate;
|
state.boostCapacity -= deltaTime * props.OutsideBoostRate;
|
||||||
}
|
}
|
||||||
if (state.boostCapacity <= 0)
|
if (state.boostCapacity <= 0)
|
||||||
{
|
{
|
||||||
@ -423,13 +423,13 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
|
|
||||||
if ((input.boostInput <= 0 || !canBoost)
|
if ((input.boostInput <= 0 || !canBoost)
|
||||||
&& zone == Zone.NimbleZone
|
&& zone == Zone.NimbleZone
|
||||||
&& state.boostCapacity <= props.maxBoostCapacity)
|
&& state.boostCapacity <= props.MaxBoostCapacity)
|
||||||
{
|
{
|
||||||
state.boostCapacity += deltaTime;
|
state.boostCapacity += deltaTime;
|
||||||
}
|
}
|
||||||
// When your boost capacity is still critical, you can't start boosting immediately again.
|
// When your boost capacity is still critical, you can't start boosting immediately again.
|
||||||
// TODO: This is not tested well enough with players.
|
// TODO: This is not tested well enough with players.
|
||||||
if (canBoost == false && state.boostCapacity >= props.minBoostCapacity)
|
if (canBoost == false && state.boostCapacity >= props.MinBoostCapacity)
|
||||||
{
|
{
|
||||||
canBoost = true;
|
canBoost = true;
|
||||||
}
|
}
|
||||||
@ -447,8 +447,8 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
if (gotTackled && !isTackled)
|
if (gotTackled && !isTackled)
|
||||||
{
|
{
|
||||||
isTackled = true;
|
isTackled = true;
|
||||||
tackledTime = isCriticalTackle ? props.tackledCriticalStunTime :
|
tackledTime = isCriticalTackle ? props.TackledCriticalStunTime :
|
||||||
props.tackledBodyStunTime;
|
props.TackledBodyStunTime;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
tackledTime -= Time.deltaTime;
|
tackledTime -= Time.deltaTime;
|
||||||
@ -483,8 +483,8 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
{
|
{
|
||||||
if (IgnoreTackle())
|
if (IgnoreTackle())
|
||||||
return;
|
return;
|
||||||
Log.Debug($"{props.shipName} is tackling.");
|
Log.Debug($"{props.ShipName} is tackling.");
|
||||||
TemporarilyIgnoreTackles(props.tacklingGraceTime);
|
TemporarilyIgnoreTackles(props.TacklingGraceTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -497,19 +497,19 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
{
|
{
|
||||||
if (IgnoreTackle())
|
if (IgnoreTackle())
|
||||||
return;
|
return;
|
||||||
TemporarilyIgnoreTackles(props.tackledGraceTime);
|
TemporarilyIgnoreTackles(props.TackledGraceTime);
|
||||||
|
|
||||||
float tacklePowerFactor = props.criticalTacklePowerFactor;
|
float tacklePowerFactor = props.CriticalTacklePowerFactor;
|
||||||
if (tackleKind == TackleKind.IncomingCritical)
|
if (tackleKind == TackleKind.IncomingCritical)
|
||||||
{
|
{
|
||||||
isCriticalTackle = true;
|
isCriticalTackle = true;
|
||||||
Log.Debug($"{props.shipName} has been tackled critically.");
|
Log.Debug($"{props.ShipName} has been tackled critically.");
|
||||||
}
|
}
|
||||||
else if (tackleKind == TackleKind.IncomingNormal)
|
else if (tackleKind == TackleKind.IncomingNormal)
|
||||||
{
|
{
|
||||||
isCriticalTackle = false;
|
isCriticalTackle = false;
|
||||||
tacklePowerFactor = props.normalTacklePowerFactor;
|
tacklePowerFactor = props.NormalTacklePowerFactor;
|
||||||
Log.Debug($"{props.shipName} has been tackled.");
|
Log.Debug($"{props.ShipName} has been tackled.");
|
||||||
}
|
}
|
||||||
Vector3 colliderVelocity = collider.attachedRigidbody.velocity;
|
Vector3 colliderVelocity = collider.attachedRigidbody.velocity;
|
||||||
//Log.Debug("velocity " + colliderVelocity);
|
//Log.Debug("velocity " + colliderVelocity);
|
||||||
@ -545,7 +545,7 @@ public class PredictedShip : NetworkBehaviour, IHUDOwner
|
|||||||
gravityEffect.Stop();
|
gravityEffect.Stop();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
float velocityFactor = math.smoothstep(0, props.absolutMaxVelocity, body.velocity.magnitude);
|
float velocityFactor = math.smoothstep(0, props.AbsolutMaxVelocity, body.velocity.magnitude);
|
||||||
if (math.abs(input.thrustInput) > 0 || IsBoosting(input.boostInput))
|
if (math.abs(input.thrustInput) > 0 || IsBoosting(input.boostInput))
|
||||||
{
|
{
|
||||||
ThrusterSound.PlayAudio(true);
|
ThrusterSound.PlayAudio(true);
|
||||||
|
|||||||
@ -57,10 +57,10 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
InstanceID = gameObject.GetInstanceID();
|
InstanceID = gameObject.GetInstanceID();
|
||||||
State.boostCapacity = Props.maxBoostCapacity;
|
State.boostCapacity = Props.MaxBoostCapacity;
|
||||||
|
|
||||||
// Get manageable audio instances for the ships sounds
|
// Get manageable audio instances for the ships sounds
|
||||||
foreach (ShipSoundToName stn in Props.audio.shipSounds)
|
foreach (ShipSoundToName stn in Props.Audio.shipSounds)
|
||||||
{
|
{
|
||||||
ManageableAudio ma = AudioManager.G.GetLocalSound(stn.soundName, 1,
|
ManageableAudio ma = AudioManager.G.GetLocalSound(stn.soundName, 1,
|
||||||
gameObject.transform);
|
gameObject.transform);
|
||||||
@ -131,17 +131,17 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
|
|
||||||
//Debug.Log("inupdatemove " + currentThrustInput);
|
//Debug.Log("inupdatemove " + currentThrustInput);
|
||||||
// Player rotation is always possible and same speed
|
// Player rotation is always possible and same speed
|
||||||
transform.Rotate(0, 0, -Props.steerVelocity * Input.steerInput * Time.deltaTime);
|
transform.Rotate(0, 0, -Props.SteerVelocity * Input.steerInput * Time.deltaTime);
|
||||||
|
|
||||||
// Get and apply the current Gravity
|
// Get and apply the current Gravity
|
||||||
Transform gravitySource = _forceManager.GetGravitySourceForInstance(InstanceID);
|
Transform gravitySource = _forceManager.GetGravitySourceForInstance(InstanceID);
|
||||||
State.currentGravity = _forceManager.GetGravityForInstance(InstanceID)(gravitySource, transform);
|
State.currentGravity = _forceManager.GetGravityForInstance(InstanceID)(gravitySource, transform) * Props.GravitStrength;
|
||||||
_body.AddForce(State.currentGravity, ForceMode.Acceleration);
|
_body.AddForce(State.currentGravity, ForceMode.Acceleration);
|
||||||
|
|
||||||
float stunFactor = _isCriticalTackle ? Props.stunLooseControlFactor : 1f;
|
float stunFactor = _isCriticalTackle ? Props.StunLooseControlFactor : 1f;
|
||||||
|
|
||||||
float thrust = IsBoosting() ? 1f : Input.thrustInput;
|
float thrust = IsBoosting() ? 1f : Input.thrustInput;
|
||||||
Vector3 acceleration = Props.thrustAcceleration * thrust * Time.deltaTime
|
Vector3 acceleration = Props.ThrustAcceleration * thrust * Time.deltaTime
|
||||||
* transform.up * stunFactor;
|
* transform.up * stunFactor;
|
||||||
|
|
||||||
Vector3 currentVelocity = _body.velocity;
|
Vector3 currentVelocity = _body.velocity;
|
||||||
@ -165,20 +165,20 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (currentVelocity.magnitude <= Props.normalMaxVelocity || IsBoosting()
|
if (currentVelocity.magnitude <= Props.NormalMaxVelocity || IsBoosting()
|
||||||
|| State.Zone != Zone.NimbleZone)
|
|| State.Zone != Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
_body.AddForce(boostedAcceleration, ForceMode.Acceleration);
|
_body.AddForce(boostedAcceleration, ForceMode.Acceleration);
|
||||||
|
|
||||||
}
|
}
|
||||||
if (currentVelocity.magnitude >= Props.absolutMaxVelocity && State.Zone == Zone.NimbleZone)
|
if (currentVelocity.magnitude >= Props.AbsolutMaxVelocity && State.Zone == Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
_body.velocity = _body.velocity.normalized * Props.absolutMaxVelocity;
|
_body.velocity = _body.velocity.normalized * Props.AbsolutMaxVelocity;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Default torque drag
|
// Default torque drag
|
||||||
_body.AddRelativeTorque(_body.angularVelocity * -Props.torqueDrag, ForceMode.Acceleration);
|
_body.AddRelativeTorque(_body.angularVelocity * -Props.TorqueDrag, ForceMode.Acceleration);
|
||||||
|
|
||||||
Debug.DrawRay(transform.position, transform.up * (currentVelocity.magnitude + 3) * 0.5f,
|
Debug.DrawRay(transform.position, transform.up * (currentVelocity.magnitude + 3) * 0.5f,
|
||||||
Color.black);
|
Color.black);
|
||||||
@ -208,17 +208,17 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
}
|
}
|
||||||
|
|
||||||
antiDriftVelocity = Vector3.Reflect(-driftVelocity, up) - driftVelocity;
|
antiDriftVelocity = Vector3.Reflect(-driftVelocity, up) - driftVelocity;
|
||||||
antiDriftFactor = Mathf.InverseLerp(Props.absolutMaxVelocity, Props.normalMaxVelocity,
|
antiDriftFactor = Mathf.InverseLerp(Props.AbsolutMaxVelocity, Props.NormalMaxVelocity,
|
||||||
currentVelocity.magnitude);
|
currentVelocity.magnitude);
|
||||||
|
|
||||||
antiDriftFactor = Mathf.Max(antiDriftFactor, Props.minAntiDriftFactor);
|
antiDriftFactor = Mathf.Max(antiDriftFactor, Props.MinAntiDriftFactor);
|
||||||
|
|
||||||
Debug.DrawRay(transform.position, currentVelocity.normalized * currentVelocity.magnitude * 2,
|
Debug.DrawRay(transform.position, currentVelocity.normalized * currentVelocity.magnitude * 2,
|
||||||
Color.cyan);
|
Color.cyan);
|
||||||
Debug.DrawRay(transform.position, driftVelocity.normalized * 5, Color.red);
|
Debug.DrawRay(transform.position, driftVelocity.normalized * 5, Color.red);
|
||||||
Debug.DrawRay(transform.position, antiDriftVelocity.normalized * 5, Color.green);
|
Debug.DrawRay(transform.position, antiDriftVelocity.normalized * 5, Color.green);
|
||||||
|
|
||||||
return antiDriftVelocity * Props.antiDriftAmount * antiDriftFactor;
|
return antiDriftVelocity * Props.AntiDriftAmount * antiDriftFactor;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -230,19 +230,19 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
Vector3 DragDecceleration(Vector3 currentVelocity, Zone zone)
|
Vector3 DragDecceleration(Vector3 currentVelocity, Zone zone)
|
||||||
{
|
{
|
||||||
Vector3 drag = new Vector3();
|
Vector3 drag = new Vector3();
|
||||||
float minDragFactor = Mathf.InverseLerp(Props.absolutMaxVelocity, Props.normalMaxVelocity,
|
float minDragFactor = Mathf.InverseLerp(Props.AbsolutMaxVelocity, Props.NormalMaxVelocity,
|
||||||
currentVelocity.magnitude);
|
currentVelocity.magnitude);
|
||||||
|
|
||||||
float normalDragFactor = Mathf.InverseLerp(Props.normalMaxVelocity, 0,
|
float normalDragFactor = Mathf.InverseLerp(Props.NormalMaxVelocity, 0,
|
||||||
currentVelocity.magnitude);
|
currentVelocity.magnitude);
|
||||||
|
|
||||||
if (!IsBoosting() && zone == Zone.NimbleZone)
|
if (!IsBoosting() && zone == Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
drag -= currentVelocity.normalized * Props.normalDrag;
|
drag -= currentVelocity.normalized * Props.NormalDrag;
|
||||||
}
|
}
|
||||||
if (currentVelocity.magnitude >= Props.normalMaxVelocity && zone == Zone.NimbleZone)
|
if (currentVelocity.magnitude >= Props.NormalMaxVelocity && zone == Zone.NimbleZone)
|
||||||
{
|
{
|
||||||
drag -= currentVelocity.normalized * Props.maximumDrag;
|
drag -= currentVelocity.normalized * Props.MaximumDrag;
|
||||||
}
|
}
|
||||||
return drag;
|
return drag;
|
||||||
}
|
}
|
||||||
@ -268,8 +268,8 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
{
|
{
|
||||||
if (IsBoosting())
|
if (IsBoosting())
|
||||||
{
|
{
|
||||||
acceleration *= Props.boostMagnitude;
|
acceleration *= Props.BoostMagnitude;
|
||||||
acceleration -= currentGravity * Props.boostAntiGravityFactor;
|
acceleration -= currentGravity * Props.BoostAntiGravityFactor;
|
||||||
}
|
}
|
||||||
return acceleration;
|
return acceleration;
|
||||||
}
|
}
|
||||||
@ -280,14 +280,14 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
/// <param name="deltaTime">Time delta of the current frame</param>
|
/// <param name="deltaTime">Time delta of the current frame</param>
|
||||||
void BoostStateUpdate(float deltaTime)
|
void BoostStateUpdate(float deltaTime)
|
||||||
{
|
{
|
||||||
BoostUI.UpdateFill(Math.Min(State.boostCapacity / Props.maxBoostCapacity, 1));
|
BoostUI.UpdateFill(Math.Min(State.boostCapacity / Props.MaxBoostCapacity, 1));
|
||||||
if (IsBoosting())
|
if (IsBoosting())
|
||||||
{
|
{
|
||||||
State.boostCapacity -= deltaTime;
|
State.boostCapacity -= deltaTime;
|
||||||
}
|
}
|
||||||
if (_canBoost && State.Zone == Zone.OutsideZone)
|
if (_canBoost && State.Zone == Zone.OutsideZone)
|
||||||
{
|
{
|
||||||
State.boostCapacity -= deltaTime * Props.outsideBoostRate;
|
State.boostCapacity -= deltaTime * Props.OutsideBoostRate;
|
||||||
}
|
}
|
||||||
if (State.boostCapacity <= 0)
|
if (State.boostCapacity <= 0)
|
||||||
{
|
{
|
||||||
@ -296,13 +296,13 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
|
|
||||||
if ((Input.boostInput <= 0 || !_canBoost)
|
if ((Input.boostInput <= 0 || !_canBoost)
|
||||||
&& State.Zone == Zone.NimbleZone
|
&& State.Zone == Zone.NimbleZone
|
||||||
&& State.boostCapacity <= Props.maxBoostCapacity)
|
&& State.boostCapacity <= Props.MaxBoostCapacity)
|
||||||
{
|
{
|
||||||
State.boostCapacity += deltaTime;
|
State.boostCapacity += deltaTime;
|
||||||
}
|
}
|
||||||
// When your boost capacity is still critical, you can't start boosting immediately again.
|
// When your boost capacity is still critical, you can't start boosting immediately again.
|
||||||
// TODO: This is not tested well enough with players.
|
// TODO: This is not tested well enough with players.
|
||||||
if (_canBoost == false && State.boostCapacity >= Props.minBoostCapacity)
|
if (_canBoost == false && State.boostCapacity >= Props.MinBoostCapacity)
|
||||||
{
|
{
|
||||||
_canBoost = true;
|
_canBoost = true;
|
||||||
}
|
}
|
||||||
@ -320,8 +320,8 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
if (gotTackled && !_isTackled)
|
if (gotTackled && !_isTackled)
|
||||||
{
|
{
|
||||||
_isTackled = true;
|
_isTackled = true;
|
||||||
_tackledTime = _isCriticalTackle ? Props.tackledCriticalStunTime :
|
_tackledTime = _isCriticalTackle ? Props.TackledCriticalStunTime :
|
||||||
Props.tackledBodyStunTime;
|
Props.TackledBodyStunTime;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
_tackledTime -= Time.deltaTime;
|
_tackledTime -= Time.deltaTime;
|
||||||
@ -356,8 +356,8 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
{
|
{
|
||||||
if (IgnoreTackle())
|
if (IgnoreTackle())
|
||||||
return;
|
return;
|
||||||
Log.Debug($"{Props.shipName} is tackling.");
|
Log.Debug($"{Props.ShipName} is tackling.");
|
||||||
TemporarilyIgnoreTackles(Props.tacklingGraceTime);
|
TemporarilyIgnoreTackles(Props.TacklingGraceTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -370,19 +370,19 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
{
|
{
|
||||||
if (IgnoreTackle())
|
if (IgnoreTackle())
|
||||||
return;
|
return;
|
||||||
TemporarilyIgnoreTackles(Props.tackledGraceTime);
|
TemporarilyIgnoreTackles(Props.TackledGraceTime);
|
||||||
|
|
||||||
float tacklePowerFactor = Props.criticalTacklePowerFactor;
|
float tacklePowerFactor = Props.CriticalTacklePowerFactor;
|
||||||
if (tackleKind == TackleKind.IncomingCritical)
|
if (tackleKind == TackleKind.IncomingCritical)
|
||||||
{
|
{
|
||||||
_isCriticalTackle = true;
|
_isCriticalTackle = true;
|
||||||
Log.Debug($"{Props.shipName} has been tackled critically.");
|
Log.Debug($"{Props.ShipName} has been tackled critically.");
|
||||||
}
|
}
|
||||||
else if (tackleKind == TackleKind.IncomingNormal)
|
else if (tackleKind == TackleKind.IncomingNormal)
|
||||||
{
|
{
|
||||||
_isCriticalTackle = false;
|
_isCriticalTackle = false;
|
||||||
tacklePowerFactor = Props.normalTacklePowerFactor;
|
tacklePowerFactor = Props.NormalTacklePowerFactor;
|
||||||
Log.Debug($"{Props.shipName} has been tackled.");
|
Log.Debug($"{Props.ShipName} has been tackled.");
|
||||||
}
|
}
|
||||||
Vector3 colliderVelocity = collider.attachedRigidbody.velocity;
|
Vector3 colliderVelocity = collider.attachedRigidbody.velocity;
|
||||||
//Log.Debug("velocity " + colliderVelocity);
|
//Log.Debug("velocity " + colliderVelocity);
|
||||||
@ -418,7 +418,7 @@ public class Ship : MonoBehaviour, IHUDOwner
|
|||||||
GravityEffect.Stop();
|
GravityEffect.Stop();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
float velocityFactor = math.smoothstep(0, Props.absolutMaxVelocity, _body.velocity.magnitude);
|
float velocityFactor = math.smoothstep(0, Props.AbsolutMaxVelocity, _body.velocity.magnitude);
|
||||||
if (math.abs(Input.thrustInput) > 0 || IsBoosting())
|
if (math.abs(Input.thrustInput) > 0 || IsBoosting())
|
||||||
{
|
{
|
||||||
sounds[Thruster].PlayAudio(true);
|
sounds[Thruster].PlayAudio(true);
|
||||||
|
|||||||
@ -1,150 +1,154 @@
|
|||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using log4net;
|
using log4net;
|
||||||
using Managers;
|
|
||||||
using Unity.Mathematics;
|
|
||||||
using Unity.VisualScripting;
|
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.UIElements;
|
using static GravityFunctionality.GravityHelpers;
|
||||||
using static AffectingForcesManager;
|
|
||||||
|
|
||||||
[ExecuteInEditMode]
|
namespace GravityFunctionality
|
||||||
public class GravityChanger : MonoBehaviour
|
|
||||||
{
|
{
|
||||||
private static ILog Log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
[ExecuteInEditMode]
|
||||||
private static Transform _nimbleZoneTransform;
|
public class GravityChanger : MonoBehaviour
|
||||||
public AffectingForcesManager forcesManager;
|
{
|
||||||
|
private static ILog Log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||||
|
private static Transform _nimbleZoneTransform;
|
||||||
|
|
||||||
public GameObject renderedZoneObject;
|
public GameObject RenderedZoneObject;
|
||||||
|
public ParticleSystem GravityEffect;
|
||||||
|
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private List<GravityColorEntry> GravityColors = new();
|
private List<GravityColorEntry> GravityColors = new();
|
||||||
|
|
||||||
private Dictionary<Gravity, Color> _gravityColors =
|
private Dictionary<Gravity, Color> _gravityColors =
|
||||||
new Dictionary<Gravity, Color>
|
new Dictionary<Gravity, Color>
|
||||||
{
|
{
|
||||||
{Gravity.DownGravity, Color.green },
|
{Gravity.DownGravity, Color.green },
|
||||||
{Gravity.UpGravity, Color.magenta },
|
{Gravity.UpGravity, Color.magenta },
|
||||||
{Gravity.NoGravity, Color.red },
|
{Gravity.NoGravity, Color.red },
|
||||||
{Gravity.InwardsGravity, Color.blue },
|
{Gravity.InwardsGravity, Color.blue },
|
||||||
{Gravity.OutwardsGravity, Color.yellow },
|
{Gravity.OutwardsGravity, Color.yellow },
|
||||||
};
|
};
|
||||||
|
|
||||||
[SerializeField]
|
|
||||||
private static float _gravityFactor = 30f;
|
|
||||||
|
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private Gravity _gravity = Gravity.NoGravity;
|
private Gravity _gravity = Gravity.NoGravity;
|
||||||
|
private AffectingForcesManager _forcesManager;
|
||||||
|
|
||||||
private int maxRippleAmount = 5;
|
private MeshRenderer meshRenderer;
|
||||||
private MeshRenderer meshRenderer;
|
private Material material;
|
||||||
private Material material;
|
|
||||||
|
|
||||||
void Awake()
|
void Awake()
|
||||||
{
|
|
||||||
foreach (GravityColorEntry entry in GravityColors)
|
|
||||||
{
|
{
|
||||||
_gravityColors[entry.gravity] = entry.color;
|
if (_forcesManager == null)
|
||||||
}
|
{
|
||||||
meshRenderer = renderedZoneObject.GetComponent<MeshRenderer>();
|
_forcesManager = GameObject.FindGameObjectWithTag("ForceManager").
|
||||||
_nimbleZoneTransform = gameObject.transform;
|
GetComponent<AffectingForcesManager>();
|
||||||
ApplyZoneColor(meshRenderer);
|
}
|
||||||
|
foreach (GravityColorEntry entry in GravityColors)
|
||||||
|
{
|
||||||
|
_gravityColors[entry.gravity] = entry.color;
|
||||||
|
}
|
||||||
|
meshRenderer = RenderedZoneObject.GetComponent<MeshRenderer>();
|
||||||
|
_nimbleZoneTransform = gameObject.transform;
|
||||||
|
ApplyZoneColor(meshRenderer);
|
||||||
|
|
||||||
#if UNITY_EDITOR
|
#if UNITY_EDITOR
|
||||||
if (!Application.isPlaying) return;
|
if (!Application.isPlaying) return;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
material = meshRenderer.material;
|
material = meshRenderer.material;
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Array of the available gravities.
|
|
||||||
/// </summary>
|
|
||||||
private Func<Transform, Transform, Vector3>[] gravityFunctions =
|
|
||||||
{ DownGravity, UpGravity, NoGravity, InwardsGravity, OutwardsGravity };
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity zero vector.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> NoGravity =
|
|
||||||
new((gravitySource, target) => new Vector3());
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector downwards, depending
|
|
||||||
/// on the parent transforms rotation.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> DownGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
gravitySource.rotation * Vector3.down * _gravityFactor);
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector upwards, depending
|
|
||||||
/// on the parent transforms rotation.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> UpGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
gravitySource.rotation * Vector3.up * _gravityFactor);
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector towards the center of the parenting transform.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> InwardsGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
(target.position - gravitySource.position).normalized * -_gravityFactor);
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector outwards from the center of the parenting transform.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> OutwardsGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
(target.position - gravitySource.position).normalized * _gravityFactor);
|
|
||||||
|
|
||||||
public Func<Transform, Transform, Vector3> GetGravityFunction(Gravity gravity)
|
|
||||||
{
|
|
||||||
return gravityFunctions[(int)gravity];
|
|
||||||
}
|
|
||||||
|
|
||||||
private void OnTriggerEnter(Collider collider)
|
|
||||||
{
|
|
||||||
int instanceID = collider.gameObject.GetInstanceID();
|
|
||||||
if (collider.tag == "Ship")
|
|
||||||
{
|
|
||||||
forcesManager.SetGravityForInstance(instanceID, GetGravityFunction(_gravity), transform);
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
private void Update()
|
void Start()
|
||||||
{
|
{
|
||||||
|
SetGravityEffect();
|
||||||
|
GravityEffect.Play();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void SetGravityEffect()
|
||||||
|
{
|
||||||
|
var velocityLifetime = GravityEffect.velocityOverLifetime;
|
||||||
|
var main = GravityEffect.main;
|
||||||
|
var emission = GravityEffect.emission;
|
||||||
|
switch (_gravity)
|
||||||
|
{
|
||||||
|
default:
|
||||||
|
case Gravity.DownGravity:
|
||||||
|
velocityLifetime.y = -1f;
|
||||||
|
main.startLifetime = 1.5f;
|
||||||
|
main.startSpeed = 0f;
|
||||||
|
velocityLifetime.speedModifier = 5f;
|
||||||
|
velocityLifetime.orbitalX = 0f;
|
||||||
|
velocityLifetime.orbitalY = 0f;
|
||||||
|
velocityLifetime.orbitalZ = 0f;
|
||||||
|
break;
|
||||||
|
case Gravity.UpGravity:
|
||||||
|
velocityLifetime.y = 1f;
|
||||||
|
main.startLifetime = 1.5f;
|
||||||
|
main.startSpeed = 0f;
|
||||||
|
velocityLifetime.speedModifier = 5f;
|
||||||
|
velocityLifetime.orbitalX = 0f;
|
||||||
|
velocityLifetime.orbitalY = 0f;
|
||||||
|
velocityLifetime.orbitalZ = 0f;
|
||||||
|
break;
|
||||||
|
case Gravity.OutwardsGravity:
|
||||||
|
velocityLifetime.y = 0;
|
||||||
|
main.startLifetime = 1.5f;
|
||||||
|
main.startSpeed = 1f;
|
||||||
|
velocityLifetime.speedModifier = 2f;
|
||||||
|
velocityLifetime.orbitalX = 0f;
|
||||||
|
velocityLifetime.orbitalY = 0f;
|
||||||
|
velocityLifetime.orbitalZ = 0f;
|
||||||
|
break;
|
||||||
|
case Gravity.InwardsGravity:
|
||||||
|
velocityLifetime.y = 0;
|
||||||
|
main.startLifetime = 1.5f;
|
||||||
|
main.startSpeed = -1f;
|
||||||
|
velocityLifetime.speedModifier = 1.5f;
|
||||||
|
velocityLifetime.orbitalX = 0.5f;
|
||||||
|
velocityLifetime.orbitalY = 0.5f;
|
||||||
|
velocityLifetime.orbitalZ = 0.5f;
|
||||||
|
break;
|
||||||
|
case Gravity.NoGravity:
|
||||||
|
main.startSpeed = 0f;
|
||||||
|
velocityLifetime.y = 0;
|
||||||
|
velocityLifetime.orbitalX = 0.2f;
|
||||||
|
velocityLifetime.orbitalY = 0.2f;
|
||||||
|
velocityLifetime.orbitalZ = 0.2f;
|
||||||
|
main.startLifetime = 8f;
|
||||||
|
emission.rateOverTime = 5;
|
||||||
|
velocityLifetime.speedModifier = 1f;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void OnTriggerEnter(Collider collider)
|
||||||
|
{
|
||||||
|
int instanceID = collider.gameObject.GetInstanceID();
|
||||||
|
if (collider.tag == "Ship")
|
||||||
|
{
|
||||||
|
var func = GetGravityFunction(_gravity);
|
||||||
|
_forcesManager.SetGravityForInstance(instanceID, func, transform);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Update()
|
||||||
|
{
|
||||||
#if UNITY_EDITOR
|
#if UNITY_EDITOR
|
||||||
if (!Application.isPlaying) return;
|
if (!Application.isPlaying) return;
|
||||||
#endif
|
#endif
|
||||||
material.SetFloat("_ShaderTime", Time.timeSinceLevelLoad);
|
material.SetFloat("_ShaderTime", Time.timeSinceLevelLoad);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ApplyZoneColor(MeshRenderer renderer)
|
||||||
|
{
|
||||||
|
Color color = _gravityColors[_gravity];
|
||||||
|
MaterialPropertyBlock materialPropertyBlock = new();
|
||||||
|
materialPropertyBlock.SetColor("_BaseColor", color);
|
||||||
|
renderer.SetPropertyBlock(materialPropertyBlock);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ApplyZoneColor(MeshRenderer renderer)
|
}
|
||||||
{
|
|
||||||
Color color = _gravityColors[_gravity];
|
|
||||||
MaterialPropertyBlock materialPropertyBlock = new();
|
|
||||||
materialPropertyBlock.SetColor("_BaseColor", color);
|
|
||||||
renderer.SetPropertyBlock(materialPropertyBlock);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public enum Gravity
|
|
||||||
{
|
|
||||||
DownGravity, UpGravity, NoGravity, InwardsGravity, OutwardsGravity
|
|
||||||
}
|
|
||||||
|
|
||||||
[Serializable]
|
|
||||||
public class GravityColorEntry
|
|
||||||
{
|
|
||||||
public Gravity gravity;
|
|
||||||
public Color color;
|
|
||||||
}
|
|
||||||
91
Assets/Scripts/GravityHelpers.cs
Normal file
91
Assets/Scripts/GravityHelpers.cs
Normal file
@ -0,0 +1,91 @@
|
|||||||
|
using System;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace GravityFunctionality
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Available types of gravity.
|
||||||
|
/// Need to match the existing functions!
|
||||||
|
/// </summary>
|
||||||
|
public enum Gravity
|
||||||
|
{
|
||||||
|
DownGravity = 0, UpGravity = 1, NoGravity = 2, InwardsGravity = 3, OutwardsGravity = 4
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Serializable mapping of a color to a gravity.
|
||||||
|
/// </summary>
|
||||||
|
[Serializable]
|
||||||
|
public class GravityColorEntry
|
||||||
|
{
|
||||||
|
public Gravity gravity;
|
||||||
|
public Color color;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class GravityHelpers
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Function which returns a gravity zero vector.
|
||||||
|
/// </summary>
|
||||||
|
private static readonly Func<Transform, Transform, Vector3> _noGravity =
|
||||||
|
new((gravitySource, target) => new Vector3());
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Function which returns a gravity vector downwards, depending
|
||||||
|
/// on the parent transforms rotation.
|
||||||
|
/// The parenting transform for a ship is the arena it's in.
|
||||||
|
/// </summary>
|
||||||
|
private static readonly Func<Transform, Transform, Vector3> _downGravity =
|
||||||
|
new((gravitySource, target) =>
|
||||||
|
gravitySource.rotation * Vector3.down);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Function which returns a gravity vector upwards, depending
|
||||||
|
/// on the parent transforms rotation.
|
||||||
|
/// The parenting transform for a ship is the arena it's in.
|
||||||
|
/// </summary>
|
||||||
|
private static readonly Func<Transform, Transform, Vector3> _upGravity =
|
||||||
|
new((gravitySource, target) =>
|
||||||
|
gravitySource.rotation * Vector3.up);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Function which returns a gravity vector towards the center of the parenting transform.
|
||||||
|
/// The parenting transform for a ship is the arena it's in.
|
||||||
|
/// </summary>
|
||||||
|
private static readonly Func<Transform, Transform, Vector3> _inwardsGravity =
|
||||||
|
new((gravitySource, target) =>
|
||||||
|
(-target.position + gravitySource.position).normalized);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Function which returns a gravity vector outwards from the center of the parenting transform.
|
||||||
|
/// The parenting transform for a ship is the arena it's in.
|
||||||
|
/// </summary>
|
||||||
|
private static readonly Func<Transform, Transform, Vector3> _outwardsGravity =
|
||||||
|
new((gravitySource, target) =>
|
||||||
|
(target.position - gravitySource.position).normalized);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets the gravity function belonging to the supplied gravity enum.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="gravity">Enum for the gravity function to get.</param>
|
||||||
|
/// <returns>A gravity function</returns>
|
||||||
|
public static Func<Transform, Transform, Vector3> GetGravityFunction(Gravity gravity)
|
||||||
|
{
|
||||||
|
switch (gravity)
|
||||||
|
{
|
||||||
|
case Gravity.DownGravity:
|
||||||
|
return _downGravity;
|
||||||
|
case Gravity.UpGravity:
|
||||||
|
return _upGravity;
|
||||||
|
case Gravity.NoGravity:
|
||||||
|
return _noGravity;
|
||||||
|
case Gravity.OutwardsGravity:
|
||||||
|
return _outwardsGravity;
|
||||||
|
case Gravity.InwardsGravity:
|
||||||
|
return _inwardsGravity;
|
||||||
|
default:
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
11
Assets/Scripts/GravityHelpers.cs.meta
Normal file
11
Assets/Scripts/GravityHelpers.cs.meta
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 52f8b1b9fd91cbe42bce23425474a53a
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@ -117,13 +117,13 @@ namespace Managers
|
|||||||
var MatchArena = MatchManager.G.MatchArena;
|
var MatchArena = MatchManager.G.MatchArena;
|
||||||
List<Player> spawned = new List<Player>();
|
List<Player> spawned = new List<Player>();
|
||||||
|
|
||||||
GameObject shipObject = Instantiate(player.character.shipPrefab);
|
GameObject shipObject = Instantiate(player.character.ShipPrefab);
|
||||||
player.spawnedCharacter = shipObject;
|
player.spawnedCharacter = shipObject;
|
||||||
shipObject.TryGetComponent(out PredictedShip ship);
|
shipObject.TryGetComponent(out PredictedShip ship);
|
||||||
ship.props = player.character;
|
ship.props = player.character;
|
||||||
ship.state = new ShipHandling.ShipState();
|
ship.state = new ShipHandling.ShipState();
|
||||||
ship.input = new ShipHandling.ShipInput();
|
ship.input = new ShipHandling.ShipInput();
|
||||||
ApplyShipColor(player.character.shipHullColor, ship.bodyMeshRenderer);
|
ApplyShipColor(player.character.ShipHullColor, ship.bodyMeshRenderer);
|
||||||
ship.cameraOperator = MatchCamera.GetComponent<CameraOperator>();
|
ship.cameraOperator = MatchCamera.GetComponent<CameraOperator>();
|
||||||
shipObject.transform.SetParent(MatchArena.transform, false);
|
shipObject.transform.SetParent(MatchArena.transform, false);
|
||||||
shipObject.transform.localPosition =
|
shipObject.transform.localPosition =
|
||||||
@ -139,8 +139,8 @@ namespace Managers
|
|||||||
|
|
||||||
public void SpawnCharacter(Player p, GameObject camera, GameObject arena)
|
public void SpawnCharacter(Player p, GameObject camera, GameObject arena)
|
||||||
{
|
{
|
||||||
Log.Debug($"Spawning ship:{p.character.shipName} for player: {p.playerName}");
|
Log.Debug($"Spawning ship:{p.character.ShipName} for player: {p.playerName}");
|
||||||
GameObject shipObject = Instantiate(p.character.shipPrefab);
|
GameObject shipObject = Instantiate(p.character.ShipPrefab);
|
||||||
Log.Debug($"Instantiated prefab");
|
Log.Debug($"Instantiated prefab");
|
||||||
p.spawnedCharacter = shipObject;
|
p.spawnedCharacter = shipObject;
|
||||||
shipObject.TryGetComponent(out Ship ship);
|
shipObject.TryGetComponent(out Ship ship);
|
||||||
@ -148,7 +148,7 @@ namespace Managers
|
|||||||
ship.State = new ShipHandling.ShipState();
|
ship.State = new ShipHandling.ShipState();
|
||||||
ship.Input = new ShipHandling.ShipInput();
|
ship.Input = new ShipHandling.ShipInput();
|
||||||
ship.CameraOperator = camera.GetComponent<CameraOperator>();
|
ship.CameraOperator = camera.GetComponent<CameraOperator>();
|
||||||
ApplyShipColor(p.character.shipHullColor, ship.BodyMeshRenderer);
|
ApplyShipColor(p.character.ShipHullColor, ship.BodyMeshRenderer);
|
||||||
Log.Debug($"Applied ships color");
|
Log.Debug($"Applied ships color");
|
||||||
shipObject.transform.SetParent(arena.transform, false);
|
shipObject.transform.SetParent(arena.transform, false);
|
||||||
shipObject.transform.localPosition =
|
shipObject.transform.localPosition =
|
||||||
|
|||||||
@ -34,9 +34,9 @@ namespace Managers
|
|||||||
playersControlSchemes?.Clear();
|
playersControlSchemes?.Clear();
|
||||||
foreach (Player p in players)
|
foreach (Player p in players)
|
||||||
{
|
{
|
||||||
if (p.character.shipInput != null)
|
if (p.character.ShipInput != null)
|
||||||
{
|
{
|
||||||
ShipInputHandler input = p.character.shipInput;
|
ShipInputHandler input = p.character.ShipInput;
|
||||||
if (p.spawnedCharacter.TryGetComponent(out Ship ship))
|
if (p.spawnedCharacter.TryGetComponent(out Ship ship))
|
||||||
{
|
{
|
||||||
input.ReActivateInput(ship);
|
input.ReActivateInput(ship);
|
||||||
@ -121,7 +121,7 @@ namespace Managers
|
|||||||
|
|
||||||
private void AssignShipControls(UniqueControl uc, ShipInput si, ShipProperties p)
|
private void AssignShipControls(UniqueControl uc, ShipInput si, ShipProperties p)
|
||||||
{
|
{
|
||||||
p.shipInput = new ShipInputHandler(si,
|
p.ShipInput = new ShipInputHandler(si,
|
||||||
InputSystem.GetDeviceById(uc.DeviceId), uc.SchemeName);
|
InputSystem.GetDeviceById(uc.DeviceId), uc.SchemeName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -145,7 +145,7 @@ namespace Managers
|
|||||||
Player updatedPlayer = null;
|
Player updatedPlayer = null;
|
||||||
foreach (Player p in PlayerManager.G.MatchPlayers)
|
foreach (Player p in PlayerManager.G.MatchPlayers)
|
||||||
{
|
{
|
||||||
if (p.character.shipName == update.Ship.Props.shipName)
|
if (p.character.ShipName == update.Ship.Props.ShipName)
|
||||||
{
|
{
|
||||||
updatedPlayer = p;
|
updatedPlayer = p;
|
||||||
Log.Debug($"Players: {p.playerName}'s match statistic will be updated.");
|
Log.Debug($"Players: {p.playerName}'s match statistic will be updated.");
|
||||||
@ -154,7 +154,7 @@ namespace Managers
|
|||||||
}
|
}
|
||||||
if (updatedPlayer == null)
|
if (updatedPlayer == null)
|
||||||
{
|
{
|
||||||
Log.Error($"Ship: {update.Ship.Props.shipName} does not belong to a player in this match."
|
Log.Error($"Ship: {update.Ship.Props.ShipName} does not belong to a player in this match."
|
||||||
+ " Can't update match.");
|
+ " Can't update match.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -448,7 +448,7 @@ namespace Managers
|
|||||||
MatchCamera.GetComponent<CameraOperator>().AddCharacter(shipGO);
|
MatchCamera.GetComponent<CameraOperator>().AddCharacter(shipGO);
|
||||||
ship.State.IsFrozen = false;
|
ship.State.IsFrozen = false;
|
||||||
|
|
||||||
ship.State.boostCapacity = ship.Props.maxBoostCapacity;
|
ship.State.boostCapacity = ship.Props.MaxBoostCapacity;
|
||||||
|
|
||||||
body.velocity = Vector3.zero;
|
body.velocity = Vector3.zero;
|
||||||
|
|
||||||
|
|||||||
@ -2,277 +2,237 @@ using System;
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using log4net;
|
using log4net;
|
||||||
using Managers;
|
|
||||||
using Unity.Mathematics;
|
using Unity.Mathematics;
|
||||||
using Unity.VisualScripting;
|
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.UIElements;
|
|
||||||
using static AffectingForcesManager;
|
using static AffectingForcesManager;
|
||||||
|
using static GravityFunctionality.GravityHelpers;
|
||||||
|
|
||||||
[ExecuteInEditMode]
|
namespace GravityFunctionality
|
||||||
public class NimbleZone : MonoBehaviour
|
|
||||||
{
|
{
|
||||||
private static ILog Log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
|
||||||
private static Transform _nimbleZoneTransform;
|
|
||||||
public AffectingForcesManager forcesManager;
|
|
||||||
|
|
||||||
public GameObject renderedZoneObject;
|
[ExecuteInEditMode]
|
||||||
|
public class NimbleZone : MonoBehaviour
|
||||||
|
{
|
||||||
|
private static ILog Log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||||
|
private static Transform _nimbleZoneTransform;
|
||||||
|
|
||||||
[SerializeField]
|
public GameObject renderedZoneObject;
|
||||||
private List<GravityColorEntry> NimbleZoneColors = new();
|
|
||||||
|
|
||||||
private Dictionary<Gravity, Color> _nimbleZoneColors =
|
[SerializeField]
|
||||||
new Dictionary<Gravity, Color>
|
private List<GravityColorEntry> NimbleZoneColors = new();
|
||||||
{
|
|
||||||
|
private Dictionary<Gravity, Color> _nimbleZoneColors =
|
||||||
|
new Dictionary<Gravity, Color>
|
||||||
|
{
|
||||||
{Gravity.DownGravity, Color.green },
|
{Gravity.DownGravity, Color.green },
|
||||||
{Gravity.UpGravity, Color.magenta },
|
{Gravity.UpGravity, Color.magenta },
|
||||||
{Gravity.NoGravity, Color.red },
|
{Gravity.NoGravity, Color.red },
|
||||||
{Gravity.InwardsGravity, Color.blue },
|
{Gravity.InwardsGravity, Color.blue },
|
||||||
{Gravity.OutwardsGravity, Color.yellow },
|
{Gravity.OutwardsGravity, Color.yellow },
|
||||||
};
|
};
|
||||||
|
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private static float gravityFactor = 30f;
|
private static float gravityFactor = 30f;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private Gravity outsideGravityFunction = Gravity.NoGravity;
|
private Gravity outsideGravityFunction = Gravity.NoGravity;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private Zone zone = Zone.NimbleZone;
|
private Zone zone = Zone.NimbleZone;
|
||||||
|
|
||||||
// Ripple properties
|
// Ripple properties
|
||||||
// These influence the shader on the nimble zone
|
// These influence the shader on the nimble zone
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private float rippleFrequency = 3f;
|
private float rippleFrequency = 3f;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private float rippleDensity = 30f;
|
private float rippleDensity = 30f;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private float rippleAmplitude = 0.1f;
|
private float rippleAmplitude = 0.1f;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private float rippleRadius = 1f;
|
private float rippleRadius = 1f;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private float rippleDuration = 1f;
|
private float rippleDuration = 1f;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private float impactVelocityModifier = 1f;
|
private float impactVelocityModifier = 1f;
|
||||||
[SerializeField, Tooltip("Minimum ripple effect intensity.")]
|
[SerializeField, Tooltip("Minimum ripple effect intensity.")]
|
||||||
[Range(0, 1)]
|
[Range(0, 1)]
|
||||||
private float minImpact = 0.2f;
|
private float minImpact = 0.2f;
|
||||||
[SerializeField, Tooltip("Velocity which makes the highest/most intense ripples.")]
|
[SerializeField, Tooltip("Velocity which makes the highest/most intense ripples.")]
|
||||||
private float maxVelocity = 45f;
|
private float maxVelocity = 45f;
|
||||||
private int maxRippleAmount = 5;
|
private AffectingForcesManager _forcesManager;
|
||||||
private MeshRenderer meshRenderer;
|
private int maxRippleAmount = 5;
|
||||||
private Material material;
|
private MeshRenderer meshRenderer;
|
||||||
|
private Material material;
|
||||||
|
|
||||||
void Awake()
|
void Awake()
|
||||||
{
|
|
||||||
foreach (GravityColorEntry entry in NimbleZoneColors)
|
|
||||||
{
|
{
|
||||||
_nimbleZoneColors[entry.gravity] = entry.color;
|
if (_forcesManager == null)
|
||||||
}
|
|
||||||
meshRenderer = renderedZoneObject.GetComponent<MeshRenderer>();
|
|
||||||
_nimbleZoneTransform = gameObject.transform;
|
|
||||||
ApplyZoneColor(meshRenderer);
|
|
||||||
|
|
||||||
#if UNITY_EDITOR
|
|
||||||
if (!Application.isPlaying) return;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
material = meshRenderer.material;
|
|
||||||
ResetRippleShaderProperties();
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Array of the available gravities.
|
|
||||||
/// </summary>
|
|
||||||
private Func<Transform, Transform, Vector3>[] gravityFunctions =
|
|
||||||
{ DownGravity, UpGravity, NoGravity, InwardsGravity, OutwardsGravity };
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity zero vector.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> NoGravity =
|
|
||||||
new((gravitySource, target) => new Vector3());
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector downwards, depending
|
|
||||||
/// on the parent transforms rotation.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> DownGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
gravitySource.rotation * Vector3.down * gravityFactor);
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector upwards, depending
|
|
||||||
/// on the parent transforms rotation.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> UpGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
gravitySource.rotation * Vector3.up * gravityFactor);
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector towards the center of the parenting transform.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> InwardsGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
(target.position - gravitySource.position).normalized * -gravityFactor);
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Function which returns a gravity vector outwards from the center of the parenting transform.
|
|
||||||
/// The parenting transform for a ship is the arena it's in.
|
|
||||||
/// </summary>
|
|
||||||
private static readonly Func<Transform, Transform, Vector3> OutwardsGravity =
|
|
||||||
new((gravitySource, target) =>
|
|
||||||
(target.position - gravitySource.position).normalized * gravityFactor);
|
|
||||||
|
|
||||||
public Func<Transform, Transform, Vector3> GetGravityFunction(Gravity gravity)
|
|
||||||
{
|
|
||||||
return gravityFunctions[(int)gravity];
|
|
||||||
}
|
|
||||||
|
|
||||||
private void OnTriggerEnter(Collider collider)
|
|
||||||
{
|
|
||||||
int instanceID = collider.gameObject.GetInstanceID();
|
|
||||||
if (collider.tag == "Spike"
|
|
||||||
&& collider.attachedRigidbody.velocity.magnitude > 1)
|
|
||||||
{
|
|
||||||
SpawnRipple(collider, false);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (collider.tag == "Ship")
|
|
||||||
{
|
|
||||||
forcesManager.SetGravityForInstance(instanceID, NoGravity, transform);
|
|
||||||
forcesManager.SetZoneForInstance(instanceID, zone);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private void OnTriggerExit(Collider collider)
|
|
||||||
{
|
|
||||||
int instanceID = collider.gameObject.GetInstanceID();
|
|
||||||
if (collider.tag == "Spike")
|
|
||||||
{
|
|
||||||
SpawnRipple(collider, true);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (collider.tag == "Ship")
|
|
||||||
{
|
|
||||||
forcesManager.SetGravityForInstance(instanceID,
|
|
||||||
GetGravityFunction(outsideGravityFunction), transform);
|
|
||||||
forcesManager.SetZoneForInstance(instanceID, Zone.OutsideZone);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private void Update()
|
|
||||||
{
|
|
||||||
#if UNITY_EDITOR
|
|
||||||
if (!Application.isPlaying) return;
|
|
||||||
#endif
|
|
||||||
material.SetFloat("_ShaderTime", Time.timeSinceLevelLoad);
|
|
||||||
}
|
|
||||||
|
|
||||||
private void ApplyZoneColor(MeshRenderer renderer)
|
|
||||||
{
|
|
||||||
Color color = _nimbleZoneColors[outsideGravityFunction];
|
|
||||||
MaterialPropertyBlock materialPropertyBlock = new();
|
|
||||||
materialPropertyBlock.SetColor("_BaseColor", color);
|
|
||||||
renderer.SetPropertyBlock(materialPropertyBlock);
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Calculates the effect which a given velocity has on a ripple property.
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="duration">Initial value of the ripple property</param>
|
|
||||||
/// <param name="velocity">Velocity of the impact</param>
|
|
||||||
/// <returns></returns>
|
|
||||||
private float ImpactVelocityEffect(float initial, float velocity)
|
|
||||||
{
|
|
||||||
return math.max(math.smoothstep(0, maxVelocity, velocity), minImpact)
|
|
||||||
* impactVelocityModifier * initial;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Spawns ripples on the shader of the nimble zone.
|
|
||||||
/// Up to 5 parallel ripples.
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="collider"></param>
|
|
||||||
/// <param name="isOutwardsRipple"></param>
|
|
||||||
private void SpawnRipple(Collider collider, bool isOutwardsRipple)
|
|
||||||
{
|
|
||||||
Rigidbody body = collider.attachedRigidbody;
|
|
||||||
GameObject gameObject = collider.gameObject;
|
|
||||||
|
|
||||||
float velocity = body.velocity.magnitude;
|
|
||||||
Vector3 position = gameObject.transform.position - transform.position;
|
|
||||||
position = transform.InverseTransformDirection(position).normalized;
|
|
||||||
|
|
||||||
Vector4[] rippleOrigins = material.GetVectorArray("_RippleOrigins");
|
|
||||||
|
|
||||||
float currentTime = Time.timeSinceLevelLoad;
|
|
||||||
float[] startedTimes = material.GetFloatArray("_RippleStartTimes");
|
|
||||||
float[] startedRippleDurations = material.GetFloatArray("_RippleDurations");
|
|
||||||
|
|
||||||
float[] rippleAmplitudes = material.GetFloatArray("_RippleAmplitudes");
|
|
||||||
float[] rippleFrequencies = material.GetFloatArray("_RippleFrequencies");
|
|
||||||
float[] rippleDensities = material.GetFloatArray("_RippleDensities");
|
|
||||||
float[] rippleRadii = material.GetFloatArray("_RippleRadii");
|
|
||||||
|
|
||||||
if (startedTimes == null)
|
|
||||||
{
|
|
||||||
Log.Warn("Ripple shader properties are null. Reseting shader");
|
|
||||||
ResetRippleShaderProperties();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (int i = 0; i < startedTimes.Length; ++i)
|
|
||||||
{
|
|
||||||
if (startedTimes[i] + startedRippleDurations[i] < currentTime)
|
|
||||||
{
|
{
|
||||||
rippleOrigins[i] = new Vector4(position.x, position.y, position.z, 0);
|
_forcesManager = GameObject.FindGameObjectWithTag("ForceManager").
|
||||||
material.SetVectorArray("_RippleOrigins", rippleOrigins);
|
GetComponent<AffectingForcesManager>();
|
||||||
startedTimes[i] = currentTime;
|
}
|
||||||
material.SetFloatArray("_RippleStartTimes", startedTimes);
|
foreach (GravityColorEntry entry in NimbleZoneColors)
|
||||||
|
{
|
||||||
|
_nimbleZoneColors[entry.gravity] = entry.color;
|
||||||
|
}
|
||||||
|
meshRenderer = renderedZoneObject.GetComponent<MeshRenderer>();
|
||||||
|
_nimbleZoneTransform = gameObject.transform;
|
||||||
|
ApplyZoneColor(meshRenderer);
|
||||||
|
|
||||||
float amplitude = isOutwardsRipple ? rippleAmplitude : -rippleAmplitude;
|
#if UNITY_EDITOR
|
||||||
|
if (!Application.isPlaying) return;
|
||||||
|
#endif
|
||||||
|
|
||||||
rippleAmplitudes[i] = ImpactVelocityEffect(amplitude, velocity);
|
material = meshRenderer.material;
|
||||||
rippleFrequencies[i] = ImpactVelocityEffect(rippleFrequency, velocity);
|
ResetRippleShaderProperties();
|
||||||
rippleDensities[i] = ImpactVelocityEffect(rippleDensity, velocity);
|
}
|
||||||
startedRippleDurations[i] = ImpactVelocityEffect(rippleDuration, velocity);
|
|
||||||
rippleRadii[i] = ImpactVelocityEffect(rippleRadius, velocity);
|
private void OnTriggerEnter(Collider collider)
|
||||||
material.SetFloatArray("_RippleAmplitudes", rippleAmplitudes);
|
{
|
||||||
material.SetFloatArray("_RippleFrequencies", rippleFrequencies);
|
int instanceID = collider.gameObject.GetInstanceID();
|
||||||
material.SetFloatArray("_RippleDensities", rippleDensities);
|
if (collider.tag == "Spike"
|
||||||
material.SetFloatArray("_RippleAmplitudes", rippleAmplitudes);
|
&& collider.attachedRigidbody.velocity.magnitude > 1)
|
||||||
material.SetFloatArray("_RippleDurations", startedRippleDurations);
|
{
|
||||||
material.SetFloatArray("_RippleRadii", rippleRadii);
|
SpawnRipple(collider, false);
|
||||||
break;
|
return;
|
||||||
|
}
|
||||||
|
if (collider.tag == "Ship")
|
||||||
|
{
|
||||||
|
var func = GetGravityFunction(Gravity.NoGravity);
|
||||||
|
_forcesManager.SetGravityForInstance(instanceID, func, transform);
|
||||||
|
_forcesManager.SetZoneForInstance(instanceID, zone);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnTriggerExit(Collider collider)
|
||||||
|
{
|
||||||
|
int instanceID = collider.gameObject.GetInstanceID();
|
||||||
|
if (collider.tag == "Spike")
|
||||||
|
{
|
||||||
|
SpawnRipple(collider, true);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (collider.tag == "Ship")
|
||||||
|
{
|
||||||
|
var func = GetGravityFunction(outsideGravityFunction);
|
||||||
|
_forcesManager.SetGravityForInstance(instanceID, func, transform);
|
||||||
|
_forcesManager.SetZoneForInstance(instanceID, Zone.OutsideZone);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Update()
|
||||||
|
{
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
if (!Application.isPlaying) return;
|
||||||
|
#endif
|
||||||
|
material.SetFloat("_ShaderTime", Time.timeSinceLevelLoad);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ApplyZoneColor(MeshRenderer renderer)
|
||||||
|
{
|
||||||
|
Color color = _nimbleZoneColors[outsideGravityFunction];
|
||||||
|
MaterialPropertyBlock materialPropertyBlock = new();
|
||||||
|
materialPropertyBlock.SetColor("_BaseColor", color);
|
||||||
|
renderer.SetPropertyBlock(materialPropertyBlock);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region RippleShader
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Calculates the effect which a given velocity has on a ripple property.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="duration">Initial value of the ripple property</param>
|
||||||
|
/// <param name="velocity">Velocity of the impact</param>
|
||||||
|
/// <returns></returns>
|
||||||
|
private float ImpactVelocityEffect(float initial, float velocity)
|
||||||
|
{
|
||||||
|
return math.max(math.smoothstep(0, maxVelocity, velocity), minImpact)
|
||||||
|
* impactVelocityModifier * initial;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Spawns ripples on the shader of the nimble zone.
|
||||||
|
/// Up to 5 parallel ripples.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="collider"></param>
|
||||||
|
/// <param name="isOutwardsRipple"></param>
|
||||||
|
private void SpawnRipple(Collider collider, bool isOutwardsRipple)
|
||||||
|
{
|
||||||
|
Rigidbody body = collider.attachedRigidbody;
|
||||||
|
GameObject gameObject = collider.gameObject;
|
||||||
|
|
||||||
|
float velocity = body.velocity.magnitude;
|
||||||
|
Vector3 position = gameObject.transform.position - transform.position;
|
||||||
|
position = transform.InverseTransformDirection(position).normalized;
|
||||||
|
|
||||||
|
Vector4[] rippleOrigins = material.GetVectorArray("_RippleOrigins");
|
||||||
|
|
||||||
|
float currentTime = Time.timeSinceLevelLoad;
|
||||||
|
float[] startedTimes = material.GetFloatArray("_RippleStartTimes");
|
||||||
|
float[] startedRippleDurations = material.GetFloatArray("_RippleDurations");
|
||||||
|
|
||||||
|
float[] rippleAmplitudes = material.GetFloatArray("_RippleAmplitudes");
|
||||||
|
float[] rippleFrequencies = material.GetFloatArray("_RippleFrequencies");
|
||||||
|
float[] rippleDensities = material.GetFloatArray("_RippleDensities");
|
||||||
|
float[] rippleRadii = material.GetFloatArray("_RippleRadii");
|
||||||
|
|
||||||
|
if (startedTimes == null)
|
||||||
|
{
|
||||||
|
Log.Warn("Ripple shader properties are null. Reseting shader");
|
||||||
|
ResetRippleShaderProperties();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for (int i = 0; i < startedTimes.Length; ++i)
|
||||||
|
{
|
||||||
|
if (startedTimes[i] + startedRippleDurations[i] < currentTime)
|
||||||
|
{
|
||||||
|
rippleOrigins[i] = new Vector4(position.x, position.y, position.z, 0);
|
||||||
|
material.SetVectorArray("_RippleOrigins", rippleOrigins);
|
||||||
|
startedTimes[i] = currentTime;
|
||||||
|
material.SetFloatArray("_RippleStartTimes", startedTimes);
|
||||||
|
|
||||||
|
float amplitude = isOutwardsRipple ? rippleAmplitude : -rippleAmplitude;
|
||||||
|
|
||||||
|
rippleAmplitudes[i] = ImpactVelocityEffect(amplitude, velocity);
|
||||||
|
rippleFrequencies[i] = ImpactVelocityEffect(rippleFrequency, velocity);
|
||||||
|
rippleDensities[i] = ImpactVelocityEffect(rippleDensity, velocity);
|
||||||
|
startedRippleDurations[i] = ImpactVelocityEffect(rippleDuration, velocity);
|
||||||
|
rippleRadii[i] = ImpactVelocityEffect(rippleRadius, velocity);
|
||||||
|
material.SetFloatArray("_RippleAmplitudes", rippleAmplitudes);
|
||||||
|
material.SetFloatArray("_RippleFrequencies", rippleFrequencies);
|
||||||
|
material.SetFloatArray("_RippleDensities", rippleDensities);
|
||||||
|
material.SetFloatArray("_RippleAmplitudes", rippleAmplitudes);
|
||||||
|
material.SetFloatArray("_RippleDurations", startedRippleDurations);
|
||||||
|
material.SetFloatArray("_RippleRadii", rippleRadii);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Resets the ripple shaders exposed properties to 0
|
||||||
|
/// </summary>
|
||||||
|
private void ResetRippleShaderProperties()
|
||||||
|
{
|
||||||
|
Vector4[] rippleOrigins = new Vector4[maxRippleAmount];
|
||||||
|
float[] startedTimes = new float[maxRippleAmount];
|
||||||
|
float[] rippleAmplitudes = new float[maxRippleAmount];
|
||||||
|
float[] rippleFrequencies = new float[maxRippleAmount];
|
||||||
|
float[] rippleDensities = new float[maxRippleAmount];
|
||||||
|
float[] rippleDurations = new float[maxRippleAmount];
|
||||||
|
float[] rippleRadii = new float[maxRippleAmount];
|
||||||
|
|
||||||
|
// Initialize Ripple Shader Properties
|
||||||
|
material.SetVectorArray("_RippleOrigins", rippleOrigins);
|
||||||
|
material.SetFloatArray("_RippleStartTimes", startedTimes);
|
||||||
|
material.SetFloatArray("_RippleAmplitudes", rippleAmplitudes);
|
||||||
|
material.SetFloatArray("_RippleFrequencies", rippleFrequencies);
|
||||||
|
material.SetFloatArray("_RippleDensities", rippleDensities);
|
||||||
|
material.SetFloatArray("_RippleDurations", rippleDurations);
|
||||||
|
material.SetFloatArray("_RippleRadii", rippleRadii);
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Resets the ripple shaders exposed properties to 0
|
|
||||||
/// </summary>
|
|
||||||
private void ResetRippleShaderProperties()
|
|
||||||
{
|
|
||||||
Vector4[] rippleOrigins = new Vector4[maxRippleAmount];
|
|
||||||
float[] startedTimes = new float[maxRippleAmount];
|
|
||||||
float[] rippleAmplitudes = new float[maxRippleAmount];
|
|
||||||
float[] rippleFrequencies = new float[maxRippleAmount];
|
|
||||||
float[] rippleDensities = new float[maxRippleAmount];
|
|
||||||
float[] rippleDurations = new float[maxRippleAmount];
|
|
||||||
float[] rippleRadii = new float[maxRippleAmount];
|
|
||||||
|
|
||||||
// Initialize Ripple Shader Properties
|
|
||||||
material.SetVectorArray("_RippleOrigins", rippleOrigins);
|
|
||||||
material.SetFloatArray("_RippleStartTimes", startedTimes);
|
|
||||||
material.SetFloatArray("_RippleAmplitudes", rippleAmplitudes);
|
|
||||||
material.SetFloatArray("_RippleFrequencies", rippleFrequencies);
|
|
||||||
material.SetFloatArray("_RippleDensities", rippleDensities);
|
|
||||||
material.SetFloatArray("_RippleDurations", rippleDurations);
|
|
||||||
material.SetFloatArray("_RippleRadii", rippleRadii);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -25,7 +25,7 @@ public class BoostCapacityUI : MonoBehaviour
|
|||||||
|
|
||||||
public void SetPlayerName(Player p)
|
public void SetPlayerName(Player p)
|
||||||
{
|
{
|
||||||
hint.SetText($"{p.playerName}\n{p.character.shipName}");
|
hint.SetText($"{p.playerName}\n{p.character.ShipName}");
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetIsOut(Player p)
|
public void SetIsOut(Player p)
|
||||||
|
|||||||
@ -10,6 +10,7 @@
|
|||||||
"com.unity.feature.development": "1.0.1",
|
"com.unity.feature.development": "1.0.1",
|
||||||
"com.unity.ide.visualstudio": "2.0.22",
|
"com.unity.ide.visualstudio": "2.0.22",
|
||||||
"com.unity.inputsystem": "1.7.0",
|
"com.unity.inputsystem": "1.7.0",
|
||||||
|
"com.unity.nuget.newtonsoft-json": "3.2.1",
|
||||||
"com.unity.postprocessing": "3.4.0",
|
"com.unity.postprocessing": "3.4.0",
|
||||||
"com.unity.render-pipelines.universal": "14.0.10",
|
"com.unity.render-pipelines.universal": "14.0.10",
|
||||||
"com.unity.textmeshpro": "3.0.8",
|
"com.unity.textmeshpro": "3.0.8",
|
||||||
|
|||||||
@ -136,6 +136,13 @@
|
|||||||
"dependencies": {},
|
"dependencies": {},
|
||||||
"url": "https://packages.unity.com"
|
"url": "https://packages.unity.com"
|
||||||
},
|
},
|
||||||
|
"com.unity.nuget.newtonsoft-json": {
|
||||||
|
"version": "3.2.1",
|
||||||
|
"depth": 0,
|
||||||
|
"source": "registry",
|
||||||
|
"dependencies": {},
|
||||||
|
"url": "https://packages.unity.com"
|
||||||
|
},
|
||||||
"com.unity.performance.profile-analyzer": {
|
"com.unity.performance.profile-analyzer": {
|
||||||
"version": "1.2.2",
|
"version": "1.2.2",
|
||||||
"depth": 1,
|
"depth": 1,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user