地图修改

This commit is contained in:
2025-12-15 12:30:59 +08:00
parent 7775fa30bb
commit afb4f0d765
22 changed files with 52391 additions and 51666 deletions

BIN
Assets/New Terrain 11.asset Normal file

Binary file not shown.

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: f6405d25840bc7647bc799163e0237fd
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 15600000
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

621
Assets/Scenes/Test.unity Normal file
View File

@@ -0,0 +1,621 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!29 &1
OcclusionCullingSettings:
m_ObjectHideFlags: 0
serializedVersion: 2
m_OcclusionBakeSettings:
smallestOccluder: 5
smallestHole: 0.25
backfaceThreshold: 100
m_SceneGUID: 00000000000000000000000000000000
m_OcclusionCullingData: {fileID: 0}
--- !u!104 &2
RenderSettings:
m_ObjectHideFlags: 0
serializedVersion: 10
m_Fog: 0
m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
m_FogMode: 3
m_FogDensity: 0.01
m_LinearFogStart: 0
m_LinearFogEnd: 300
m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
m_AmbientIntensity: 1
m_AmbientMode: 0
m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0}
m_HaloStrength: 0.5
m_FlareStrength: 1
m_FlareFadeSpeed: 3
m_HaloTexture: {fileID: 0}
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
m_DefaultReflectionMode: 0
m_DefaultReflectionResolution: 128
m_ReflectionBounces: 1
m_ReflectionIntensity: 1
m_CustomReflection: {fileID: 0}
m_Sun: {fileID: 0}
m_UseRadianceAmbientProbe: 0
--- !u!157 &3
LightmapSettings:
m_ObjectHideFlags: 0
serializedVersion: 13
m_BakeOnSceneLoad: 0
m_GISettings:
serializedVersion: 2
m_BounceScale: 1
m_IndirectOutputScale: 1
m_AlbedoBoost: 1
m_EnvironmentLightingMode: 0
m_EnableBakedLightmaps: 1
m_EnableRealtimeLightmaps: 0
m_LightmapEditorSettings:
serializedVersion: 12
m_Resolution: 2
m_BakeResolution: 40
m_AtlasSize: 1024
m_AO: 0
m_AOMaxDistance: 1
m_CompAOExponent: 1
m_CompAOExponentDirect: 0
m_ExtractAmbientOcclusion: 0
m_Padding: 2
m_LightmapParameters: {fileID: 0}
m_LightmapsBakeMode: 1
m_TextureCompression: 1
m_ReflectionCompression: 2
m_MixedBakeMode: 2
m_BakeBackend: 1
m_PVRSampling: 1
m_PVRDirectSampleCount: 32
m_PVRSampleCount: 512
m_PVRBounces: 2
m_PVREnvironmentSampleCount: 256
m_PVREnvironmentReferencePointCount: 2048
m_PVRFilteringMode: 1
m_PVRDenoiserTypeDirect: 1
m_PVRDenoiserTypeIndirect: 1
m_PVRDenoiserTypeAO: 1
m_PVRFilterTypeDirect: 0
m_PVRFilterTypeIndirect: 0
m_PVRFilterTypeAO: 0
m_PVREnvironmentMIS: 1
m_PVRCulling: 1
m_PVRFilteringGaussRadiusDirect: 1
m_PVRFilteringGaussRadiusIndirect: 5
m_PVRFilteringGaussRadiusAO: 2
m_PVRFilteringAtrousPositionSigmaDirect: 0.5
m_PVRFilteringAtrousPositionSigmaIndirect: 2
m_PVRFilteringAtrousPositionSigmaAO: 1
m_ExportTrainingData: 0
m_TrainingDataDestination: TrainingData
m_LightProbeSampleCountMultiplier: 4
m_LightingDataAsset: {fileID: 20201, guid: 0000000000000000f000000000000000, type: 0}
m_LightingSettings: {fileID: 0}
--- !u!196 &4
NavMeshSettings:
serializedVersion: 2
m_ObjectHideFlags: 0
m_BuildSettings:
serializedVersion: 3
agentTypeID: 0
agentRadius: 0.5
agentHeight: 2
agentSlope: 45
agentClimb: 0.4
ledgeDropHeight: 0
maxJumpAcrossDistance: 0
minRegionArea: 2
manualCellSize: 0
cellSize: 0.16666667
manualTileSize: 0
tileSize: 256
buildHeightMesh: 0
maxJobWorkers: 0
preserveTilesOutsideBounds: 0
debug:
m_Flags: 0
m_NavMeshData: {fileID: 0}
--- !u!1 &203844586
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 203844589}
- component: {fileID: 203844588}
- component: {fileID: 203844587}
m_Layer: 0
m_Name: Directional Light
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!114 &203844587
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 203844586}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 474bcb49853aa07438625e644c072ee6, type: 3}
m_Name:
m_EditorClassIdentifier:
m_UsePipelineSettings: 1
m_AdditionalLightsShadowResolutionTier: 2
m_CustomShadowLayers: 0
m_LightCookieSize: {x: 1, y: 1}
m_LightCookieOffset: {x: 0, y: 0}
m_SoftShadowQuality: 0
m_RenderingLayersMask:
serializedVersion: 0
m_Bits: 1
m_ShadowRenderingLayersMask:
serializedVersion: 0
m_Bits: 1
m_Version: 4
m_LightLayerMask: 1
m_ShadowLayerMask: 1
m_RenderingLayers: 1
m_ShadowRenderingLayers: 1
--- !u!108 &203844588
Light:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 203844586}
m_Enabled: 1
serializedVersion: 11
m_Type: 1
m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1}
m_Intensity: 1
m_Range: 10
m_SpotAngle: 30
m_InnerSpotAngle: 21.80208
m_CookieSize: 10
m_Shadows:
m_Type: 2
m_Resolution: -1
m_CustomResolution: -1
m_Strength: 1
m_Bias: 0.05
m_NormalBias: 0.4
m_NearPlane: 0.2
m_CullingMatrixOverride:
e00: 1
e01: 0
e02: 0
e03: 0
e10: 0
e11: 1
e12: 0
e13: 0
e20: 0
e21: 0
e22: 1
e23: 0
e30: 0
e31: 0
e32: 0
e33: 1
m_UseCullingMatrixOverride: 0
m_Cookie: {fileID: 0}
m_DrawHalo: 0
m_Flare: {fileID: 0}
m_RenderMode: 0
m_CullingMask:
serializedVersion: 2
m_Bits: 4294967295
m_RenderingLayerMask: 1
m_Lightmapping: 4
m_LightShadowCasterMode: 0
m_AreaSize: {x: 1, y: 1}
m_BounceIntensity: 1
m_ColorTemperature: 6570
m_UseColorTemperature: 0
m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0}
m_UseBoundingSphereOverride: 0
m_UseViewFrustumForShadowCasterCull: 1
m_ForceVisible: 0
m_ShadowRadius: 0
m_ShadowAngle: 0
m_LightUnit: 1
m_LuxAtDistance: 1
m_EnableSpotReflector: 1
--- !u!4 &203844589
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 203844586}
serializedVersion: 2
m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261}
m_LocalPosition: {x: 0, y: 3, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0}
--- !u!1001 &408076628
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1020630824}
m_Modifications:
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalPosition.x
value: 0.22866821
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalPosition.z
value: -0.04827881
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalRotation.x
value: -0
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalRotation.y
value: -0
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalRotation.z
value: -0
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1127680710956633387, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: m_Name
value: Human_Male
objectReference: {fileID: 0}
- target: {fileID: 4810300765004469523, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: finalScaleReference
value: 0.9072808
objectReference: {fileID: 0}
- target: {fileID: 4810300765004469523, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
propertyPath: _Editor_OnValidateTrigger
value: 0
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
--- !u!1 &731189379
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 731189382}
- component: {fileID: 731189381}
- component: {fileID: 731189380}
m_Layer: 0
m_Name: Terrain
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 2147483647
m_IsActive: 1
--- !u!154 &731189380
TerrainCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 731189379}
m_Material: {fileID: 0}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 0
m_LayerOverridePriority: 0
m_ProvidesContacts: 0
m_Enabled: 1
serializedVersion: 2
m_TerrainData: {fileID: 15600000, guid: f6405d25840bc7647bc799163e0237fd, type: 2}
m_EnableTreeColliders: 1
--- !u!218 &731189381
Terrain:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 731189379}
m_Enabled: 1
serializedVersion: 6
m_TerrainData: {fileID: 15600000, guid: f6405d25840bc7647bc799163e0237fd, type: 2}
m_TreeDistance: 5000
m_TreeBillboardDistance: 50
m_TreeCrossFadeLength: 5
m_TreeMaximumFullLODCount: 50
m_DetailObjectDistance: 80
m_DetailObjectDensity: 1
m_HeightmapPixelError: 5
m_SplatMapDistance: 1000
m_HeightmapMinimumLODSimplification: 0
m_HeightmapMaximumLOD: 0
m_ShadowCastingMode: 2
m_DrawHeightmap: 1
m_DrawInstanced: 0
m_DrawTreesAndFoliage: 1
m_StaticShadowCaster: 0
m_IgnoreQualitySettings: 0
m_ReflectionProbeUsage: 1
m_MaterialTemplate: {fileID: 2100000, guid: 594ea882c5a793440b60ff72d896021e, type: 2}
m_BakeLightProbesForTrees: 1
m_PreserveTreePrototypeLayers: 0
m_DeringLightProbesForTrees: 1
m_ReceiveGI: 1
m_ScaleInLightmap: 0.0256
m_LightmapParameters: {fileID: 15203, guid: 0000000000000000f000000000000000, type: 0}
m_GroupingID: 0
m_RenderingLayerMask: 1
m_AllowAutoConnect: 1
m_EnableHeightmapRayTracing: 1
m_EnableTreesAndDetailsRayTracing: 0
m_TreeMotionVectorModeOverride: 3
--- !u!4 &731189382
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 731189379}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &961739749
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 961739753}
- component: {fileID: 961739752}
- component: {fileID: 961739751}
- component: {fileID: 961739750}
m_Layer: 0
m_Name: Main Camera
m_TagString: MainCamera
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!114 &961739750
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 961739749}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a79441f348de89743a2939f4d699eac1, type: 3}
m_Name:
m_EditorClassIdentifier:
m_RenderShadows: 1
m_RequiresDepthTextureOption: 2
m_RequiresOpaqueTextureOption: 2
m_CameraType: 0
m_Cameras: []
m_RendererIndex: -1
m_VolumeLayerMask:
serializedVersion: 2
m_Bits: 1
m_VolumeTrigger: {fileID: 0}
m_VolumeFrameworkUpdateModeOption: 2
m_RenderPostProcessing: 0
m_Antialiasing: 0
m_AntialiasingQuality: 2
m_StopNaN: 0
m_Dithering: 0
m_ClearDepth: 1
m_AllowXRRendering: 1
m_AllowHDROutput: 1
m_UseScreenCoordOverride: 0
m_ScreenSizeOverride: {x: 0, y: 0, z: 0, w: 0}
m_ScreenCoordScaleBias: {x: 0, y: 0, z: 0, w: 0}
m_RequiresDepthTexture: 0
m_RequiresColorTexture: 0
m_TaaSettings:
m_Quality: 3
m_FrameInfluence: 0.1
m_JitterScale: 1
m_MipBias: 0
m_VarianceClampScale: 0.9
m_ContrastAdaptiveSharpening: 0
m_Version: 2
--- !u!81 &961739751
AudioListener:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 961739749}
m_Enabled: 1
--- !u!20 &961739752
Camera:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 961739749}
m_Enabled: 1
serializedVersion: 2
m_ClearFlags: 1
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0}
m_projectionMatrixMode: 1
m_GateFitMode: 2
m_FOVAxisMode: 0
m_Iso: 200
m_ShutterSpeed: 0.005
m_Aperture: 16
m_FocusDistance: 10
m_FocalLength: 50
m_BladeCount: 5
m_Curvature: {x: 2, y: 11}
m_BarrelClipping: 0.25
m_Anamorphism: 0
m_SensorSize: {x: 36, y: 24}
m_LensShift: {x: 0, y: 0}
m_NormalizedViewPortRect:
serializedVersion: 2
x: 0
y: 0
width: 1
height: 1
near clip plane: 0.3
far clip plane: 1000
field of view: 60
orthographic: 0
orthographic size: 5
m_Depth: -1
m_CullingMask:
serializedVersion: 2
m_Bits: 4294967295
m_RenderingPath: -1
m_TargetTexture: {fileID: 0}
m_TargetDisplay: 0
m_TargetEye: 3
m_HDR: 1
m_AllowMSAA: 1
m_AllowDynamicResolution: 0
m_ForceIntoRT: 0
m_OcclusionCulling: 1
m_StereoConvergence: 10
m_StereoSeparation: 0.022
--- !u!4 &961739753
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 961739749}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 1, z: -10}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &1020630824 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 8695154010886802211, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
m_PrefabInstance: {fileID: 1526663330}
m_PrefabAsset: {fileID: 0}
--- !u!4 &1273533587 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 355084039068129169, guid: 0893171cfcdca8943a3322a9a261c693, type: 3}
m_PrefabInstance: {fileID: 408076628}
m_PrefabAsset: {fileID: 0}
--- !u!1001 &1526663330
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalPosition.x
value: 483.9309
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalPosition.y
value: -0
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalPosition.z
value: 421.3181
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2216216690891386863, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8172838236951268422, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
propertyPath: m_Name
value: Player
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects:
- targetCorrespondingSourceObject: {fileID: 8695154010886802211, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
insertIndex: -1
addedObject: {fileID: 1273533587}
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 7917dd17f69770c4aa92841af853861f, type: 3}
--- !u!1660057539 &9223372036854775807
SceneRoots:
m_ObjectHideFlags: 0
m_Roots:
- {fileID: 961739753}
- {fileID: 203844589}
- {fileID: 731189382}
- {fileID: 1526663330}

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: d6d2fd308592b2b44ba186f74ac4b605
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 1c61b32e7992466f9771eac80763078e
timeCreated: 1765523393

