diff --git a/.gitignore b/.gitignore index 790dc8f9..7d55b52e 100644 --- a/.gitignore +++ b/.gitignore @@ -149,3 +149,7 @@ DerivedDataCache/* ColorlessWorld-2024-4-2/Library/* ColorlessWorld-2024-4-2/Logs/* +ColorlessWorld-2024-4-2/UserSettings/* + + + diff --git a/ColorlessWorld-2024-4-2/Assets/Image/enemyMark.png b/ColorlessWorld-2024-4-2/Assets/Image/enemyMark.png new file mode 100644 index 00000000..7117e8bd Binary files /dev/null and b/ColorlessWorld-2024-4-2/Assets/Image/enemyMark.png differ diff --git a/ColorlessWorld-2024-4-2/Assets/Image/enemyMark.png.meta b/ColorlessWorld-2024-4-2/Assets/Image/enemyMark.png.meta new file mode 100644 index 00000000..0e7e59cd --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Image/enemyMark.png.meta @@ -0,0 +1,127 @@ +fileFormatVersion: 2 +guid: 02691098c39ccd6458dd3771b3004071 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 12 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + flipGreenChannel: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMipmapLimit: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 0 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 0 + swizzle: 50462976 + cookieLightType: 0 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 256 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + nameFileIdTable: {} + mipmapLimitGroupName: + pSDRemoveMatte: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/MapUnity _2.prefab b/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/MapUnity _2.prefab index d27085b7..49af80f8 100644 --- a/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/MapUnity _2.prefab +++ b/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/MapUnity _2.prefab @@ -59,9 +59,12 @@ MonoBehaviour: locationY: 0 compalte: 0 influenced: 0 + markInfluenced: 0 choossedMark: {fileID: 1211505881046303546} + hightLigtMark: {fileID: 1502226451502315807} red: {fileID: 2100000, guid: 876d1c111d915ca45b7304b41dcc1060, type: 2} yellow: {fileID: 2100000, guid: cf59497cd92e036419cf5cfa2d1e4c79, type: 2} + enemyMark: {fileID: 2100000, guid: 5bc9b4d525fc54344935f187546b718b, type: 2} plyerColour: {fileID: 2100000, guid: 8ec571d5570dab34ea8687ab32ac03ac, type: 2} enemyColour: {fileID: 2100000, guid: 1f241e895118d564d8b61a307da80150, type: 2} colourGameObject: {fileID: 7818877686521749494} @@ -123,7 +126,7 @@ GameObject: - component: {fileID: 1240166201725739929} - component: {fileID: 8781005840710497347} m_Layer: 0 - m_Name: Cylinder + m_Name: inf m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -194,6 +197,89 @@ MeshRenderer: m_SortingLayer: 0 m_SortingOrder: 0 m_AdditionalVertexStreams: {fileID: 0} +--- !u!1 &1502226451502315807 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 8900614378456229163} + - component: {fileID: 8485410642332178147} + - component: {fileID: 6124836568472427169} + m_Layer: 0 + m_Name: mark + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!4 &8900614378456229163 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1502226451502315807} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: -0.2} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 4579690416932963536} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &8485410642332178147 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1502226451502315807} + m_Mesh: {fileID: -5468021829708598221, guid: ae332737a5755ee499c32f566d3a2913, type: 3} +--- !u!23 &6124836568472427169 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1502226451502315807} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 5bc9b4d525fc54344935f187546b718b, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} --- !u!1 &7818877686521749494 GameObject: m_ObjectHideFlags: 0 @@ -332,6 +418,7 @@ Transform: m_ConstrainProportionsScale: 0 m_Children: - {fileID: 5510486009783351286} + - {fileID: 8900614378456229163} m_Father: {fileID: 2384686249825617783} m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} --- !u!33 &2437255636331898785 diff --git a/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/enemyMark.mat b/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/enemyMark.mat new file mode 100644 index 00000000..9632cbbb --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/enemyMark.mat @@ -0,0 +1,137 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 8 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: enemyMark + m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3} + m_Parent: {fileID: 0} + m_ModifiedSerializedProperties: 0 + m_ValidKeywords: + - _ALPHAPREMULTIPLY_ON + - _SURFACE_TYPE_TRANSPARENT + m_InvalidKeywords: [] + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: 3000 + stringTagMap: + RenderType: Transparent + disabledShaderPasses: + - DepthOnly + - SHADOWCASTER + m_LockedProperties: + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BaseMap: + m_Texture: {fileID: 2800000, guid: 02691098c39ccd6458dd3771b3004071, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 2800000, guid: 02691098c39ccd6458dd3771b3004071, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _SpecGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - unity_Lightmaps: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - unity_LightmapsInd: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - unity_ShadowMasks: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Ints: [] + m_Floats: + - _AlphaClip: 0 + - _AlphaToMask: 0 + - _Blend: 0 + - _BlendModePreserveSpecular: 1 + - _BumpScale: 1 + - _ClearCoatMask: 0 + - _ClearCoatSmoothness: 0 + - _Cull: 2 + - _Cutoff: 0.5 + - _DetailAlbedoMapScale: 1 + - _DetailNormalMapScale: 1 + - _DstBlend: 10 + - _DstBlendAlpha: 10 + - _EnvironmentReflections: 1 + - _GlossMapScale: 0 + - _Glossiness: 0 + - _GlossyReflections: 0 + - _Metallic: 0.5 + - _OcclusionStrength: 1 + - _Parallax: 0.005 + - _QueueOffset: 0 + - _ReceiveShadows: 1 + - _Smoothness: 0.5 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _SrcBlendAlpha: 1 + - _Surface: 1 + - _WorkflowMode: 1 + - _ZWrite: 0 + m_Colors: + - _BaseColor: {r: 1, g: 1, b: 1, a: 1} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} + - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} + m_BuildTextureStacks: [] +--- !u!114 &1781025284166211548 +MonoBehaviour: + m_ObjectHideFlags: 11 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} + m_Name: + m_EditorClassIdentifier: + version: 7 diff --git a/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/enemyMark.mat.meta b/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/enemyMark.mat.meta new file mode 100644 index 00000000..70ebd02c --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Prefab/MapNodePrefab/enemyMark.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5bc9b4d525fc54344935f187546b718b +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity b/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity index 86149cc5..8f806f85 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity +++ b/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity @@ -3370,6 +3370,7 @@ Transform: - {fileID: 1227255859} - {fileID: 14034787} - {fileID: 409697653} + - {fileID: 678393340} m_Father: {fileID: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &365854624 @@ -5154,7 +5155,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: time: 0.2 - moveSpeed: 2 + moveSpeed: 4 --- !u!1 &557438114 GameObject: m_ObjectHideFlags: 0 @@ -6434,6 +6435,51 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 669923021} m_CullTransparentMesh: 1 +--- !u!1 &678393339 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 678393340} + - component: {fileID: 678393341} + m_Layer: 0 + m_Name: MapUnityManager + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &678393340 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 678393339} + 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: 348176937} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &678393341 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 678393339} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d344126aa8082fa48b7e5f19eff09202, type: 3} + m_Name: + m_EditorClassIdentifier: + castPool: [] --- !u!1 &680060074 GameObject: m_ObjectHideFlags: 0 @@ -9210,6 +9256,7 @@ MonoBehaviour: usedCard: {fileID: 1964831963} cardDeckNumberText: {fileID: 591146068} usedCardNumberText: {fileID: 1278694494} + deleteCardNumberText: {fileID: 263387098} currentCost: 0 totalCost: 0 turn: 4 @@ -9422,7 +9469,7 @@ MonoBehaviour: serializedVersion: 2 m_Bits: 2176 time: 0.2 - moveSpeed: 2 + moveSpeed: 4 --- !u!114 &1153479994 MonoBehaviour: m_ObjectHideFlags: 0 @@ -9679,7 +9726,7 @@ MonoBehaviour: cardPrefab: {fileID: 3410471369990512392, guid: d255d4b8a06372542bcbeef98cf4761c, type: 3} cardList: 00000000 - cardDeck: 1127000012270000132700001427000015270000162700001727000018270000192700001a2700001b2700001c2700001d2700001e270000 + cardDeck: 1127000012270000132700001427000015270000162700001727000018270000192700001a2700001b2700001c2700001d2700001e2700001f270000 --- !u!4 &1190351098 Transform: m_ObjectHideFlags: 0 @@ -10153,6 +10200,7 @@ MonoBehaviour: templatePlayerState: {fileID: 11400000, guid: afd7daa84e9985b45bd00c91505acb37, type: 2} playerState: {fileID: 0} + onDrag: 0 textMaxCost: {fileID: 2096369105} textCurrentCost: {fileID: 791443579} textMaxStep: {fileID: 219845941} @@ -11235,7 +11283,7 @@ MonoBehaviour: serializedVersion: 2 m_Bits: 2176 time: 0.2 - moveSpeed: 2 + moveSpeed: 4 --- !u!114 &1387589238 MonoBehaviour: m_ObjectHideFlags: 0 @@ -15547,6 +15595,7 @@ MonoBehaviour: cardPrefab: {fileID: 3410471369990512392, guid: d255d4b8a06372542bcbeef98cf4761c, type: 3} usedCardList: + deleteCardList: --- !u!1 &1966305439 GameObject: m_ObjectHideFlags: 0 diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs index b9517d7f..22556d34 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs @@ -8,6 +8,7 @@ using static EnemyNode; using static UnityEngine.Rendering.DebugUI; using System; using Unity.VisualScripting; +using System.Data; public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDragHandler { @@ -19,7 +20,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag public EventSystem eventSystem; bool canUse = true;//决定卡牌是否可以释放 bool choosed;//标识卡牌是否被选中 - + [Header("贝塞尔曲线瞄准")] public GameObject ainPanle; @@ -52,7 +53,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag { Debug.Log("当前费用:" + TurnMaster.Instance.currentCost); Debug.Log("总费用:" + Usermanager.Instance.totalCost); - if (TurnMaster.Instance.currentCost - cardEntity.cardOriginalData.Cost < 0) + if (GameManager.Instance.playerState.currentCost - cardEntity.cardOriginalData.Cost < 0) { Debug.Log("费用不足"); cardEntity.costEnough = false; @@ -102,11 +103,11 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag private void resetComponentPosition() { //遍历范围预览池消除影响色 - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) + for (int i = 0; i < MapUnityManager.Instance.castPool.Count; i++) { - GameManager.Instance.player.influencePreviewPool[i].influenced = false; + MapUnityManager.Instance.castPool[i].influenced = false; } - GameManager.Instance.player.influencePreviewPool.Clear(); + MapUnityManager.Instance.castPool.Clear(); //遍历影响池变色 for (int i = 0; i < cardEntity.influencePreviewPool.Count; i++) { @@ -128,6 +129,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag if (choosed && Mouse.current.rightButton.wasPressedThisFrame) { + GameManager.Instance.onDrag = false; Debug.Log("取消释放"); canUse = false;//取消释放 ainPanle.SetActive(false); @@ -146,6 +148,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag { return; } + GameManager.Instance.onDrag = true; choosed = true; GetComponent().blocksRaycasts = false; @@ -190,7 +193,6 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag //重新调用范围预览 //GameManager.Instance.player.StepPreviewInfluencedNode(cardEntity.cardOriginalData.CastingRange); setCastingRangePreview(cardEntity.cardOriginalData.EffectRange); - Debug.Log(cardEntity.cardOriginalData.CastingRange); //预览影响范围 if (currentNode.influenced) { @@ -198,7 +200,6 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag Vector3 face = currentNode.transform.position - GameManager.Instance.playerOn.transform.position; float euler = Vector3.SignedAngle(-GameManager.Instance.playerOn.transform.forward, face, GameManager.Instance.playerOn.transform.up) + 180; - Debug.Log("角度是:" + euler); setEffectRangePreview(cardEntity.cardOriginalData.EffectRange, euler, currentNode); //influencePreviewPool.Add(currentNode); @@ -213,13 +214,20 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag private void setCastingRangePreview(string effectRange) { + for (int i = 0; i < MapUnityManager.Instance.castPool.Count; i++) + { + MapUnityManager.Instance.castPool[i].influenced = false; + } + MapUnityManager.Instance.castPool.Clear(); if (effectRange == EffectRange.range1) { - GameManager.Instance.player.StepPreviewInfluencedNode(cardEntity.cardOriginalData.CastingRange); + MapUnityManager.Instance.getCastPool(cardEntity.cardOriginalData.EffectRange, cardEntity.cardOriginalData.CastingRange); + //GameManager.Instance.player.StepPreviewInfluencedNode(cardEntity.cardOriginalData.CastingRange); } else { - GameManager.Instance.player.StepPreviewInfluencedNode(1); + MapUnityManager.Instance.getCastPool(cardEntity.cardOriginalData.EffectRange, cardEntity.cardOriginalData.CastingRange); + //GameManager.Instance.player.StepPreviewInfluencedNode(1); /* MapUnity playerNode = GameManager.Instance.playerOn; MapUnity currentNode = GameManager.Instance.playerOn; castingPool.Clear(); @@ -236,7 +244,6 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag } private void setEffectRangePreview(string effectRange, float euler, MapUnity currentNode) { - Debug.Log("作用范围:" + effectRange); MapUnity playerOnNode = GameManager.Instance.playerOn.transform.GetComponent(); var handlers = new Dictionary { @@ -264,86 +271,9 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag { cardEntity.influencePreviewPool = handler.HandleAngleWithResult(euler); } + cardEntity.influencePreviewPool=MathTool.RemoveDuplicates(cardEntity.influencePreviewPool); } - /* private void showEffectRange3_2(float euler) - { - if (euler > 0 && euler < 45) - { - if (checkNodeInfluencedable(currentNode.unitPool[0])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[0]); - if (checkNodeInfluencedable(currentNode.unitPool[4])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[4]); - } - else if (euler > 45 && euler < 135) - { - if (checkNodeInfluencedable(currentNode.unitPool[1])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[1]); - if (checkNodeInfluencedable(currentNode.unitPool[5])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[5]); - } - else if (euler > 135 && euler < 180) - { - if (checkNodeInfluencedable(currentNode.unitPool[2])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[2]); - if (checkNodeInfluencedable(currentNode.unitPool[0])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[0]); - } - else if (euler > 180 && euler < 225) - { - if (checkNodeInfluencedable(currentNode.unitPool[1])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[1]); - if (checkNodeInfluencedable(currentNode.unitPool[3])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[3]); - } - else if (euler > 225 && euler < 315) - { - if (checkNodeInfluencedable(currentNode.unitPool[2])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[2]); - if (checkNodeInfluencedable(currentNode.unitPool[4])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[4]); - } - else if (euler > 315 && euler < 360) - { - if (checkNodeInfluencedable(currentNode.unitPool[3])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[3]); - if (checkNodeInfluencedable(currentNode.unitPool[5])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[5]); - } - }*/ - /* private void showEffectRange2(float euler) - { - if (euler > 0 && euler <= 45) - { - if (checkNodeInfluencedable(currentNode.unitPool[2])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[2]); - } - else if (euler > 45 && euler <= 135) - { - if (checkNodeInfluencedable(currentNode.unitPool[3])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[3]); - } - else if (euler > 135 && euler <= 180) - { - if (checkNodeInfluencedable(currentNode.unitPool[4])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[4]); - } - else if (euler > 180 && euler <= 225) - { - if (checkNodeInfluencedable(currentNode.unitPool[5])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[5]); - } - else if (euler > 225 && euler <= 315) - { - if (checkNodeInfluencedable(currentNode.unitPool[0])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[0]); - } - else if (euler > 315 && euler <= 360) - { - if (checkNodeInfluencedable(currentNode.unitPool[1])) - cardEntity.influencePreviewPool.Add(currentNode.unitPool[1]); - } - }*/ private void getInfluencePreviePoll(MapUnity currentNode, string effecctRange) @@ -359,7 +289,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag private void noAinPanleWork(PointerEventData eventData) { - Ray ray = Camera.main.ScreenPointToRay(Mouse.current.position.value); + /*Ray ray = Camera.main.ScreenPointToRay(Mouse.current.position.value); if (eventData.pointerCurrentRaycast.gameObject != null) { if (Physics.Raycast(ray, out RaycastHit raycastHit)) @@ -367,7 +297,8 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag currentNode = raycastHit.collider.transform.GetComponent(); cardEntity.influencePreviewPool.Add(currentNode); } - } + }*/ + setEffectRangePreview(cardEntity.cardOriginalData.EffectRange, 30.0f, currentNode); } public void OnDrag(PointerEventData eventData) @@ -383,8 +314,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag } else { - //没有范围不需要射线吧,因为不需要指定目标点? - // noAinPanleWork(eventData); + noAinPanleWork(eventData); } dyeing(); @@ -403,114 +333,9 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag public void OnEndDrag(PointerEventData eventData) { - StartCoroutine(OnDragIEnumerator(eventData)); - /* if (!cardEntity.costEnough) - { - return; - } - choosed = false; - if (canUse) - { - if (eventData.pointerCurrentRaycast.gameObject != null) - { - if (eventData.pointerCurrentRaycast.gameObject.name == "Card") - { - transform.SetParent(eventData.pointerCurrentRaycast.gameObject.transform.parent); - transform.position = eventData.pointerCurrentRaycast.gameObject.transform.position; - eventData.pointerCurrentRaycast.gameObject.transform.position = originalParent.position; - eventData.pointerCurrentRaycast.gameObject.transform.SetParent(originalParent); + GameManager.Instance.onDrag = false; - GetComponent().blocksRaycasts = true; - - ainPanle.SetActive(false);//关闭贝塞尔曲线 - //遍历范围预览池消除影响色 - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) - { - GameManager.Instance.player.influencePreviewPool[i].influenced = false; - } - //GameManager.Instance.player.influencePreviewPool.Clear(); - - return; - } - else if (eventData.pointerCurrentRaycast.gameObject.name == "cardSlot") - { - transform.SetParent(eventData.pointerCurrentRaycast.gameObject.transform); - transform.position = eventData.pointerCurrentRaycast.gameObject.transform.position; - GetComponent().blocksRaycasts = true; - - ainPanle.SetActive(false);//关闭贝塞尔曲线 - //遍历范围预览池消除影响色 - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) - { - GameManager.Instance.player.influencePreviewPool[i].influenced = false; - } - //GameManager.Instance.player.influencePreviewPool.Clear(); - - return; - } - } - if (ainPanle.activeSelf) - { - ainPanle.SetActive(false);//关闭贝塞尔曲线 - } - - //先判断该卡牌的类型是否是需要范围 - if (cardEntity.cardOriginalData.CastingRange != 0) - { - //检测碰撞的地图节点是否被影响(可释放) - if (currentNode == null || currentNode.influenced == false) - { - //遍历范围预览池消除影响色(红色,卡牌的释放范围) - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) - { - GameManager.Instance.player.influencePreviewPool[i].influenced = false; - } - //GameManager.Instance.player.influencePreviewPool.Clear(); - } - else if (currentNode.influenced) - { - - //卡牌释放效果 - Debug.Log("卡牌释放前影响格数:" + cardEntity.influencePreviewPool.Count); - cardEntity.use(); - Debug.Log("玩家盾量:" + Usermanager.Instance.Shield); - - - } - //遍历范围预览池消除影响色 - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) - { - GameManager.Instance.player.influencePreviewPool[i].influenced = false; - } - GameManager.Instance.player.influencePreviewPool.Clear(); - //遍历影响池变色 - for (int i = 0; i < cardEntity.influencePreviewPool.Count; i++) - { - cardEntity.influencePreviewPool[i].influenced = false; - } - cardEntity.influencePreviewPool.Clear(); - GetComponent().blocksRaycasts = true; - - //其他位置都归位 - transform.SetParent(originalParent); - transform.localPosition = originalpoint; - return; - }//范围类,需要指定被影响的节点才能释放 - else - { - //卡牌释放效果 - cardEntity.use(); - Debug.Log("玩家盾量:" + Usermanager.Instance.Shield); - - return; - - }//无范围类,直接释放 - - } - else - { - canUse = true; - }*/ + StartCoroutine(OnDragIEnumerator(eventData)); } private IEnumerator OnDragIEnumerator(PointerEventData eventData) @@ -551,10 +376,16 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag ainPanle.SetActive(false);//关闭贝塞尔曲线 //遍历范围预览池消除影响色 - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) + for (int i = 0; i < MapUnityManager.Instance.castPool.Count; i++) { - GameManager.Instance.player.influencePreviewPool[i].influenced = false; + MapUnityManager.Instance.castPool[i].influenced = false; + } + MapUnityManager.Instance.castPool.Clear(); + for (int i = 0; i < cardEntity.influencePreviewPool.Count; i++) + { + cardEntity.influencePreviewPool[i].influenced = false; } + cardEntity.influencePreviewPool.Clear(); //GameManager.Instance.player.influencePreviewPool.Clear(); yield break; @@ -572,18 +403,17 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag if (currentNode == null || currentNode.influenced == false) { //遍历范围预览池消除影响色(红色,卡牌的释放范围) - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) + for (int i = 0; i < MapUnityManager.Instance.castPool.Count; i++) { - GameManager.Instance.player.influencePreviewPool[i].influenced = false; + MapUnityManager.Instance.castPool[i].influenced = false; } - //GameManager.Instance.player.influencePreviewPool.Clear(); + MapUnityManager.Instance.castPool.Clear(); } else if (currentNode.influenced) { //卡牌释放效果 yield return StartCoroutine(cardEntity.settle(0)); - Debug.Log("玩家盾量:" + Usermanager.Instance.Shield); } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs index 2123996e..038b38e0 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs @@ -12,7 +12,7 @@ public class CardEntity : MonoBehaviour { public CardOriginalData cardOriginalData; //public CardOriginalData cardData; - public List influencePreviewPool;//卡牌的影响范围 + public List influencePreviewPool=new List();//卡牌的影响范围 public int cardId; @@ -155,7 +155,6 @@ public class CardEntity : MonoBehaviour } if (cardOriginalData.AdvantageDescription.Length != 0) { - Debug.Log("优势:" + cardOriginalData.AdvantageDescription + ";"); sb.Append("优势:" + cardOriginalData.AdvantageDescription + ";"); } if (sb.Length > 0) diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs index 8b1d3b3f..a3175107 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs @@ -13,6 +13,7 @@ public class TurnMaster : Singleton public Text cardDeckNumberText; public Text usedCardNumberText; + public Text deleteCardNumberText; public int currentCost; public int totalCost; @@ -37,8 +38,8 @@ public class TurnMaster : Singleton } public void Start() { - totalCost = Usermanager.Instance.totalCost; - currentCost = totalCost; + /*totalCost = Usermanager.Instance.totalCost; + currentCost = totalCost;*/ } private void Update() @@ -62,8 +63,8 @@ public class TurnMaster : Singleton { //结算buff //结算技能冷却 - // EnemyManager.Instance.EnemySkillCoolDown_Observer(); - + // EnemyManager.Instance.EnemySkillCoolDown_Observer(); + EnemyManager.Instance.enemyTurnSettle(0); turn = Turn.enemyTurn; } @@ -74,7 +75,7 @@ public class TurnMaster : Singleton //敌人动作如移动,涂色 EnemyManager.Instance.EnemyTurn_Observer(); - EnemyManager.Instance.enemyTurnSettle(0); + turn = Turn.turnStop; // EndEnemyTurn();在enemyTurn里面调用 @@ -83,6 +84,7 @@ public class TurnMaster : Singleton //同步UI cardDeckNumberText.text = cardDeck.cardList.Count.ToString(); usedCardNumberText.text = usedCard.usedCardList.Count.ToString(); + deleteCardNumberText.text = usedCard.deleteCardList.Count.ToString(); } IEnumerator EndPlayerTurnBegin() { @@ -105,8 +107,9 @@ public class TurnMaster : Singleton //老吊写的函数 public void restoreResource(int settleTurn) { - totalCost = Usermanager.Instance.totalCost; - currentCost = totalCost; + //totalCost = Usermanager.Instance.totalCost; + //currentCost = totalCost; + GameManager.Instance.playerState.currentCost = GameManager.Instance.playerState.maxCost; Usermanager.Instance.Shield = 0; } IEnumerator ShuffleWithLosingCards() diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/UsedCard.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/UsedCard.cs index e7a50223..4c0098cc 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/UsedCard.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/UsedCard.cs @@ -5,5 +5,8 @@ using UnityEngine; public class UsedCard : MonoBehaviour { public GameObject cardPrefab; + [Header("墓地")] public List usedCardList; + [Header("销毁")] + public List deleteCardList; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyManager.cs index 64fc4285..9355a65b 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyManager.cs @@ -1,5 +1,6 @@ using System.Collections; using System.Collections.Generic; +using System.Linq; using UnityEngine; using UnityEngine.UI; @@ -153,9 +154,8 @@ public class EnemyManager : Singleton } public void AttackRangePreviewInfluencedNode(MapUnity enemyNode, int step,List influencePreviewPool)//可移动格子预览 - { - - influencePreviewPool .Clear(); + { + influencePreviewPool .Clear(); //GameManager.Instance.playerOn.InfluencePool = GameManager.Instance.playerOn.unitPool; MapUnity playerNode = enemyNode; MapUnity currentNode = enemyNode; @@ -519,11 +519,14 @@ public class EnemyManager : Singleton } } + + List disInfluencePreviewPool = influencePreviewPool.Distinct(new MapUnityCompare()).ToList(); + //遍历影响池变色 - for (int i = 0; i < influencePreviewPool.Count; i++) + foreach ( var i in disInfluencePreviewPool) { - influencePreviewPool[i].influenced = true; - influencePreviewPool[i].choossedMark.GetComponent().material = influencePreviewPool[i].red; + i.markInfluenced = true; + i.hightLigtMark.GetComponent().material = i.enemyMark; } } @@ -896,5 +899,30 @@ public class EnemyManager : Singleton } } + List disInfluencePreviewPool = influencePreviewPool.Distinct(new MapUnityCompare()).ToList (); + influencePreviewPool.Clear(); + foreach (var i in disInfluencePreviewPool ) + { + influencePreviewPool.Add(i); + } + } + + + //比较类 + class MapUnityCompare : IEqualityComparer + { + public bool Equals(MapUnity x, MapUnity y) + { + if((x.locationX == y.locationX)&&(x.locationY == y.locationY)) + { + return true; + } + return false; + } + + public int GetHashCode(MapUnity obj) + { + return obj.locationX.GetHashCode() ^ obj.locationY.GetHashCode(); + } } } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs index 443f3836..f28ae682 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs @@ -309,6 +309,18 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver if (EnemyState.currentHP <= 0) { OnDeath(); + }else + { + foreach (var key in EnemyState.abnormalCondition.Keys.ToList()) + { + Debug.Log(key); + switch (key) + { + case AbnormalCondition.sleep: + EnemyState.abnormalCondition.Remove(key); + break; + } + } } } @@ -338,9 +350,6 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver case AbnormalCondition.disarm: disarmSettle(EnemyState.abnormalCondition[key]); break; - case AbnormalCondition.sleep: - sleepSettle(EnemyState.abnormalCondition[key]); - break; case AbnormalCondition.bleed: //bleedSettle(EnemyState.abnormalCondition[key]); break; @@ -350,6 +359,18 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver } abnormalConditionEndCheck(); } + + foreach (var key in EnemyState.abnormalCondition.Keys.ToList()) + { + Debug.Log(key); + switch (key) + { + case AbnormalCondition.sleep: + sleepSettle(EnemyState.abnormalCondition[key]); + break; + } + abnormalConditionEndCheck(); + } /*for(int i=0;i< EnemyState.abnormalCondition.Count; i++) { switch (EnemyState.abnormalCondition[i].key) @@ -410,6 +431,7 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver { EnemyState.damageMultiplier = 0; EnemyState.stepRangeMultiplier = 0; + EnemyState.abnormalCondition[AbnormalCondition.sleep]--; } public void bleedSettle() diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/GameManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/GameManager.cs index 6721d9cd..813fecad 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/GameManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/GameManager.cs @@ -16,6 +16,9 @@ public class GameManager : Singleton public PlayerState_SO templatePlayerState;//角色数据ScriptableObject模板 public PlayerState_SO playerState;//在游戏中实际使用的数据 + [Header("角色动作状态")] + public bool onDrag;//正在拖动卡牌 + [Header("角色状态数据UI")] public Text textMaxCost; public Text textCurrentCost; @@ -86,7 +89,6 @@ public class GameManager : Singleton public bool SyncColourCountUI() { bool result = false; - Debug.Log("Sync"); float playerCount = 0; float enemyCount = 0; float totalCount = 0; diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler7_2.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler7_2.cs index 4d51a25d..2b3832c9 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler7_2.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler7_2.cs @@ -15,37 +15,37 @@ public class EffectRangeHandler7_2 : EffectRangeHandlerBase { { 30.0f, () => { - get7_2Node(currentNode,2); + get7_2Node(currentNode); return influencePreviewPool; } }, { 90.0f, () => { - get7_2Node(currentNode,3); + get7_2Node(currentNode); return influencePreviewPool; } }, { 150.0f, () => { - get7_2Node(currentNode,4); + get7_2Node(currentNode); return influencePreviewPool; } }, { 210.0f, () => { - get7_2Node(currentNode,5); + get7_2Node(currentNode); return influencePreviewPool; } }, { 270.0f, () => { - get7_2Node(currentNode,0); + get7_2Node(currentNode); return influencePreviewPool; } }, { 330.0f, () => { - get7_2Node(currentNode,1); + get7_2Node(currentNode); return influencePreviewPool; } } @@ -54,9 +54,9 @@ public class EffectRangeHandler7_2 : EffectRangeHandlerBase } - private void get7_2Node(MapUnity currentNode, int value) + private void get7_2Node(MapUnity currentNode) { - if (tryGetNodeInfluencedable(currentNode.unitPool[counter.Subtract(value, 1)])) + /*if (tryGetNodeInfluencedable(currentNode.unitPool[counter.Subtract(value, 1)])) { tryGetNodeInfluencedable(currentNode.unitPool[counter.Subtract(value, 1)].unitPool[value]); } @@ -64,7 +64,8 @@ public class EffectRangeHandler7_2 : EffectRangeHandlerBase { tryGetNodeInfluencedable(currentNode.unitPool[counter.Add(value, 1)].unitPool[value]); } - getongNode(currentNode, value); + getongNode(currentNode, value);*/ + getNodeTools.getCircleNode(influencePreviewPool,1); } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler8_2.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler8_2.cs index 40ca3aab..3172b4c0 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler8_2.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandler8_2.cs @@ -54,48 +54,19 @@ public class EffectRangeHandler8_2 : EffectRangeHandlerBase } - public bool tryGetNodeInfluencedableList(MapUnity node,List nodeList) - { - bool canPass = true; - if (node == null) - { - canPass = false; - return canPass; - } - Debug.Log("坐标X" + node.locationX + "坐标Y" + node.locationY); - if (node.TryGetComponent(out EnemyNode enemyNode)) - { - Debug.Log("JJKK"); - if (enemyNode.enemyType == EnemyNode.EnemyType.block) - { - Debug.Log("AABB"); - canPass = false; - nodeList.Add(node); - } - Debug.Log("DDFF"); - } - - if (canPass) - { - nodeList.Add(node); - } - return canPass; - } - private void get8_2Node(MapUnity node, List influencePreviewPool) { + Debug.Log("进入8_2"); influencePreviewPool.Add(node); - getNearbyNode(influencePreviewPool); - getNearbyNode(influencePreviewPool); - getNearbyNode(influencePreviewPool); - while (influencePreviewPool.Contains(node)) + getNodeTools.getCircleNode(influencePreviewPool,3); + /*while (influencePreviewPool.Contains(node)) { influencePreviewPool.Remove(node); - } + }*/ } - public void getNearbyNode(List nodeList) +/* public void getNearbyNode(List nodeList) { // 创建一个副本以避免遍历时修改原集合 List nodesCopy = new List(nodeList); @@ -112,7 +83,7 @@ public class EffectRangeHandler8_2 : EffectRangeHandlerBase // 遍历完成后统一修改原集合 nodeList.AddRange(nodesToAdd); - } + }*/ } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandlerBase.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandlerBase.cs index a14d1d3b..53042a8d 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandlerBase.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Handler/EffectRangeHandlerBase.cs @@ -18,18 +18,14 @@ public class EffectRangeHandlerBase : EffectRangeHandler canPass = false; return canPass; } - Debug.Log("currentNode"+ currentNode.enemyNode); /*if (currentNode.TryGetComponent(out EnemyNode enemyNode))*/ if (currentNode.enemyNode!=null) { - Debug.Log("JJKK"); if (currentNode.enemyNode.enemyType.Equals(EnemyNode.EnemyType.block)) { - Debug.Log("AABB"); canPass = false; influencePreviewPool.Add(currentNode); } - Debug.Log("DDFF"); } if (canPass) @@ -41,7 +37,6 @@ public class EffectRangeHandlerBase : EffectRangeHandler public List HandleAngleWithResult(float angle) { - Debug.Log("角度大小" + angle); foreach (var kvp in angleActions) { if (Math.Abs(angle - kvp.Key) < Epsilon) @@ -49,7 +44,6 @@ public class EffectRangeHandlerBase : EffectRangeHandler return kvp.Value(); } } - Debug.Log("数组大小" + influencePreviewPool.Count); return influencePreviewPool; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs index d8ad3988..e242505c 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs @@ -12,10 +12,14 @@ public class MapUnity : MonoBehaviour [Header("UI效果范围控件")] public bool influenced;//被选中 + public bool markInfluenced;//需要被高亮显示 + public GameObject choossedMark;//被选中激活 - // public List InfluencePool;//影响池 + public GameObject hightLigtMark;//被选中高亮 + public Material red; public Material yellow; + public Material enemyMark; [Header("涂色控件")] public Material plyerColour;//玩家颜色 @@ -77,9 +81,17 @@ public class MapUnity : MonoBehaviour { choossedMark.SetActive(false); } + if (markInfluenced) + { + hightLigtMark.SetActive(true); + } + else + { + hightLigtMark.SetActive(false); + } - //根据涂色角色改变颜色 - if(whoColour == WhoColour.playerColour ) + //根据涂色角色改变颜色 + if (whoColour == WhoColour.playerColour ) { colourGameObject.GetComponent().material = plyerColour; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs index 6623f053..ba25ac9d 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs @@ -34,8 +34,7 @@ public class Player : MonoBehaviour if (Physics.Raycast(ray, out RaycastHit raycastHit, 500, playerLayerMask.value) && raycastHit.collider.gameObject.tag == "Player") { Debug.Log(raycastHit.collider.gameObject.name); - MapUnityManager mapUnityManager = new MapUnityManager(); - influencePreviewPool.AddRange(mapUnityManager.findReachableTiles(GameManager.Instance.playerOn, GameManager.Instance.playerState.currentStepRange)); + influencePreviewPool.AddRange(MapUnityManager.Instance.findReachableTiles(GameManager.Instance.playerOn, GameManager.Instance.playerState.currentStepRange)); //遍历影响池变色 for (int i = 0; i < influencePreviewPool.Count; i++) { diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardData_SO/PlayerState_SO.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardData_SO/PlayerState_SO.cs index 34e8f38c..64b73629 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardData_SO/PlayerState_SO.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardData_SO/PlayerState_SO.cs @@ -24,5 +24,10 @@ public class PlayerState_SO : ScriptableObject public float currentHP; + private void Start() + { + maxCost = 3; + } + } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/EffectRange.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/EffectRange.cs index 1fbe378a..a1fe83a4 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/EffectRange.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/EffectRange.cs @@ -40,4 +40,7 @@ public class EffectRange public const string range8_1 = "8_1"; public const string range8_2 = "8_2"; + + public static readonly List speRange = new List {range2, range3_1, range3_2, range3_3, range4_1, + range4_2, range4_3, range5_1, range5_2, range5_3, range6_1, range6_2, range6_3, range7_1, range7_2, range8_1 , range8_2}; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs index 30c62bd0..54dddb85 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs @@ -39,4 +39,22 @@ public class MathTool return numbers; } + + public static List RemoveDuplicates(List list) + { + List result = new List(); + HashSet set = new HashSet(); + + foreach (T item in list) + { + if (set.Add(item)) + { + result.Add(item); + } + } + + return result; + } } + + diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs index dfabdad3..9a12d39f 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs @@ -1,10 +1,15 @@ +using System; using System.Collections; using System.Collections.Generic; using UnityEngine; +using UnityEngine.UI; +using UnityEngine.UIElements; -public class getNodeTools +public class getNodeTools { - public bool tryGetNodeInfluencedable(MapUnity currentNode,List nodeList) + [Header("瞄准射线图层剔除")] + public LayerMask layerMask; + public bool tryGetNodeInfluencedable(MapUnity currentNode, List nodeList) { bool canPass = true; if (currentNode == null) @@ -23,5 +28,110 @@ public class getNodeTools return canPass; } + public static void getLongNodes(MapUnity currentNode, int angle, int range,List results) + { + List result = new List(); + MapUnity currentCheckNode = currentNode; + for (int i = 0; i < range; i++) + { + if (tryGetNode(currentCheckNode.unitPool[angle], results)) + { + currentCheckNode = currentCheckNode.unitPool[angle]; + } + else + { + return; + } + } + } + + public static bool tryGetNode(MapUnity currentNode, List results) + { + bool canPass = true; + if (currentNode == null) + { + canPass = false; + return canPass; + } + /*if (currentNode.TryGetComponent(out EnemyNode enemyNode))*/ + if (currentNode.enemyNode != null) + { + if (currentNode.enemyNode.enemyType.Equals(EnemyNode.EnemyType.block)) + { + canPass = false; + results.Add(currentNode); + } + } + + if (canPass) + { + results.Add(currentNode); + } + return canPass; + } + + public static void getCircleNode(List nodeList,int range) + { + for (int i = 0;i < range;i++) + { + getNearbyNode(nodeList); + } + } + public static void getNearbyNode(List nodeList) + { + // 创建一个副本以避免遍历时修改原集合 + List nodesCopy = new List(nodeList); + List nodesToAdd = new List(); // 临时列表存储要添加的节点 + + foreach (var node in nodesCopy) + { + for (int i = 0; i < 6; i++) + { + tryGetNode(node.unitPool[i], nodesToAdd); + } + } + + // 遍历完成后统一修改原集合 + nodeList.AddRange(nodesToAdd); + + } + + public static void checkListPass(List mapUnityList) + { + + for (int i = 0; i < mapUnityList.Count; i++) + { + if (!checkNodePass(mapUnityList[i])) + { + mapUnityList.RemoveAt(i); + } + + } + + } + + public static bool checkNodePass(MapUnity mapUnity) + { + LayerMask layerMask=new LayerMask(); + int blockLayer = LayerMask.NameToLayer("Block"); + layerMask |= (1 << blockLayer); + bool canPass=true; + //MapUnity playerOnNode = GameManager.Instance.playerOn.transform.GetComponent(); + var playerOnNode=GameManager.Instance.player; + float distance = Vector3.Distance(playerOnNode.transform.position, mapUnity.transform.position); + Vector3 dir = mapUnity.transform.position - playerOnNode.transform.position; + Ray ray = new Ray(playerOnNode.transform.position, dir); + if (Physics.Raycast(ray, out RaycastHit raycastHit, distance, layerMask.value)) + { + canPass = false; + } +/* if (!canPass) + {*/ + Debug.Log("距离是" + distance + ",结果是:" + canPass+",角度是:"+dir); + //} + return canPass; + + } + } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/UI/EnemyPlanActionUI.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/UI/EnemyPlanActionUI.cs index 4f78b75e..4a28a7fc 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/UI/EnemyPlanActionUI.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/UI/EnemyPlanActionUI.cs @@ -14,7 +14,7 @@ public class EnemyPlanActionUI : MonoBehaviour private void OnMouseEnter() { - if (TurnMaster.Instance.turn == TurnMaster.Turn.playerTurn) + if (TurnMaster.Instance.turn == TurnMaster.Turn.playerTurn &&GameManager .Instance .onDrag ==false ) { MapUnity currentMapUnity = GameManager.Instance.X[enemyNode.positionX].Y[enemyNode.positionY]; @@ -134,21 +134,21 @@ public class EnemyPlanActionUI : MonoBehaviour { for (int i = 0; i < step + 1; i++) { - enemyNode.pasth[i].choossedMark.GetComponent().material = enemyNode.pasth[i].yellow; + enemyNode.pasth[i].hightLigtMark.GetComponent().material = enemyNode.pasth[i].yellow; } } else if (enemyNode.pasth.Count - 1 == step) { for (int i = 0; i < step; i++) { - enemyNode.pasth[i].choossedMark.GetComponent().material = enemyNode.pasth[i].yellow; + enemyNode.pasth[i].hightLigtMark.GetComponent().material = enemyNode.pasth[i].yellow; } } else { for (int i = 0; i < enemyNode.pasth.Count; i++) { - enemyNode.pasth[i].choossedMark.GetComponent().material = enemyNode.pasth[i].yellow; + enemyNode.pasth[i].hightLigtMark.GetComponent().material = enemyNode.pasth[i].yellow; } } } @@ -160,7 +160,7 @@ public class EnemyPlanActionUI : MonoBehaviour { for (int i = 0; i < enemyNode.oppositePasth.Count; i++) { - enemyNode.oppositePasth[i].choossedMark.GetComponent().material = enemyNode.pasth[i].yellow; + enemyNode.oppositePasth[i].hightLigtMark.GetComponent().material = enemyNode.pasth[i].yellow; } } break; @@ -185,9 +185,9 @@ public class EnemyPlanActionUI : MonoBehaviour //遍历影响池变色 for (int i = 0; i < enemyNode.rangePool.Count; i++) { - enemyNode.rangePool[i].influenced = false; + enemyNode.rangePool[i].markInfluenced = false; } - enemyNode.rangePool.Clear(); + //enemyNode.rangePool.Clear(); } } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs index e2f9204f..e70550f5 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs @@ -22,11 +22,17 @@ public class DestructionManager : Singleton GameManager.Instance.SyncColourCountUI(); //遍历范围预览池消除影响色 Debug.Log("清除前红色格数:" + GameManager.Instance.player.influencePreviewPool.Count); - for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) + /*for (int i = 0; i < GameManager.Instance.player.influencePreviewPool.Count; i++) { GameManager.Instance.player.influencePreviewPool[i].influenced = false; } - GameManager.Instance.player.influencePreviewPool.Clear(); + GameManager.Instance.player.influencePreviewPool.Clear();*/ + + for (int i = 0; i < MapUnityManager.Instance.castPool.Count; i++) + { + MapUnityManager.Instance.castPool[i].influenced = false; + } + MapUnityManager.Instance.castPool.Clear(); //GetComponent().blocksRaycasts = true; diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs index 59b3f322..0f5b65a7 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs @@ -1,9 +1,13 @@ using System.Collections; using System.Collections.Generic; +using System.Linq; +using UnityEditor.Experimental.GraphView; using UnityEngine; -public class MapUnityManager : MonoBehaviour +public class MapUnityManager : Singleton { + + public List castPool=new List();//记录预览影响的对象池 public List findReachableTiles(MapUnity startNode, int movePoints) { List reachableNodes = new List(); @@ -38,4 +42,33 @@ public class MapUnityManager : MonoBehaviour return reachableNodes; } + + public void getCastPool(string effectRange,int castRange) + { + MapUnity playerOn = GameManager.Instance.playerOn; + if (EffectRange.speRange.Contains(effectRange)) + { + for (int i = 0; i < 6; i++) + { + getNodeTools.getLongNodes(playerOn, i, castRange, castPool); + } + } + else + { + castPool.Add(playerOn); + getNodeTools.getCircleNode(castPool, castRange); + while (castPool.Contains(playerOn)) + { + castPool.Remove(playerOn); + } + } + //castPool.Distinct().ToList(); + //getNodeTools.checkListPass(castPool); + //遍历影响池变色 + for (int i = 0; i < castPool.Count; i++) + { + castPool[i].influenced = true; + castPool[i].choossedMark.GetComponent().material = castPool[i].red; + } + } } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs index c4b9845d..3fe3438e 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs @@ -2,6 +2,7 @@ using System.Collections; using System.Collections.Generic; using Unity.VisualScripting; using UnityEngine; +using UnityEngine.Playables; public class SettlementManager : Singleton { @@ -46,6 +47,7 @@ public class SettlementManager : Singleton { Dictionary trueFunctionVal = new Dictionary(); bool canAdv = GameManager.Instance.SyncColourCountUI(); + GameManager.Instance.playerState.currentCost -= cardOriginalData.Cost; if (canAdv) { trueFunctionVal.AddRange(cardOriginalData.AdvantageFunctionVal); @@ -80,7 +82,7 @@ public class SettlementManager : Singleton abnormalConditionWork(kvp.Key, int.Parse(kvp.Value), influencePreviewPool); break; case CardFunction.costRestore: - TurnMaster.Instance.currentCost += int.Parse(kvp.Value); + GameManager.Instance.playerState.currentCost += int.Parse(kvp.Value); break; case CardFunction.dyeing: dyeingWork(influencePreviewPool); @@ -117,6 +119,7 @@ public class SettlementManager : Singleton } } + GameManager.Instance.SyncColourCountUI(); } diff --git a/ColorlessWorld-2024-4-2/Assets/data/card_data.csv b/ColorlessWorld-2024-4-2/Assets/data/card_data.csv index ef1e7510..40083150 100644 --- a/ColorlessWorld-2024-4-2/Assets/data/card_data.csv +++ b/ColorlessWorld-2024-4-2/Assets/data/card_data.csv @@ -1,8 +1,8 @@ 锘縄D,鍚嶇О,璐圭敤,绋鏈夊害,鍔熻兘,鏁板,鏂芥硶鑼冨洿,浣滅敤鑼冨洿,娑堣,浼樺娍鍔熻兘,鏁板,鍗$墝绫诲瀷,浼樺娍鎻忚堪,鍥剧墖璺緞 -10001,灏勫嚮,1,1,1,7,1,1,0,1,7,1,,PlayerIcon -10002,鎶ょ浘,1,1,2,5,0,1,0,2,5,1,,PlayerIcon +10001,灏勫嚮,1,1,1,7,3,1,0,1,7,1,,PlayerIcon +10002,鎶ょ浘,1,1,2,5,0,0,0,2,5,1,,PlayerIcon 10003,姣掕嵂,1,1,4,6,3,1,0,4,10,1,鏂藉姞4灞備腑姣,PlayerIcon -10004,鏋彾鐐稿脊,2,2,9,2,1,7_2,0,9;4,2;4,1,鏂藉姞4灞備腑姣,PlayerIcon +10004,鏋彾鐐稿脊,2,2,9,2,2,7_2,0,9;4,2;4,1,鏂藉姞4灞備腑姣,PlayerIcon 10005,鑺辩矇,0,2,8,1,4,1,0,8,2,1,鏂藉姞1灞傛矇鐫,PlayerIcon 10006,鑷存畫,2,1,7,2,2,1,0,7;9,2;2,1,鏂藉姞2灞傛祦琛,PlayerIcon 10007,婊嬪吇,1,2,12;13,3;1,0,0,0,12,3,1,鏃犻渶涓㈠純,PlayerIcon @@ -12,4 +12,5 @@ 10011,鑽夊洟,2,1,1;14,5;0,1,6_2,1,1;14,8;0,1,閫犳垚3鐐逛激瀹,PlayerIcon 10012,绌垮埡灏勫嚮,2,1,1,8,1,5_1,0,1;4,8;4,1,鏂藉姞4灞備腑姣,PlayerIcon 10013,妫灄涔嬫,3,3,1,20,3,1,0,1;15,20;0,1,閫犳垚鍦哄湴宸激瀹,PlayerIcon -10014,宸ㄦ爲涔嬪紦,2,1,1;14,13;0,1,5_3,0,1;14;5,13;0;1,1,鏂藉姞1灞傝櫄寮,PlayerIcon +10014,宸ㄦ爲涔嬪紦,2,1,1;14,13;0,3,5_3,0,1;14;5,13;0;1,1,鏂藉姞1灞傝櫄寮,PlayerIcon +10015,鐐稿脊,0,1,1,5,0,8_2,0,1,5,1,,PlayerIcon diff --git a/ColorlessWorld-2024-4-2/UserSettings/EditorUserSettings.asset b/ColorlessWorld-2024-4-2/UserSettings/EditorUserSettings.asset index 4e2b5931..ef5c316a 100644 --- a/ColorlessWorld-2024-4-2/UserSettings/EditorUserSettings.asset +++ b/ColorlessWorld-2024-4-2/UserSettings/EditorUserSettings.asset @@ -6,9 +6,6 @@ EditorUserSettings: serializedVersion: 4 m_ConfigSettings: RecentlyUsedSceneGuid-0: - value: 0052010304020f0b0858582012770844124f1929292d2068292a1b62e7b9313a - flags: 0 - RecentlyUsedSceneGuid-1: value: 5a08575f5207595a0f5d59741173094444164f7d7d2a23317c7a4465bbe1646d flags: 0 vcSharedLogLevel: diff --git a/ColorlessWorld-2024-4-2/UserSettings/Layouts/CurrentMaximizeLayout.dwlt b/ColorlessWorld-2024-4-2/UserSettings/Layouts/CurrentMaximizeLayout.dwlt index 1ed346a6..e7098555 100644 --- a/ColorlessWorld-2024-4-2/UserSettings/Layouts/CurrentMaximizeLayout.dwlt +++ b/ColorlessWorld-2024-4-2/UserSettings/Layouts/CurrentMaximizeLayout.dwlt @@ -46,10 +46,10 @@ MonoBehaviour: m_Tooltip: m_Pos: serializedVersion: 2 - x: 409.6 + x: 410.4 y: 73.6 - width: 769.99994 - height: 466.2 + width: 769.19995 + height: 465.4 m_SerializedDataModeController: m_DataMode: 0 m_PreferredDataMode: 0 @@ -102,10 +102,10 @@ MonoBehaviour: serializedVersion: 2 x: 0 y: 21 - width: 769.99994 - height: 445.2 - m_Scale: {x: 0.50130206, y: 0.50130206} - m_Translation: {x: 385, y: 222.6} + width: 769.19995 + height: 444.4 + m_Scale: {x: 0.50078124, y: 0.50078124} + m_Translation: {x: 384.59998, y: 222.2} m_MarginLeft: 0 m_MarginRight: 0 m_MarginTop: 0 @@ -113,12 +113,12 @@ MonoBehaviour: m_LastShownAreaInsideMargins: serializedVersion: 2 x: -768 - y: -444.04367 + y: -443.70673 width: 1536 - height: 888.08734 + height: 887.41345 m_MinimalGUI: 1 - m_defaultScale: 0.50130206 - m_LastWindowPixelSize: {x: 962.49994, y: 582.75} + m_defaultScale: 0.50078124 + m_LastWindowPixelSize: {x: 961.49994, y: 581.75} m_ClearInEditMode: 1 m_NoCameraWarning: 1 m_LowResolutionForAspectRatios: 00000000000000000000 @@ -169,7 +169,7 @@ MonoBehaviour: x: 0 y: 0 width: 1119.2 - height: 487.2 + height: 486.4 m_MinSize: {x: 200, y: 50} m_MaxSize: {x: 16192, y: 8096} vertical: 0 @@ -191,8 +191,8 @@ MonoBehaviour: serializedVersion: 2 x: 0 y: 0 - width: 347.2 - height: 487.2 + width: 348 + height: 486.4 m_MinSize: {x: 201, y: 221} m_MaxSize: {x: 4001, y: 4021} m_ActualView: {fileID: 6} @@ -223,8 +223,8 @@ MonoBehaviour: serializedVersion: 2 x: 62.4 y: 73.6 - width: 346.2 - height: 466.2 + width: 347 + height: 465.4 m_SerializedDataModeController: m_DataMode: 0 m_PreferredDataMode: 0 @@ -238,9 +238,9 @@ MonoBehaviour: m_SceneHierarchy: m_TreeViewState: scrollPos: {x: 0, y: 0} - m_SelectedIDs: - m_LastClickedID: 0 - m_ExpandedIDs: be2bfcff062cfcff262dfcff72bbfffff0bbffff58bdffff2afbffffd46c0000426d0000f46d0000046f0000366f0000926f0000aa700000507100009a710000c2710000ea7100000472000060720000ba720000c47200000a7300002c730000 + m_SelectedIDs: e4cd0000 + m_LastClickedID: 52708 + m_ExpandedIDs: 0a80feff9681feffa0cc000086cd0000cace000014cf0000dcd00000 m_RenameOverlay: m_UserAcceptedRename: 0 m_Name: @@ -279,10 +279,10 @@ MonoBehaviour: m_Children: [] m_Position: serializedVersion: 2 - x: 347.2 + x: 348 y: 0 - width: 771.99994 - height: 487.2 + width: 771.19995 + height: 486.4 m_MinSize: {x: 102, y: 121} m_MaxSize: {x: 4002, y: 4021} m_ActualView: {fileID: 2} @@ -312,10 +312,10 @@ MonoBehaviour: m_Tooltip: m_Pos: serializedVersion: 2 - x: 409.6 + x: 410.4 y: 73.6 - width: 769.99994 - height: 466.2 + width: 769.19995 + height: 465.4 m_SerializedDataModeController: m_DataMode: 0 m_PreferredDataMode: 0 @@ -356,9 +356,9 @@ MonoBehaviour: floating: 0 collapsed: 0 displayed: 1 - snapOffset: {x: -322, y: -280.8} + snapOffset: {x: -322, y: 24.8} snapOffsetDelta: {x: 0, y: 0} - snapCorner: 3 + snapCorner: 1 id: unity-scene-view-toolbar index: 0 layout: 1 @@ -635,9 +635,9 @@ MonoBehaviour: m_PlayAudio: 0 m_AudioPlay: 0 m_Position: - m_Target: {x: 2.4415243, y: -1.7079823, z: 2.0844522} + m_Target: {x: 3.9131052, y: -11.547329, z: 5.253002} speed: 2 - m_Value: {x: 2.4415243, y: -1.7079823, z: 2.0844522} + m_Value: {x: 3.9131052, y: -11.547329, z: 5.253002} m_RenderMode: 0 m_CameraMode: drawMode: 0 @@ -683,13 +683,13 @@ MonoBehaviour: m_GridAxis: 1 m_gridOpacity: 0.5 m_Rotation: - m_Target: {x: 0.22429028, y: -0.017527353, z: 0.0038717669, w: 0.97460735} + m_Target: {x: -0.5857513, y: -0.0031634637, z: 0.0022860928, w: -0.81048596} speed: 2 - m_Value: {x: 0.2242356, y: -0.017523078, z: 0.0038708227, w: 0.9743697} + m_Value: {x: -0.5857492, y: -0.0031634523, z: 0.0022860847, w: -0.81048304} m_Size: - m_Target: 3.4315991 + m_Target: 11.411661 speed: 2 - m_Value: 3.4315991 + m_Value: 11.411661 m_Ortho: m_Target: 0 speed: 2 @@ -730,9 +730,9 @@ MonoBehaviour: m_Position: serializedVersion: 2 x: 0 - y: 487.2 + y: 486.4 width: 1119.2 - height: 283.59998 + height: 284.4 m_MinSize: {x: 101, y: 121} m_MaxSize: {x: 4001, y: 4021} m_ActualView: {fileID: 11} @@ -763,9 +763,9 @@ MonoBehaviour: m_Pos: serializedVersion: 2 x: 62.4 - y: 560.8 + y: 560 width: 1118.2 - height: 262.59998 + height: 263.4 m_SerializedDataModeController: m_DataMode: 0 m_PreferredDataMode: 0 @@ -787,24 +787,24 @@ MonoBehaviour: m_SkipHidden: 0 m_SearchArea: 1 m_Folders: - - Assets/Scripts/UI + - Assets/Prefab/MapNodePrefab m_Globs: [] m_OriginalText: m_ImportLogFlags: 0 m_FilterByTypeIntersection: 0 m_ViewMode: 1 - m_StartGridSize: 64 + m_StartGridSize: 62 m_LastFolders: - - Assets/Scripts/UI - m_LastFoldersGridSize: -1 - m_LastProjectPath: D:\GitInventory_0330\test_45\ColorlessWorld-2024-4-2 + - Assets/Prefab/MapNodePrefab + m_LastFoldersGridSize: 62 + m_LastProjectPath: D:\GitInventory_0524\test_45\ColorlessWorld-2024-4-2 m_LockTracker: m_IsLocked: 0 m_FolderTreeState: - scrollPos: {x: 0, y: 141.40002} - m_SelectedIDs: 6e760000 - m_LastClickedID: 30318 - m_ExpandedIDs: 000000009a7400009c74000000ca9a3bffffff7f + scrollPos: {x: 0, y: 79} + m_SelectedIDs: 58070000 + m_LastClickedID: 1880 + m_ExpandedIDs: 000000000c060000cc0600000c07000000ca9a3bffffff7f m_RenameOverlay: m_UserAcceptedRename: 0 m_Name: @@ -832,7 +832,7 @@ MonoBehaviour: scrollPos: {x: 0, y: 0} m_SelectedIDs: m_LastClickedID: 0 - m_ExpandedIDs: 000000009a7400009c74000000ca9a3bffffff7f + m_ExpandedIDs: 000000000c06000000ca9a3bffffff7f m_RenameOverlay: m_UserAcceptedRename: 0 m_Name: @@ -857,9 +857,9 @@ MonoBehaviour: m_Icon: {fileID: 0} m_ResourceFile: m_ListAreaState: - m_SelectedInstanceIDs: 700d0000 - m_LastClickedInstanceID: 3440 - m_HadKeyboardFocusLastEvent: 1 + m_SelectedInstanceIDs: 4ad00000 + m_LastClickedInstanceID: 53322 + m_HadKeyboardFocusLastEvent: 0 m_ExpandedInstanceIDs: c6230000f06f00003a7b000058cc00005ecc00006ed400004e6e0000e07200000a7000000e7000000281000056cf00000000000094760000 m_RenameOverlay: m_UserAcceptedRename: 0 @@ -885,7 +885,7 @@ MonoBehaviour: m_ResourceFile: m_NewAssetIndexInList: -1 m_ScrollPosition: {x: 0, y: 0} - m_GridSize: 64 + m_GridSize: 62 m_SkipHiddenPackages: 0 m_DirectoriesAreaWidth: 207 --- !u!114 &11 @@ -910,9 +910,9 @@ MonoBehaviour: m_Pos: serializedVersion: 2 x: 62.4 - y: 560.8 + y: 560 width: 1118.2 - height: 262.59998 + height: 263.4 m_SerializedDataModeController: m_DataMode: 0 m_PreferredDataMode: 0 diff --git a/ColorlessWorld-2024-4-2/UserSettings/Search.index b/ColorlessWorld-2024-4-2/UserSettings/Search.index deleted file mode 100644 index dba62d53..00000000 --- a/ColorlessWorld-2024-4-2/UserSettings/Search.index +++ /dev/null @@ -1,13 +0,0 @@ -{ - "name": "Assets", - "roots": ["Assets"], - "includes": [], - "excludes": [], - "options": { - "types": true, - "properties": true, - "extended": false, - "dependencies": false - }, - "baseScore": 999 -} \ No newline at end of file diff --git a/ColorlessWorld-2024-4-2/UserSettings/Search.settings b/ColorlessWorld-2024-4-2/UserSettings/Search.settings index 8d4fbd54..9e26dfee 100644 --- a/ColorlessWorld-2024-4-2/UserSettings/Search.settings +++ b/ColorlessWorld-2024-4-2/UserSettings/Search.settings @@ -1,75 +1 @@ -trackSelection = true -refreshSearchWindowsInPlayMode = false -fetchPreview = true -defaultFlags = 0 -keepOpen = false -queryFolder = "Assets" -onBoardingDoNotAskAgain = true -showPackageIndexes = false -showStatusBar = false -scopes = { -} -providers = { - packages = { - active = true - priority = 90 - defaultAction = null - } - profilermarkers = { - active = false - priority = 100 - defaultAction = null - } - store = { - active = true - priority = 100 - defaultAction = null - } - log = { - active = false - priority = 210 - defaultAction = null - } - scene = { - active = true - priority = 50 - defaultAction = null - } - find = { - active = true - priority = 25 - defaultAction = null - } - performance = { - active = false - priority = 100 - defaultAction = null - } - adb = { - active = false - priority = 2500 - defaultAction = null - } - asset = { - active = true - priority = 25 - defaultAction = null - } -} -objectSelectors = { -} -recentSearches = [ -] -searchItemFavorites = [ -] -savedSearchesSortOrder = 0 -showSavedSearchPanel = false -hideTabs = false -expandedQueries = [ -] -queryBuilder = false -ignoredProperties = "id;name;classname;imagecontentshash" -helperWidgetCurrentArea = "all" -disabledIndexers = "" -minIndexVariations = 2 -findProviderIndexHelper = true \ No newline at end of file +{} \ No newline at end of file