This commit is contained in:
parent
7f7e9fbce1
commit
44cfb049fc
|
@ -53,6 +53,7 @@
|
|||
<Compile Include="Assets\HighlightPlus\Editor\TransparentWithDepth.cs" />
|
||||
<Compile Include="Assets\HighlightPlus\Editor\VRCheck.cs" />
|
||||
<Compile Include="Assets\Model\Fantastic City Generator\DayNight\Editor\DayNightEditor.cs" />
|
||||
<Compile Include="Assets\Editor\ScriptDescriptionEditor.cs" />
|
||||
<Compile Include="Assets\HighlightPlus\Editor\HighlightTriggerEditor.cs" />
|
||||
<Reference Include="UnityEngine">
|
||||
<HintPath>E:\Program Files\Unity 2022.3.22f1\Editor\Data\Managed\UnityEngine\UnityEngine.dll</HintPath>
|
||||
|
@ -309,6 +310,9 @@
|
|||
<Reference Include="UnityEditor.Graphs">
|
||||
<HintPath>E:\Program Files\Unity 2022.3.22f1\Editor\Data\Managed\UnityEditor.Graphs.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="UnityEditor.WebGL.Extensions">
|
||||
<HintPath>E:\Program Files\Unity 2022.3.22f1\Editor\Data\PlaybackEngines\WebGLSupport\UnityEditor.WebGL.Extensions.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="UnityEditor.WindowsStandalone.Extensions">
|
||||
<HintPath>E:\Program Files\Unity 2022.3.22f1\Editor\Data\PlaybackEngines\WindowsStandaloneSupport\UnityEditor.WindowsStandalone.Extensions.dll</HintPath>
|
||||
</Reference>
|
||||
|
|
|
@ -112,6 +112,7 @@
|
|||
<Compile Include="Assets\Standard Assets 1\Vehicles\Aircraft\Scripts\AeroplaneAudio.cs" />
|
||||
<Compile Include="Assets\Standard Assets 1\Utility\FPSCounter.cs" />
|
||||
<Compile Include="Assets\Standard Assets 1\Characters\FirstPersonCharacter\Scripts\MouseLook.cs" />
|
||||
<Compile Include="Assets\Scripts\ScriptDescriptionAttribute.cs" />
|
||||
<Compile Include="Assets\Standard Assets 1\Utility\CameraRefocus.cs" />
|
||||
<Compile Include="Assets\Standard Assets 1\CrossPlatformInput\Scripts\ButtonHandler.cs" />
|
||||
<Compile Include="Assets\Model\Fantastic City Generator\Water\WaterSample.cs" />
|
||||
|
@ -188,6 +189,7 @@
|
|||
<None Include="Assets\StreamingAssets\DataConfig\ToolsPackData.json" />
|
||||
<None Include="Assets\TextMesh Pro\Shaders\TMPro_Surface.cginc" />
|
||||
<None Include="Assets\HighlightPlus\Resources\HighlightPlus\HighlightComposeOutline.shader" />
|
||||
<None Include="Assets\StreamingAssets\DataConfig\TeachingData.json" />
|
||||
<None Include="Assets\TextMesh Pro\Resources\LineBreaking Following Characters.txt" />
|
||||
<None Include="Assets\HighlightPlus\Resources\HighlightPlus\HighlightOutline.shader" />
|
||||
<None Include="Assets\Framework\ThirdParty\NaughtyAttributes\package.json" />
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 39f6a98fe6694803aa57ec7a477aceb7
|
||||
timeCreated: 1717727458
|
|
@ -0,0 +1,54 @@
|
|||
using UnityEditor;
|
||||
using UnityEngine;
|
||||
|
||||
[CustomEditor(typeof(MonoBehaviour), true)]
|
||||
public class ScriptDescriptionEditor : Editor
|
||||
{
|
||||
private GUIStyle descriptionStyle;
|
||||
|
||||
private void OnEnable()
|
||||
{
|
||||
descriptionStyle = new GUIStyle(EditorStyles.label)
|
||||
{
|
||||
wordWrap = true,
|
||||
alignment = TextAnchor.MiddleCenter,
|
||||
normal = { background = MakeTex(2, 2, new Color(0.1509434f, 0.1473834f, 0.1473834f, 1f)), textColor = Color.white },
|
||||
padding = new RectOffset(10, 10, 10, 10),
|
||||
margin = new RectOffset(0, 0, 10, 10)
|
||||
};
|
||||
}
|
||||
|
||||
private Texture2D MakeTex(int width, int height, Color col)
|
||||
{
|
||||
Color[] pix = new Color[width * height];
|
||||
for (int i = 0; i < pix.Length; i++)
|
||||
pix[i] = col;
|
||||
Texture2D result = new Texture2D(width, height);
|
||||
result.SetPixels(pix);
|
||||
result.Apply();
|
||||
return result;
|
||||
}
|
||||
|
||||
public override void OnInspectorGUI()
|
||||
{
|
||||
// 获取目标脚本的类型
|
||||
var type = target.GetType();
|
||||
|
||||
// 获取 ScriptDescription 属性
|
||||
var descriptionAttribute = (ScriptDescriptionAttribute)System.Attribute.GetCustomAttribute(type, typeof(ScriptDescriptionAttribute));
|
||||
|
||||
// 如果属性存在,显示描述
|
||||
if (descriptionAttribute != null)
|
||||
{
|
||||
// EditorGUILayout.HelpBox(descriptionAttribute.Description, MessageType.Info);
|
||||
// EditorGUILayout.LabelField(descriptionAttribute.Description, EditorStyles.wordWrappedLabel);
|
||||
// EditorGUILayout.Space();
|
||||
|
||||
GUILayout.Label(descriptionAttribute.Description, descriptionStyle);
|
||||
|
||||
}
|
||||
|
||||
// 绘制默认的 Inspector
|
||||
DrawDefaultInspector();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
fileFormatVersion: 2
|
||||
guid: f3acec5d843d477ab43baf400e808867
|
||||
timeCreated: 1717727469
|
File diff suppressed because one or more lines are too long
|
@ -38,7 +38,7 @@ public class GameLauncher : MonoBehaviour
|
|||
CreateGameModules();
|
||||
|
||||
|
||||
// SceneManager.LoadScene("묏야쇌");
|
||||
//SceneManager.LoadScene("묏야쇌");
|
||||
}
|
||||
void Update()
|
||||
{
|
||||
|
|
|
@ -780,6 +780,140 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 415079788}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &435344339
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 435344340}
|
||||
- component: {fileID: 435344342}
|
||||
- component: {fileID: 435344341}
|
||||
m_Layer: 5
|
||||
m_Name: Text
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &435344340
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 435344339}
|
||||
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: 764280861}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: 3, y: -59.5}
|
||||
m_SizeDelta: {x: -5.9999, y: -119}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &435344341
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 435344339}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_text: New Text
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 703c5bf45144ac448a6d18fc3c044972, type: 2}
|
||||
m_sharedMaterial: {fileID: -8603090892031157933, guid: 703c5bf45144ac448a6d18fc3c044972, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
m_fontColor32:
|
||||
serializedVersion: 2
|
||||
rgba: 4278190080
|
||||
m_fontColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
m_enableVertexGradient: 0
|
||||
m_colorMode: 3
|
||||
m_fontColorGradient:
|
||||
topLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
topRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_fontColorGradientPreset: {fileID: 0}
|
||||
m_spriteAsset: {fileID: 0}
|
||||
m_tintAllSprites: 0
|
||||
m_StyleSheet: {fileID: 0}
|
||||
m_TextStyleHashCode: -1183493901
|
||||
m_overrideHtmlColors: 0
|
||||
m_faceColor:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontSize: 36
|
||||
m_fontSizeBase: 36
|
||||
m_fontWeight: 400
|
||||
m_enableAutoSizing: 0
|
||||
m_fontSizeMin: 18
|
||||
m_fontSizeMax: 72
|
||||
m_fontStyle: 0
|
||||
m_HorizontalAlignment: 1
|
||||
m_VerticalAlignment: 256
|
||||
m_textAlignment: 65535
|
||||
m_characterSpacing: 0
|
||||
m_wordSpacing: 0
|
||||
m_lineSpacing: 0
|
||||
m_lineSpacingMax: 0
|
||||
m_paragraphSpacing: 0
|
||||
m_charWidthMaxAdj: 0
|
||||
m_enableWordWrapping: 1
|
||||
m_wordWrappingRatios: 0.4
|
||||
m_overflowMode: 0
|
||||
m_linkedTextComponent: {fileID: 0}
|
||||
parentLinkedComponent: {fileID: 0}
|
||||
m_enableKerning: 1
|
||||
m_enableExtraPadding: 0
|
||||
checkPaddingRequired: 0
|
||||
m_isRichText: 1
|
||||
m_parseCtrlCharacters: 1
|
||||
m_isOrthographic: 1
|
||||
m_isCullingEnabled: 0
|
||||
m_horizontalMapping: 0
|
||||
m_verticalMapping: 0
|
||||
m_uvLineOffset: 0
|
||||
m_geometrySortingOrder: 0
|
||||
m_IsTextObjectScaleStatic: 0
|
||||
m_VertexBufferAutoSizeReduction: 0
|
||||
m_useMaxVisibleDescender: 1
|
||||
m_pageToDisplay: 1
|
||||
m_margin: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_isUsingLegacyAnimationComponent: 0
|
||||
m_isVolumetricText: 0
|
||||
m_hasFontAssetChanged: 0
|
||||
m_baseMaterial: {fileID: 0}
|
||||
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
|
||||
--- !u!222 &435344342
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 435344339}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &448721056
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -1772,8 +1906,8 @@ Canvas:
|
|||
m_OverrideSorting: 0
|
||||
m_OverridePixelPerfect: 0
|
||||
m_SortingBucketNormalizedSize: 0
|
||||
m_VertexColorAlwaysGammaSpace: 0
|
||||
m_AdditionalShaderChannelsFlag: 0
|
||||
m_VertexColorAlwaysGammaSpace: 1
|
||||
m_AdditionalShaderChannelsFlag: 25
|
||||
m_UpdateRectTransformForStandalone: 0
|
||||
m_SortingLayerID: 0
|
||||
m_SortingOrder: 0
|
||||
|
@ -1792,6 +1926,8 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 1013479121}
|
||||
- {fileID: 1801241091}
|
||||
- {fileID: 1245220569}
|
||||
- {fileID: 2109620457}
|
||||
m_Father: {fileID: 0}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
|
@ -2070,6 +2206,83 @@ MeshFilter:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 756157321}
|
||||
m_Mesh: {fileID: -7434549690534084444, guid: 156cca832bad49447b16a92685b1fa5b, type: 3}
|
||||
--- !u!1 &764280860
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 764280861}
|
||||
- component: {fileID: 764280863}
|
||||
- component: {fileID: 764280862}
|
||||
m_Layer: 5
|
||||
m_Name: BackGround
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &764280861
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 764280860}
|
||||
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:
|
||||
- {fileID: 435344340}
|
||||
- {fileID: 1494204031}
|
||||
m_Father: {fileID: 1245220569}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: -11}
|
||||
m_SizeDelta: {x: 820.7, y: 534.3}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &764280862
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 764280860}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 0}
|
||||
m_Type: 0
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &764280863
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 764280860}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1001 &822250774
|
||||
PrefabInstance:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -2377,7 +2590,7 @@ GameObject:
|
|||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &1013479121
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -2950,6 +3163,42 @@ RectTransform:
|
|||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: -20, y: -20}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!1 &1245220568
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1245220569}
|
||||
m_Layer: 5
|
||||
m_Name: "\u4EFB\u52A1\u4E66"
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
--- !u!224 &1245220569
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1245220568}
|
||||
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:
|
||||
- {fileID: 764280861}
|
||||
m_Father: {fileID: 587418715}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!1 &1331583476
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -3695,6 +3944,138 @@ Transform:
|
|||
- {fileID: 1617607508}
|
||||
m_Father: {fileID: 0}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: -241.93, z: 0}
|
||||
--- !u!1 &1494204030
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1494204031}
|
||||
- component: {fileID: 1494204034}
|
||||
- component: {fileID: 1494204033}
|
||||
- component: {fileID: 1494204032}
|
||||
m_Layer: 5
|
||||
m_Name: Close
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &1494204031
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1494204030}
|
||||
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: 764280861}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 391.92896, y: 249.92572}
|
||||
m_SizeDelta: {x: 36.8423, y: 34.4486}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &1494204032
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1494204030}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Navigation:
|
||||
m_Mode: 3
|
||||
m_WrapAround: 0
|
||||
m_SelectOnUp: {fileID: 0}
|
||||
m_SelectOnDown: {fileID: 0}
|
||||
m_SelectOnLeft: {fileID: 0}
|
||||
m_SelectOnRight: {fileID: 0}
|
||||
m_Transition: 1
|
||||
m_Colors:
|
||||
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
|
||||
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
|
||||
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
|
||||
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
|
||||
m_ColorMultiplier: 1
|
||||
m_FadeDuration: 0.1
|
||||
m_SpriteState:
|
||||
m_HighlightedSprite: {fileID: 0}
|
||||
m_PressedSprite: {fileID: 0}
|
||||
m_SelectedSprite: {fileID: 0}
|
||||
m_DisabledSprite: {fileID: 0}
|
||||
m_AnimationTriggers:
|
||||
m_NormalTrigger: Normal
|
||||
m_HighlightedTrigger: Highlighted
|
||||
m_PressedTrigger: Pressed
|
||||
m_SelectedTrigger: Selected
|
||||
m_DisabledTrigger: Disabled
|
||||
m_Interactable: 1
|
||||
m_TargetGraphic: {fileID: 1494204033}
|
||||
m_OnClick:
|
||||
m_PersistentCalls:
|
||||
m_Calls:
|
||||
- m_Target: {fileID: 1245220568}
|
||||
m_TargetAssemblyTypeName: UnityEngine.GameObject, UnityEngine
|
||||
m_MethodName: SetActive
|
||||
m_Mode: 6
|
||||
m_Arguments:
|
||||
m_ObjectArgument: {fileID: 0}
|
||||
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
|
||||
m_IntArgument: 0
|
||||
m_FloatArgument: 0
|
||||
m_StringArgument:
|
||||
m_BoolArgument: 0
|
||||
m_CallState: 2
|
||||
--- !u!114 &1494204033
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1494204030}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_Type: 1
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &1494204034
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1494204030}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &1524053069
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -5236,6 +5617,81 @@ Camera:
|
|||
m_OcclusionCulling: 1
|
||||
m_StereoConvergence: 10
|
||||
m_StereoSeparation: 0.022
|
||||
--- !u!1 &2109620456
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 2109620457}
|
||||
- component: {fileID: 2109620459}
|
||||
- component: {fileID: 2109620458}
|
||||
m_Layer: 5
|
||||
m_Name: Image
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &2109620457
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2109620456}
|
||||
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: 587418715}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 100, y: 100}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &2109620458
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2109620456}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 0.1509434, g: 0.1473834, b: 0.1473834, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 0}
|
||||
m_Type: 0
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &2109620459
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2109620456}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &2129569636
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
|
@ -6,6 +6,7 @@ using UnityEngine.UI;
|
|||
|
||||
namespace DefaultNamespace
|
||||
{
|
||||
[ScriptDescription("人物装备信息管理类")]
|
||||
public class CharacterEquipInfoManager : MonoBehaviour
|
||||
{
|
||||
public static CharacterEquipInfoManager Instance;
|
||||
|
|
|
@ -10,6 +10,7 @@ namespace DefaultNamespace
|
|||
/// <summary>
|
||||
/// 人物窗口装备管理器
|
||||
/// </summary>
|
||||
[ScriptDescription("人物窗口装备管理器")]
|
||||
public class CharacterEquipManager : MonoBehaviour
|
||||
{
|
||||
public static CharacterEquipManager Instance;
|
||||
|
|
|
@ -9,6 +9,7 @@ namespace DefaultNamespace
|
|||
/// <summary>
|
||||
/// 创建检查的背包工具UI
|
||||
/// </summary>
|
||||
[ScriptDescription("人物装备窗口管理类,打开窗口左侧物品栏通过背包获取")]
|
||||
public class CharacterEquipWindowManager : MonoBehaviour
|
||||
{
|
||||
private Dictionary<string, List<GameObject>> _toolsNames;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using MotionFramework;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using UnityEngine;
|
||||
|
||||
|
@ -8,12 +9,18 @@ namespace DefaultNamespace
|
|||
{
|
||||
public class DataConfigManager : ModuleSingleton<DataConfigManager>, IModule
|
||||
{
|
||||
private Dictionary<string, List<string>> toolsPackDict;
|
||||
private string ToolsPackDataPath = Application.streamingAssetsPath + "/DataConfig/ToolsPackData.json"; //工具包
|
||||
private string TeachingDataPath = Application.streamingAssetsPath + "/DataConfig/TeachingData.json"; //教学工具包设备高亮数据
|
||||
|
||||
|
||||
private Dictionary<string, List<string>> toolsPackDict;
|
||||
private List<string> teachingData;
|
||||
|
||||
public void OnCreate(object createParam)
|
||||
{
|
||||
LoadConfig();
|
||||
|
||||
LoadTeachingData();
|
||||
}
|
||||
|
||||
public void OnUpdate()
|
||||
|
@ -26,36 +33,32 @@ namespace DefaultNamespace
|
|||
|
||||
public void OnGUI()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public List<string> GetToolsPackData(string toolsName)
|
||||
/// <summary>
|
||||
/// 获取教学工具包设备高亮数据
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public List<string> GetTeachingData()
|
||||
{
|
||||
foreach (var v in toolsPackDict)
|
||||
{
|
||||
if (v.Key == toolsName)
|
||||
{
|
||||
if (v.Value.Count > 0)
|
||||
{
|
||||
return v.Value;
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
return teachingData;
|
||||
}
|
||||
|
||||
|
||||
private void LoadTeachingData()
|
||||
{
|
||||
string jsonContent = File.ReadAllText(ToolsPackDataPath);
|
||||
teachingData = JsonConvert.DeserializeObject<List<string>>(jsonContent);
|
||||
foreach (var tool in teachingData)
|
||||
{
|
||||
Debug.Log("Tool model: " + tool);
|
||||
}
|
||||
}
|
||||
|
||||
private void LoadConfig()
|
||||
{
|
||||
string path = Application.streamingAssetsPath + "/DataConfig/ToolsPackData.json";
|
||||
if (File.Exists(path))
|
||||
if (File.Exists(ToolsPackDataPath))
|
||||
{
|
||||
string jsonContent = File.ReadAllText(path);
|
||||
string jsonContent = File.ReadAllText(ToolsPackDataPath);
|
||||
JObject jsonObj = JObject.Parse(jsonContent);
|
||||
|
||||
toolsPackDict = new Dictionary<string, List<string>>();
|
||||
|
@ -81,6 +84,27 @@ namespace DefaultNamespace
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
public List<string> GetToolsPackData(string toolsName)
|
||||
{
|
||||
foreach (var v in toolsPackDict)
|
||||
{
|
||||
if (v.Key == toolsName)
|
||||
{
|
||||
if (v.Value.Count > 0)
|
||||
{
|
||||
return v.Value;
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
void ParseTools(JArray models)
|
||||
{
|
||||
foreach (var model in models)
|
||||
|
@ -111,6 +135,7 @@ namespace DefaultNamespace
|
|||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
ParseTools(subItems as JArray); // 递归解析子对象
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
using System;
|
||||
using UnityEngine;
|
||||
[AttributeUsage(AttributeTargets.Class, Inherited = false, AllowMultiple = false)]
|
||||
public class ScriptDescriptionAttribute : PropertyAttribute
|
||||
{
|
||||
public string Description;
|
||||
|
||||
public ScriptDescriptionAttribute(string description)
|
||||
{
|
||||
Description = description;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 6e2f9697492a4143b3541edea3c9ca5f
|
||||
timeCreated: 1717727478
|
|
@ -6,6 +6,7 @@ using UnityEngine.Serialization;
|
|||
|
||||
namespace DefaultNamespace
|
||||
{
|
||||
[ScriptDescription("工具间的选择类,除了工具间场景,其他场景应选择:其他")]
|
||||
public class ToolsPackSceneManager : MonoBehaviour
|
||||
{
|
||||
[SerializeField] private ToolsPackScene toolsPackScene;
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
[{
|
||||
"model": "螺丝刀"
|
||||
},{
|
||||
"model": "剥线钳"
|
||||
},{
|
||||
"model": "绝缘胶带"
|
||||
},{
|
||||
"model": "验电笔"
|
||||
},{
|
||||
"model": "盒装封印"
|
||||
}]
|
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 5a951d4fb94d42c40ace3dc705a59da3
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Loading…
Reference in New Issue