View File

@@ -0,0 +1,7 @@
namespace NBF.Fishing2
{
public struct UseGearEvent
{
public UnitGearComponent Gear;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 6172898013ee4551afc0686399136d8f
timeCreated: 1765523056

View File

@@ -17,10 +17,15 @@ namespace NBF.Fishing2
/// 旋转速度
/// </summary>
public float ReelSpeed { get; set; }
/// <summary>
/// 鱼竿设置
/// </summary>
public int RedSetting { get; set; }
/// <summary>
/// 是否拿在手里
/// </summary>
public bool InHand { get; set; }
}
}

View File

@@ -86,6 +86,7 @@ namespace NBF.Fishing2
var unitBasic = GetOrAddComponent<MapUnitBasic>();
unitBasic.UpdateInfo(unitInfo);
// unitInfo.Gears
var numericComponent = GetOrAddComponent<NumericComponent>();
foreach (var kv in unitInfo.Propertys)

View File

@@ -136,23 +136,33 @@ namespace NBF.Fishing2
Quaternion rotation = _Character.transform.rotation;
float num = Quaternion.Angle(rotation, lastRotation);
// float num2 = Vector3.Cross(lastRotation * Vector3.forward, rotation * Vector3.forward).y > 0f
// ? 1f
// : -1f;
bool flag = num > 0f;
if (!flag)
// 计算当前帧与上一帧的旋转差异
Quaternion rotationDelta = rotation * Quaternion.Inverse(lastRotation);
// 将四元数转换为角度轴表示
rotationDelta.ToAngleAxis(out float angle, out Vector3 axis);
// 确保角度在0-360范围内
if (angle > 180f) angle -= 360f;
// 获取Y轴旋转分量归一化处理
float yRotation = 0f;
if (Mathf.Abs(angle) > 0.001f && Mathf.Abs(axis.y) > 0.1f)
{
MapUnit.RotationSpeed = Mathf.Lerp(MapUnit.RotationSpeed, 0f, 5 * Time.deltaTime);
// 计算Y轴方向的旋转角度考虑旋转轴方向
yRotation = angle * Mathf.Sign(axis.y);
}
float maxTurnSpeed = 180f; // 度/秒
// 转换为角速度并归一化到[-1, 1]
float angularSpeed = yRotation / Time.deltaTime;
float turnValue = Mathf.Clamp(angularSpeed / maxTurnSpeed, -1f, 1f);
MapUnit.RotationSpeed = turnValue;
lastRotation = rotation;
// var TargetMultiplier = 15;
// float num3 = MapUnit.RotationSpeed < 1f ? TargetMultiplier * 5f : TargetMultiplier;
// MapUnit.RotationSpeed += (flag ? 1f : 0f) * num2 * Time.deltaTime *
// (Run ? num3 * 0.075f : num3);
}
private void UpdateWater()

View File

@@ -1,5 +1,6 @@
using Fantasy.Entitas;
using Fantasy.Entitas.Interface;
using NBC;
using UnityEngine;
namespace NBF.Fishing2
@@ -34,11 +35,16 @@ namespace NBF.Fishing2
public static readonly int PreciseIdle = Animator.StringToHash("Precise Idle");
public static readonly string Torso = "Torso";
#endregion
public Animator Animator { get; private set; }
public MapUnit MapUnit;
private bool _isTorsoLayerEnabled;
#region System
public class CharacterAnimatorComponentDestroySystem : DestroySystem<CharacterAnimatorComponent>
@@ -58,9 +64,17 @@ namespace NBF.Fishing2
}
}
public class CharacterAnimatorComponentUpdateSystem : UpdateSystem<CharacterAnimatorComponent>
// public class CharacterAnimatorComponentUpdateSystem : UpdateSystem<CharacterAnimatorComponent>
// {
// protected override void Update(CharacterAnimatorComponent self)
// {
// // self.UpdateAnimator();
// }
// }
public class CharacterAnimatorComponentLateUpdateSystem : LateUpdateSystem<CharacterAnimatorComponent>
{
protected override void Update(CharacterAnimatorComponent self)
protected override void LateUpdate(CharacterAnimatorComponent self)
{
self.UpdateAnimator();
}
@@ -74,8 +88,26 @@ namespace NBF.Fishing2
Animator.SetBool(OnGround, MapUnit.IsGrounded);
float value3 = Mathf.Lerp(Animator.GetFloat(Forward), MapUnit.Speed / 5f, Time.deltaTime * 20f);
Animator.SetFloat(Forward, value3);
float value4 = Mathf.Lerp(Animator.GetFloat(Turn), MapUnit.RotationSpeed, Time.deltaTime * 15f);
Animator.SetFloat(Turn, Mathf.Clamp(value4, -1f, 1f));
// 平滑处理
// float smoothedTurn = Mathf.SmoothDamp(Animator.GetFloat(Turn),
// MapUnit.RotationSpeed,
// ref turnSmoothVelocity,
// smoothingTime
// );
float smoothedTurn = Mathf.Lerp(Animator.GetFloat(Turn), MapUnit.RotationSpeed, Time.deltaTime * 10f);
Animator.SetFloat(Turn, smoothedTurn);
float layerWeight = Animator.GetLayerWeight(Animator.GetLayerIndex(Torso));
SetLayerWeight(Torso,
Mathf.MoveTowards(layerWeight, _isTorsoLayerEnabled ? 1f : 0f, Time.deltaTime * 3f));
}
public void SetLayerWeight(string layer, float weight)
{
Animator.SetLayerWeight(Animator.GetLayerIndex(layer), weight);
}
}
}

View File

@@ -76,6 +76,7 @@ namespace Fantasy
}
public override void Dispose()
{
ItemId = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<C2Game_UseItemRequest>(this);
#endif
@@ -85,6 +86,8 @@ namespace Fantasy
public uint OpCode() { return OuterOpcode.C2Game_UseItemRequest; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public long ItemId { get; set; }
}
/// <summary>
/// 请求使用物品响应
@@ -500,5 +503,57 @@ namespace Fantasy
[ProtoMember(1)]
public List<AwardInfo> Awards = new List<AwardInfo>();
}
/// <summary>
/// /////////// ******** GM *******/////////////
/// </summary>
/// <summary>
/// 请求执行GM
/// </summary>
[ProtoContract]
public partial class C2Game_GMRequest : AMessage, ICustomRouteRequest
{
public static C2Game_GMRequest Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<C2Game_GMRequest>();
}
public override void Dispose()
{
Cmd = default;
Args = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<C2Game_GMRequest>(this);
#endif
}
[ProtoIgnore]
public Game2C_GMResponse ResponseType { get; set; }
public uint OpCode() { return OuterOpcode.C2Game_GMRequest; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public string Cmd { get; set; }
[ProtoMember(2)]
public string Args { get; set; }
}
/// <summary>
/// 执行GM返回
/// </summary>
[ProtoContract]
public partial class Game2C_GMResponse : AMessage, ICustomRouteResponse
{
public static Game2C_GMResponse Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<Game2C_GMResponse>();
}
public override void Dispose()
{
ErrorCode = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<Game2C_GMResponse>(this);
#endif
}
public uint OpCode() { return OuterOpcode.Game2C_GMResponse; }
[ProtoMember(1)]
public uint ErrorCode { get; set; }
}
}

View File

@@ -30,7 +30,7 @@ namespace Fantasy
public Map2C_CreateRoomResponse ResponseType { get; set; }
public uint OpCode() { return OuterOpcode.C2Map_CreateRoomRequest; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public int MapId { get; set; }
}
@@ -184,7 +184,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_ChangeMap; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public int MapId { get; set; }
[ProtoMember(2)]

View File

@@ -90,25 +90,31 @@ namespace Fantasy
}
public override void Dispose()
{
Rod = default;
Rigs.Clear();
Item = default;
Binds.Clear();
Position = default;
Rotation = default;
Propertys.Clear();
InUse = default;
InHand = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<GearInfo>(this);
#endif
}
[ProtoMember(1)]
public long Rod { get; set; }
public ItemInfo Item { get; set; }
[ProtoMember(2)]
public List<long> Rigs = new List<long>();
public List<ItemInfo> Binds = new List<ItemInfo>();
[ProtoMember(3)]
public Vector3Info Position { get; set; }
[ProtoMember(4)]
public Vector3Info Rotation { get; set; }
[ProtoMember(5)]
public List<KeyValueInt64> Propertys = new List<KeyValueInt64>();
[ProtoMember(6)]
public bool InUse { get; set; }
[ProtoMember(7)]
public bool InHand { get; set; }
}
[ProtoContract]
public partial class UnitStateInfo : AMessage

View File

@@ -29,9 +29,10 @@ namespace Fantasy
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static async FTask<Game2C_UseItemResponse> C2Game_UseItemRequest(this Session session)
public static async FTask<Game2C_UseItemResponse> C2Game_UseItemRequest(this Session session, long itemId)
{
using var request = Fantasy.C2Game_UseItemRequest.Create(session.Scene);
request.ItemId = itemId;
return (Game2C_UseItemResponse)await session.Call(request);
}
@@ -168,6 +169,21 @@ namespace Fantasy
session.Send(message);
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static async FTask<Game2C_GMResponse> C2Game_GMRequest(this Session session, C2Game_GMRequest request)
{
return (Game2C_GMResponse)await session.Call(request);
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static async FTask<Game2C_GMResponse> C2Game_GMRequest(this Session session, string cmd, string args)
{
using var request = Fantasy.C2Game_GMRequest.Create(session.Scene);
request.Cmd = cmd;
request.Args = args;
return (Game2C_GMResponse)await session.Call(request);
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static async FTask<Map2C_CreateRoomResponse> C2Map_CreateRoomRequest(this Session session, C2Map_CreateRoomRequest request)
{
@@ -311,6 +327,21 @@ namespace Fantasy
session.Send(message);
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static async FTask<Map2C_TakeItemResponse> C2Map_TakeItemRequest(this Session session, C2Map_TakeItemRequest request)
{
return (Map2C_TakeItemResponse)await session.Call(request);
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static async FTask<Map2C_TakeItemResponse> C2Map_TakeItemRequest(this Session session, int id, bool task)
{
using var request = Fantasy.C2Map_TakeItemRequest.Create(session.Scene);
request.Id = id;
request.Task = task;
return (Map2C_TakeItemResponse)await session.Call(request);
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static void C2Map_RolePropertyChange(this Session session, C2Map_RolePropertyChange message)
{

View File

@@ -21,8 +21,10 @@ namespace Fantasy
public const uint C2Game_BuyRequest = 2281711384;
public const uint Game2C_BuyResponse = 2415929112;
public const uint Game2C_RewardNotify = 2147493651;
public const uint C2Map_CreateRoomRequest = 2281711385;
public const uint Map2C_CreateRoomResponse = 2415929113;
public const uint C2Game_GMRequest = 2281711385;
public const uint Game2C_GMResponse = 2415929113;
public const uint C2Map_CreateRoomRequest = 2281711386;
public const uint Map2C_CreateRoomResponse = 2415929114;
public const uint C2G_ExitRoomRequest = 268445457;
public const uint G2C_ExitRoomResponse = 402663185;
public const uint C2G_EnterMapRequest = 268445458;
@@ -33,10 +35,12 @@ namespace Fantasy
public const uint C2G_LoginRequest = 268445460;
public const uint G2C_LoginResponse = 402663188;
public const uint G2C_RepeatLogin = 134227729;
public const uint C2Game_GetRoleInfoRequest = 2281711386;
public const uint Game2C_GetRoleInfoResponse = 2415929114;
public const uint C2Game_GetRoleInfoRequest = 2281711387;
public const uint Game2C_GetRoleInfoResponse = 2415929115;
public const uint Map2C_RoleEnterRoomNotify = 2147493653;
public const uint Map2C_RoleExitRoomNotify = 2147493654;
public const uint C2Map_TakeItemRequest = 2281711388;
public const uint Map2C_TakeItemResponse = 2415929116;
public const uint C2Map_RolePropertyChange = 2147493655;
public const uint Map2C_RoleStateNotify = 2147493656;
public const uint Map2C_RoleGearChangeNotify = 2147493657;
@@ -45,37 +49,37 @@ namespace Fantasy
public const uint C2Map_Look = 2147493660;
public const uint Map2C_MoveNotify = 2147493661;
public const uint Map2C_LookeNotify = 2147493662;
public const uint C2S_GetConversationsRequest = 2281711387;
public const uint S2C_GetConversationsResponse = 2415929115;
public const uint C2S_SendMailRequest = 2281711388;
public const uint S2C_SendMailResponse = 2415929116;
public const uint C2S_DeleteMailRequest = 2281711389;
public const uint S2C_DeleteMailResponse = 2415929117;
public const uint C2S_GetConversationsRequest = 2281711389;
public const uint S2C_GetConversationsResponse = 2415929117;
public const uint C2S_SendMailRequest = 2281711390;
public const uint S2C_SendMailResponse = 2415929118;
public const uint C2S_DeleteMailRequest = 2281711391;
public const uint S2C_DeleteMailResponse = 2415929119;
public const uint S2C_HaveMail = 2147493663;
public const uint S2C_MailState = 2147493664;
public const uint C2S_CreateChannelRequest = 2281711390;
public const uint S2C_CreateChannelResponse = 2415929118;
public const uint C2S_JoinChannelRequest = 2281711391;
public const uint S2C_JoinChannelResponse = 2415929119;
public const uint C2S_SendMessageRequest = 2281711392;
public const uint S2C_SendMessageResponse = 2415929120;
public const uint C2S_CreateChannelRequest = 2281711392;
public const uint S2C_CreateChannelResponse = 2415929120;
public const uint C2S_JoinChannelRequest = 2281711393;
public const uint S2C_JoinChannelResponse = 2415929121;
public const uint C2S_SendMessageRequest = 2281711394;
public const uint S2C_SendMessageResponse = 2415929122;
public const uint S2C_Message = 2147493665;
public const uint C2S_CreateClubRequest = 2281711393;
public const uint S2C_CreateClubResponse = 2415929121;
public const uint C2S_GetClubInfoRequest = 2281711394;
public const uint S2C_GetClubInfoResponse = 2415929122;
public const uint C2S_GetMemberListRequest = 2281711395;
public const uint S2C_GetMemberListResponse = 2415929123;
public const uint C2S_GetClubListRequest = 2281711396;
public const uint S2C_GetClubListResponse = 2415929124;
public const uint C2S_JoinClubRequest = 2281711397;
public const uint S2C_JoinClubResponse = 2415929125;
public const uint C2S_LeaveClubRequest = 2281711398;
public const uint S2C_LeaveClubResponse = 2415929126;
public const uint C2S_DissolveClubRequest = 2281711399;
public const uint S2C_DissolveClubResponse = 2415929127;
public const uint C2S_DisposeJoinRequest = 2281711400;
public const uint S2C_DisposeJoinResponse = 2415929128;
public const uint C2S_CreateClubRequest = 2281711395;
public const uint S2C_CreateClubResponse = 2415929123;
public const uint C2S_GetClubInfoRequest = 2281711396;
public const uint S2C_GetClubInfoResponse = 2415929124;
public const uint C2S_GetMemberListRequest = 2281711397;
public const uint S2C_GetMemberListResponse = 2415929125;
public const uint C2S_GetClubListRequest = 2281711398;
public const uint S2C_GetClubListResponse = 2415929126;
public const uint C2S_JoinClubRequest = 2281711399;
public const uint S2C_JoinClubResponse = 2415929127;
public const uint C2S_LeaveClubRequest = 2281711400;
public const uint S2C_LeaveClubResponse = 2415929128;
public const uint C2S_DissolveClubRequest = 2281711401;
public const uint S2C_DissolveClubResponse = 2415929129;
public const uint C2S_DisposeJoinRequest = 2281711402;
public const uint S2C_DisposeJoinResponse = 2415929130;
public const uint S2C_ClubChange = 2147493666;
}
}

View File

@@ -28,7 +28,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_RoleEnterRoomNotify; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public MapUnitInfo Info { get; set; }
}
@@ -51,10 +51,65 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_RoleExitRoomNotify; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public long Id { get; set; }
}
/// <summary>
/// 请求拿起物品
/// </summary>
[ProtoContract]
public partial class C2Map_TakeItemRequest : AMessage, ICustomRouteRequest
{
public static C2Map_TakeItemRequest Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<C2Map_TakeItemRequest>();
}
public override void Dispose()
{
Id = default;
Task = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<C2Map_TakeItemRequest>(this);
#endif
}
[ProtoIgnore]
public Map2C_TakeItemResponse ResponseType { get; set; }
public uint OpCode() { return OuterOpcode.C2Map_TakeItemRequest; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public int Id { get; set; }
[ProtoMember(2)]
public bool Task { get; set; }
}
/// <summary>
/// 请求拿起物品响应
/// </summary>
[ProtoContract]
public partial class Map2C_TakeItemResponse : AMessage, ICustomRouteResponse
{
public static Map2C_TakeItemResponse Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<Map2C_TakeItemResponse>();
}
public override void Dispose()
{
ErrorCode = default;
Id = default;
Task = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<Map2C_TakeItemResponse>(this);
#endif
}
public uint OpCode() { return OuterOpcode.Map2C_TakeItemResponse; }
[ProtoMember(1)]
public int Id { get; set; }
[ProtoMember(2)]
public bool Task { get; set; }
[ProtoMember(3)]
public uint ErrorCode { get; set; }
}
[ProtoContract]
public partial class C2Map_RolePropertyChange : AMessage, ICustomRouteMessage
{
@@ -71,7 +126,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.C2Map_RolePropertyChange; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public List<KeyValueInt64> Propertys = new List<KeyValueInt64>();
}
@@ -95,7 +150,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_RoleStateNotify; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public long Id { get; set; }
[ProtoMember(2)]
@@ -121,7 +176,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_RoleGearChangeNotify; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public long Id { get; set; }
[ProtoMember(2)]
@@ -144,7 +199,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_RolePropertyChangeNotify; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public long Id { get; set; }
[ProtoMember(2)]
@@ -171,7 +226,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.C2Map_Move; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public Vector3Info Position { get; set; }
[ProtoMember(2)]
@@ -202,7 +257,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.C2Map_Look; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public Vector3Info Rotation { get; set; }
[ProtoMember(2)]
@@ -233,7 +288,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_MoveNotify; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public long Id { get; set; }
[ProtoMember(2)]
@@ -270,7 +325,7 @@ namespace Fantasy
}
public uint OpCode() { return OuterOpcode.Map2C_LookeNotify; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.MapRoute;
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public long Id { get; set; }
[ProtoMember(2)]

View File

@@ -6,6 +6,5 @@ namespace Fantasy
public const int GateRoute = 1001; // Gate
public const int SocialRoute = 1002; // Social
public const int GameRoute = 1003; // Game
public const int MapRoute = 1004; // 地图
}
}