Merge branch 'develop' into feature/HP_jump

This commit is contained in:
Tungdv
2025-12-25 18:15:49 +07:00
50 changed files with 44821 additions and 107 deletions
+8
View File
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 296cac0f54860484f8e9c81696536cf2
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Binary file not shown.
+7
View File
@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 4e7b437eecb43c64b87ab9700f5850c9
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Binary file not shown.
+7
View File
@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 6e02334765e10654e874714298f4eef1
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Binary file not shown.
+7
View File
@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 98b87a70ddccda2459742976c2b90262
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
@@ -13,6 +13,7 @@ MonoBehaviour:
m_Name: AddressableAssetGroupSortSettings
m_EditorClassIdentifier:
sortOrder:
- 402389c9c8797a8489a1d8188e497c23
- 17b5850382b624d15a322e51c0b9b7c7
- af2f31e34f6644749bdd552abb39cb07
- 712e3991f28e549e7a56ee582a977810
@@ -15,7 +15,7 @@ MonoBehaviour:
m_DefaultGroup: 712e3991f28e549e7a56ee582a977810
m_currentHash:
serializedVersion: 2
Hash: 0d3b7a355df1b84783b0b7d14e952d8a
Hash: 75ec376e740cf6f59bbbadec6b866c16
m_OptimizeCatalogSize: 0
m_BuildRemoteCatalog: 0
m_CatalogRequestsTimeout: 0
@@ -61,6 +61,7 @@ MonoBehaviour:
m_overridePlayerVersion: '[UnityEditor.PlayerSettings.bundleVersion]'
m_GroupAssets:
- {fileID: 11400000, guid: ba28219cd9e2e4e51817178f840965e8, type: 2}
- {fileID: 11400000, guid: 0759296650e322743affabf844e4f32a, type: 2}
- {fileID: 11400000, guid: 86ad1216662b54841a182d663f54030d, type: 2}
- {fileID: 11400000, guid: 5c7374bc56a9447e88024b8d10f93d58, type: 2}
m_BuildSettings:
@@ -0,0 +1,48 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
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: e5d17a21594effb4e9591490b009e7aa, type: 3}
m_Name: configuration_BundledAssetGroupSchema
m_EditorClassIdentifier:
m_Group: {fileID: 11400000, guid: 0759296650e322743affabf844e4f32a, type: 2}
m_InternalBundleIdMode: 1
m_Compression: 1
m_IncludeAddressInCatalog: 1
m_IncludeGUIDInCatalog: 1
m_IncludeLabelsInCatalog: 1
m_InternalIdNamingMode: 0
m_CacheClearBehavior: 0
m_IncludeInBuild: 1
m_BundledAssetProviderType:
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.BundledAssetProvider
m_StripDownloadOptions: 0
m_ForceUniqueProvider: 0
m_UseAssetBundleCache: 1
m_UseAssetBundleCrc: 1
m_UseAssetBundleCrcForCachedBundles: 1
m_UseUWRForLocalBundles: 0
m_Timeout: 0
m_ChunkedTransfer: 0
m_RedirectLimit: -1
m_RetryCount: 0
m_BuildPath:
m_Id: 506465302ec864e8eb6eb8e0d2ee7b2c
m_LoadPath:
m_Id: 71015b41342024feebebb329061472f1
m_BundleMode: 0
m_AssetBundleProviderType:
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.AssetBundleProvider
m_UseDefaultSchemaSettings: 0
m_SelectedPathPairIndex: 0
m_BundleNaming: 0
m_AssetLoadMode: 0
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: bb578b99e8094cb47b2525487f7c2ff6
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,16 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
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: 5834b5087d578d24c926ce20cd31e6d6, type: 3}
m_Name: configuration_ContentUpdateGroupSchema
m_EditorClassIdentifier:
m_Group: {fileID: 11400000, guid: 0759296650e322743affabf844e4f32a, type: 2}
m_StaticContent: 0
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 2dd3fabc7c9772049999c2bb26625097
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,38 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
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: bbb281ee3bf0b054c82ac2347e9e782c, type: 3}
m_Name: configuration
m_EditorClassIdentifier:
m_GroupName: configuration
m_GUID: 402389c9c8797a8489a1d8188e497c23
m_SerializeEntries:
- m_GUID: 4e7b437eecb43c64b87ab9700f5850c9
m_Address: Assets/Addressable/elements.txt
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 6e02334765e10654e874714298f4eef1
m_Address: Assets/Addressable/gshop.txt
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 98b87a70ddccda2459742976c2b90262
m_Address: Assets/Addressable/gshop1.txt
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
m_ReadOnly: 0
m_Settings: {fileID: 11400000, guid: 070edb522e6e54c14a99055900003890, type: 2}
m_SchemaSet:
m_Schemas:
- {fileID: 11400000, guid: bb578b99e8094cb47b2525487f7c2ff6, type: 2}
- {fileID: 11400000, guid: 2dd3fabc7c9772049999c2bb26625097, type: 2}
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 0759296650e322743affabf844e4f32a
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:
+8
View File
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 44a578080cbfcfd4e9ff349d2bab2ac2
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 92e9c4056b1adfc49b730ee033f46a50
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,189 @@
%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: flare007
m_Shader: {fileID: 4800000, guid: 0a016a83287664641b867743f19faf14, type: 3}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords: []
m_InvalidKeywords:
- _DISSOLVETEXAR_ON
- _DISTORTTEXAR_ON
- _MASKTEXAR_ON
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses:
- MOTIONVECTORS
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
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}
- _DissolveTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DistortTex:
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: 772336b58515afd47947731c852261e0, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MaskTex:
m_Texture: {fileID: 0}
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:
- _AddPrecomputedVelocity: 0
- _AlphaClip: 0
- _AlphaCutoff: 0.5
- _AlphaToMask: 0
- _Blend: 0
- _BlendMode: 1
- _BlendModePreserveSpecular: 1
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _CullMode: 0
- _CustomDissolve: 0
- _CustomMainTex: 0
- _Cutoff: 0.5
- _DepthFade: 1
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DissolveFactor: 0
- _DissolveSoft: 0.1
- _DissolveTexAR: 1
- _DissolveTexUSpeed: 0
- _DissolveTexVSpeed: 0
- _DissolveWide: 0.05
- _DistortDissolveTex: 0
- _DistortFactor: 0
- _DistortMainTex: 0
- _DistortMaskTex: 0
- _DistortTexAR: 1
- _DistortTexUSpeed: 0
- _DistortTexVSpeed: 0
- _Dst: 1
- _DstBlend: 0
- _DstBlendAlpha: 0
- _EnvironmentReflections: 1
- _FDepth: 0
- _FDissolveTex: 0
- _FDistortTex: 0
- _FFnl: 0
- _FMaskTex: 0
- _FnlPower: 1
- _FnlScale: 0
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _MainAlpha: 1
- _MainTexAR: 0
- _MainTexUSpeed: 0
- _MainTexVSpeed: 0
- _MaskTexAR: 1
- _MaskTexUSpeed: 0
- _MaskTexVSpeed: 0
- _Metallic: 0
- _OcclusionStrength: 1
- _Parallax: 0.005
- _QueueOffset: 0
- _ReFnl: 0
- _ReceiveShadows: 1
- _Scr: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _SrcBlendAlpha: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _DissolveColor: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _FnlColor: {r: 1, g: 1, b: 1, a: 1}
- _MainColor: {r: 5.3403134, g: 5.3403134, b: 5.3403134, a: 1}
- _SpecColor: {r: 0.2, g: 0.2, b: 0.2, a: 1}
m_BuildTextureStacks: []
m_AllowLocking: 1
--- !u!114 &8741123340869993700
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: 9
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 3043e6b7cf19c4e49a3a39c5ae46303d
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,189 @@
%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: jianguang
m_Shader: {fileID: 4800000, guid: 0a016a83287664641b867743f19faf14, type: 3}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords: []
m_InvalidKeywords:
- _DISSOLVETEXAR_ON
- _DISTORTTEXAR_ON
- _MASKTEXAR_ON
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses:
- MOTIONVECTORS
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
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}
- _DissolveTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DistortTex:
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: 1677de469522e70429446c88d4cffde6, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MaskTex:
m_Texture: {fileID: 0}
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:
- _AddPrecomputedVelocity: 0
- _AlphaClip: 0
- _AlphaCutoff: 0.5
- _AlphaToMask: 0
- _Blend: 0
- _BlendMode: 1
- _BlendModePreserveSpecular: 1
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _CullMode: 0
- _CustomDissolve: 0
- _CustomMainTex: 0
- _Cutoff: 0.5
- _DepthFade: 1
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DissolveFactor: 0
- _DissolveSoft: 0.1
- _DissolveTexAR: 1
- _DissolveTexUSpeed: 0
- _DissolveTexVSpeed: 0
- _DissolveWide: 0.05
- _DistortDissolveTex: 0
- _DistortFactor: 0
- _DistortMainTex: 0
- _DistortMaskTex: 0
- _DistortTexAR: 1
- _DistortTexUSpeed: 0
- _DistortTexVSpeed: 0
- _Dst: 1
- _DstBlend: 0
- _DstBlendAlpha: 0
- _EnvironmentReflections: 1
- _FDepth: 0
- _FDissolveTex: 0
- _FDistortTex: 0
- _FFnl: 0
- _FMaskTex: 0
- _FnlPower: 1
- _FnlScale: 0
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _MainAlpha: 1
- _MainTexAR: 0
- _MainTexUSpeed: 0
- _MainTexVSpeed: 0
- _MaskTexAR: 1
- _MaskTexUSpeed: 0
- _MaskTexVSpeed: 0
- _Metallic: 0
- _OcclusionStrength: 1
- _Parallax: 0.005
- _QueueOffset: 0
- _ReFnl: 0
- _ReceiveShadows: 1
- _Scr: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _SrcBlendAlpha: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _DissolveColor: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _FnlColor: {r: 1, g: 1, b: 1, a: 1}
- _MainColor: {r: 5.3403134, g: 5.3403134, b: 5.3403134, a: 1}
- _SpecColor: {r: 0.2, g: 0.2, b: 0.2, a: 1}
m_BuildTextureStacks: []
m_AllowLocking: 1
--- !u!114 &8741123340869993700
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: 9
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 46015077c5d3c0545a29f15b423d136c
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,189 @@
%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: ray012
m_Shader: {fileID: 4800000, guid: 0a016a83287664641b867743f19faf14, type: 3}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords: []
m_InvalidKeywords:
- _DISSOLVETEXAR_ON
- _DISTORTTEXAR_ON
- _MASKTEXAR_ON
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses:
- MOTIONVECTORS
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
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}
- _DissolveTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DistortTex:
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: f575aa063b9a30d428b5b3302fbb3b38, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MaskTex:
m_Texture: {fileID: 0}
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:
- _AddPrecomputedVelocity: 0
- _AlphaClip: 0
- _AlphaCutoff: 0.5
- _AlphaToMask: 0
- _Blend: 0
- _BlendMode: 1
- _BlendModePreserveSpecular: 1
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _CullMode: 0
- _CustomDissolve: 0
- _CustomMainTex: 0
- _Cutoff: 0.5
- _DepthFade: 1
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DissolveFactor: 0
- _DissolveSoft: 0.1
- _DissolveTexAR: 1
- _DissolveTexUSpeed: 0
- _DissolveTexVSpeed: 0
- _DissolveWide: 0.05
- _DistortDissolveTex: 0
- _DistortFactor: 0
- _DistortMainTex: 0
- _DistortMaskTex: 0
- _DistortTexAR: 1
- _DistortTexUSpeed: 0
- _DistortTexVSpeed: 0
- _Dst: 1
- _DstBlend: 0
- _DstBlendAlpha: 0
- _EnvironmentReflections: 1
- _FDepth: 0
- _FDissolveTex: 0
- _FDistortTex: 0
- _FFnl: 0
- _FMaskTex: 0
- _FnlPower: 1
- _FnlScale: 0
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _MainAlpha: 1
- _MainTexAR: 0
- _MainTexUSpeed: 0
- _MainTexVSpeed: 0
- _MaskTexAR: 1
- _MaskTexUSpeed: 0
- _MaskTexVSpeed: 0
- _Metallic: 0
- _OcclusionStrength: 1
- _Parallax: 0.005
- _QueueOffset: 0
- _ReFnl: 0
- _ReceiveShadows: 1
- _Scr: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _SrcBlendAlpha: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _DissolveColor: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _FnlColor: {r: 1, g: 1, b: 1, a: 1}
- _MainColor: {r: 5.3403134, g: 5.3403134, b: 5.3403134, a: 1}
- _SpecColor: {r: 0.2, g: 0.2, b: 0.2, a: 1}
m_BuildTextureStacks: []
m_AllowLocking: 1
--- !u!114 &8741123340869993700
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: 9
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 1d8a3d90e2b2f0b49b9d3106d6127c92
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:
+1 -1
View File
@@ -88,7 +88,7 @@ ModelImporter:
armStretch: 0.05
legStretch: 0.05
feetSpacing: 0
globalScale: 1
globalScale: 0.01
rootMotionBoneName:
hasTranslationDoF: 0
hasExtraRoot: 0
+8
View File
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: a51734c05bc583f46a7f7f8c04f24940
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5407429d268e9bf4a8be2e039d04278e
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,21 @@
fileFormatVersion: 2
guid: 772336b58515afd47947731c852261e0
IHVImageFormatImporter:
externalObjects: {}
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 0
wrapV: 0
wrapW: 0
isReadable: 0
sRGBTexture: 1
streamingMipmaps: 0
streamingMipmapsPriority: 0
ignoreMipmapLimit: 0
mipmapLimitGroupName:
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,21 @@
fileFormatVersion: 2
guid: 1677de469522e70429446c88d4cffde6
IHVImageFormatImporter:
externalObjects: {}
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 0
wrapV: 0
wrapW: 0
isReadable: 0
sRGBTexture: 1
streamingMipmaps: 0
streamingMipmapsPriority: 0
ignoreMipmapLimit: 0
mipmapLimitGroupName:
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,21 @@
fileFormatVersion: 2
guid: f575aa063b9a30d428b5b3302fbb3b38
IHVImageFormatImporter:
externalObjects: {}
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 0
wrapV: 0
wrapW: 0
isReadable: 0
sRGBTexture: 1
streamingMipmaps: 0
streamingMipmapsPriority: 0
ignoreMipmapLimit: 0
mipmapLimitGroupName:
userData:
assetBundleName:
assetBundleVariant:
@@ -287,7 +287,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 0.2
scalar: 0.08
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -5120,7 +5120,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 0.3
scalar: 0.12
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -9953,7 +9953,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 1.75
scalar: 0.7
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -14871,7 +14871,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 0.1
scalar: 0.04
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -14924,7 +14924,7 @@ ParticleSystem:
startSizeY:
serializedVersion: 2
minMaxState: 0
scalar: 2
scalar: 0.8
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -19704,7 +19704,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 0.4
scalar: 0.16
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -24537,7 +24537,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 0.08
scalar: 0.032
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -24590,7 +24590,7 @@ ParticleSystem:
startSizeY:
serializedVersion: 2
minMaxState: 0
scalar: 1
scalar: 0.4
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -29379,7 +29379,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 2.5
scalar: 1
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -34279,7 +34279,7 @@ ParticleSystem:
startSize:
serializedVersion: 2
minMaxState: 0
scalar: 1.75
scalar: 0.7
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -34332,7 +34332,7 @@ ParticleSystem:
startSizeY:
serializedVersion: 2
minMaxState: 0
scalar: 0.75
scalar: 0.3
minScalar: 1
maxCurve:
serializedVersion: 2
@@ -1,11 +1,11 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using UnityEngine;
using UnityEngine.AddressableAssets;
using UnityEngine.AddressableAssets.ResourceLocators;
using UnityEngine.ResourceManagement.AsyncOperations;
using UnityEngine.ResourceManagement.ResourceLocations;
namespace BrewMonster.Scripts
{
@@ -14,6 +14,7 @@ namespace BrewMonster.Scripts
private bool _isInitialized = false;
private Dictionary<string, AsyncOperationHandle<GameObject>> _loadedAssets = new();
private Dictionary<string, AsyncOperationHandle<TextAsset>> _loadedTextAssets = new();
public event Action OnDispose;
protected override void Initialize()
@@ -23,6 +24,11 @@ namespace BrewMonster.Scripts
Addressables.InitializeAsync().Completed += OnInitializeComplete;
}
public bool IsInitialized()
{
return _isInitialized;
}
void OnInitializeComplete(AsyncOperationHandle<IResourceLocator> handle)
{
if (handle.Status == AsyncOperationStatus.Succeeded)
@@ -37,6 +43,132 @@ namespace BrewMonster.Scripts
}
}
/// <summary>
/// Load a text asset asynchronously.
/// NOTE: The key must match the Addressables "Address" (or another valid key like a label/GUID).
/// </summary>
/// <typeparam name="T"></typeparam>
/// <param name="assetPath"></param>
/// <returns></returns>
public async Task<TextAsset> LoadTextAssetAsync(string assetPath)
{
if (_loadedTextAssets.ContainsKey(assetPath))
{
return _loadedTextAssets[assetPath].Result;
}
try
{
// First, try the key exactly as provided. If it doesn't exist in the catalog,
// fall back to common project conventions (e.g. full Asset path).
foreach (var key in GetCandidateKeys(assetPath))
{
var locationsHandle = Addressables.LoadResourceLocationsAsync(key, typeof(TextAsset));
await locationsHandle.Task;
if (locationsHandle.Status != AsyncOperationStatus.Succeeded || locationsHandle.Result == null || locationsHandle.Result.Count == 0)
{
Addressables.Release(locationsHandle);
continue;
}
Addressables.Release(locationsHandle);
var handle = Addressables.LoadAssetAsync<TextAsset>(key);
await handle.Task;
if (handle.Status == AsyncOperationStatus.Succeeded && handle.Result != null)
{
_loadedTextAssets[assetPath] = handle;
return handle.Result;
}
// If load failed, release and try next candidate.
if (handle.IsValid())
{
Addressables.Release(handle);
}
}
BMLogger.LogError($"AddressableManager: No Location found for TextAsset key='{assetPath}'. " +
$"Tried: {string.Join(", ", GetCandidateKeys(assetPath).Select(k => $"'{k}'"))}");
LogSimilarKeys(assetPath);
return null;
}
catch (Exception e)
{
BMLogger.LogError($"AddressableManager: Failed to load TextAsset '{assetPath}': {e}");
return null;
}
}
private static IEnumerable<string> GetCandidateKeys(string assetPath)
{
if (string.IsNullOrWhiteSpace(assetPath))
{
yield break;
}
// Exact key (what caller asked for)
yield return assetPath;
// Common fallback used by this repo's Addressables settings: full asset path address.
// Example in `Assets/AddressableAssetsData/AssetGroups/configuration.asset`:
// m_Address: Assets/Addressable/elements.txt
if (!assetPath.Contains("/") && !assetPath.Contains("\\"))
{
yield return $"Assets/Addressable/{assetPath}";
}
}
private static void LogSimilarKeys(string needle)
{
// Helpful diagnostics in dev builds: show a few keys containing the substring.
try
{
var lower = needle?.ToLowerInvariant();
if (string.IsNullOrEmpty(lower))
{
return;
}
const int max = 20;
var matches = new List<string>(max);
foreach (var locator in Addressables.ResourceLocators)
{
foreach (var keyObj in locator.Keys)
{
if (keyObj is not string keyStr)
{
continue;
}
if (!keyStr.ToLowerInvariant().Contains(lower))
{
continue;
}
matches.Add(keyStr);
if (matches.Count >= max)
{
goto Done;
}
}
}
Done:
if (matches.Count > 0)
{
BMLogger.LogWarning($"AddressableManager: Similar Addressables keys for '{needle}': {string.Join(", ", matches)}");
}
}
catch
{
// ignore diagnostics failures
}
}
/// <summary>
/// Load an asset asynchronously. The address should look like this: "models/npcs/npc/魅灵首领/魅灵首领/魅灵首领.prefab"
/// </summary>
@@ -67,7 +67,7 @@ public class AAssit
/// re-seeked before reading the count and each element.</param>
/// <typeparam name="T">Element type to deserialize. Must be blittable/marshallable via <see cref="Marshal.PtrToStructure(System.IntPtr,System.Type)"/>.</typeparam>
/// <returns>The populated array when <c>count</c> > 0; otherwise null.</returns>
public static T[] ReadArrayPointerFromBinary<T>(FileStream stream, ref long readBytes, long fileOffset = -1)
public static T[] ReadArrayPointerFromBinary<T>(Stream stream, ref long readBytes, long fileOffset = -1)
{
// seek to the fileOffset if it's >= 0
if (fileOffset >= 0)
@@ -112,7 +112,7 @@ public class AAssit
return buffer;
}
public static bool GetBoolFromFileStream(FileStream fs, ref long readBytes)
public static bool GetBoolFromFileStream(Stream fs, ref long readBytes)
{
byte[] buffer = new byte[1];
int bytesRead = fs.Read(buffer, 0, 1);
@@ -123,7 +123,7 @@ public class AAssit
return buffer[0] != 0;
}
public static int GetIntFromFileStream(FileStream fs, ref long readBytes)
public static int GetIntFromFileStream(Stream fs, ref long readBytes)
{
byte[] buffer = new byte[4];
int bytesRead = fs.Read(buffer, 0, 4);
@@ -134,7 +134,7 @@ public class AAssit
return BitConverter.ToInt32(buffer, 0);
}
public static uint GetUIntFromFileStream(FileStream fs, ref long readBytes)
public static uint GetUIntFromFileStream(Stream fs, ref long readBytes)
{
byte[] buffer = new byte[4];
int bytesRead = fs.Read(buffer, 0, 4);
@@ -145,7 +145,7 @@ public class AAssit
return BitConverter.ToUInt32(buffer, 0);
}
public static long GetLongFromFileStream(FileStream fs, ref long readBytes)
public static long GetLongFromFileStream(Stream fs, ref long readBytes)
{
byte[] buffer = new byte[8];
int bytesRead = fs.Read(buffer, 0, 8);
@@ -1,4 +1,6 @@
using System;
using BrewMonster.Scripts;
using Cysharp.Threading.Tasks;
using ModelRenderer.Scripts.GameData;
using UnityEngine;
@@ -15,12 +17,21 @@ namespace BrewMonster
}
public async void Initialize()
{
await InitializeInternal();
}
public async UniTask InitializeInternal()
{
_elementDataMan = new();
_instance = this;
try
{
while (!AddressableManager.Instance.IsInitialized())
{
await UniTask.DelayFrame(1);
}
var result = await _elementDataMan.load_data();
if (result == -1)
{
@@ -1,4 +1,6 @@
using BrewMonster;
using BrewMonster.Scripts;
using Cysharp.Threading.Tasks;
using System.Collections.Generic;
using System.IO;
using System.Text;
@@ -300,26 +302,36 @@ namespace ModelRenderer.Scripts.GameData
return true;
}
public async Task<int> load_data(string pathname = "")
public async UniTask<int> load_data(string pathname = "")
{
#if UNITY_ANDROID && !UNITY_EDITOR
var success = await MoveElementFileToPersistentPath();
if (!success)
// #if UNITY_ANDROID && !UNITY_EDITOR
// var success = await MoveElementFileToPersistentPath();
// if (!success)
// {
// BMLogger.LogError("ElementDataMan: Failed to move element file to persistent path");
// return -1;
// }
// pathname = Path.Combine(UnityEngine.Application.persistentDataPath, "elements.data");
// #endif
// if (string.IsNullOrEmpty(pathname))
// {
// pathname = Path.Combine(UnityEngine.Application.streamingAssetsPath, "elements.data");
// }
// if (!File.Exists(pathname)) return -1;
// Addressables key must match the configured "Address". This repo currently uses full asset paths
// (see `Assets/AddressableAssetsData/AssetGroups/configuration.asset`).
// `AddressableManager.LoadTextAssetAsync` also has fallbacks, so "elements.txt" will work too.
var dataFile = await AddressableManager.Instance.LoadTextAssetAsync("Assets/Addressable/elements.txt");
if (dataFile == null)
{
BMLogger.LogError("ElementDataMan: Failed to move element file to persistent path");
BMLogger.LogError("ElementDataMan: Failed to load Addressable TextAsset for elements data.");
return -1;
}
pathname = Path.Combine(UnityEngine.Application.persistentDataPath, "elements.data");
#endif
if (string.IsNullOrEmpty(pathname))
{
pathname = Path.Combine(UnityEngine.Application.streamingAssetsPath, "elements.data");
}
if (!File.Exists(pathname)) return -1;
using (var file = new FileStream(pathname, FileMode.Open, FileAccess.Read))
using (var file = new MemoryStream(dataFile.bytes))
{
long dwRead = 0;
int version = AAssit.GetIntFromFileStream(file, ref dwRead);
@@ -1,3 +1,4 @@
#if UNITY_EDITOR
using System.Collections.Generic;
using UnityEditor;
@@ -45,3 +46,4 @@ namespace BrewMonster
}
}
#endif
+1 -1
View File
@@ -27,7 +27,7 @@ namespace BrewMonster
}
public static void LogMono(object source, string message)
{
#if ENALBE_LOGGING
#if ENALBE_LOGGING && UNITY_EDITOR
if (DebugRegistry.IsEnabled(source))
UnityEngine.Debug.LogError($"[{source}] {message}");
#endif
@@ -3924,8 +3924,8 @@ namespace BrewMonster
public int num_option; // number of options
public option[] options; // options pointer
public void Read(FileStream file)
public void Read(Stream file)
{
long dwRead = file.Position;
id = AAssit.GetIntFromFileStream(file, ref dwRead);
@@ -3943,7 +3943,7 @@ namespace BrewMonster
public window[] windows; // windows pointer
public void Read(FileStream file)
public void Read(Stream file)
{
long dwRead = file.Position;
id_talk = AAssit.GetUIntFromFileStream(file, ref dwRead);
@@ -2,108 +2,74 @@ using System;
using System.Collections.Generic;
using System.IO;
using BrewMonster;
using BrewMonster.Scripts;
using Cysharp.Threading.Tasks;
using UnityEngine;
using UnityEngine.Networking;
public class GShopLoader : MonoBehaviour
{
[Header("File Paths")]
public string gshopDataPath = "gshop.data";
public string gshop1DataPath = "gshop1.data";
// Addressables-only: do NOT load gshop/gshop1 from file system paths.
// These must match the configured Addressables "Address" values in
// `Assets/AddressableAssetsData/AssetGroups/configuration.asset`.
private const string GSHOP_ADDRESS = "Assets/Addressable/gshop.txt";
private const string GSHOP1_ADDRESS = "Assets/Addressable/gshop1.txt";
[Header("Loaded Data")]
public GShopData primaryShop = new GShopData();
public GShopData secondaryShop = new GShopData();
async void Start()
{
#if UNITY_ANDROID && !UNITY_EDITOR
bool result = await MoveShopDataToPersistentPath();
if (!result)
// Wait for AddressableManager to be initialized
while (!AddressableManager.Instance.IsInitialized())
{
BMLogger.LogError($"ElementDataMan: Failed to move element file to persistent path");
return;
await UniTask.DelayFrame(1);
}
#endif
LoadGShopData();
}
public async UniTask<bool> MoveShopDataToPersistentPath()
{
var destinationPath = Path.Combine(UnityEngine.Application.persistentDataPath, gshopDataPath);
var sourcePath = Path.Combine(UnityEngine.Application.streamingAssetsPath, gshopDataPath);
if (!File.Exists(destinationPath))
{
UnityWebRequest request = UnityWebRequest.Get(sourcePath);
await request.SendWebRequest();
if (request.result != UnityWebRequest.Result.Success)
{
BMLogger.LogError($"ElementDataMan: Failed to move element file to persistent path: {request.error}");
return false;
}
File.WriteAllBytes(destinationPath, request.downloadHandler.data);
}
BMLogger.Log($"ElementDataMan: Successfully moved element file to persistent path: {destinationPath}");
destinationPath = Path.Combine(UnityEngine.Application.persistentDataPath, gshop1DataPath);
sourcePath = Path.Combine(UnityEngine.Application.streamingAssetsPath, gshop1DataPath);
if (!File.Exists(destinationPath))
{
var request = UnityWebRequest.Get(sourcePath);
await request.SendWebRequest();
if (request.result != UnityWebRequest.Result.Success)
{
BMLogger.LogError($"ElementDataMan: Failed to move element file to persistent path: {request.error}");
return false;
}
File.WriteAllBytes(destinationPath, request.downloadHandler.data);
}
BMLogger.Log($"ElementDataMan: Successfully moved element file to persistent path: {destinationPath}");
return true;
await LoadGShopData();
}
public void LoadGShopData()
public async UniTask LoadGShopData()
{
Debug.Log("=== Loading GShop Data ===");
// Load primary shop
if (LoadShopData(gshopDataPath, primaryShop))
if (await LoadShopData(GSHOP_ADDRESS, primaryShop))
{
Debug.Log($"Primary shop loaded: {primaryShop.items.Count} items, {primaryShop.mainTypes.Count} categories");
//LogShopData("Primary Shop", primaryShop);
}
// Load secondary shop
if (LoadShopData(gshop1DataPath, secondaryShop))
if (await LoadShopData(GSHOP1_ADDRESS, secondaryShop))
{
Debug.Log($"Secondary shop loaded: {secondaryShop.items.Count} items, {secondaryShop.mainTypes.Count} categories");
//LogShopData("Secondary Shop", secondaryShop);
}
}
private bool LoadShopData(string filePath, GShopData shopData)
private async UniTask<bool> LoadShopData(string filePath, GShopData shopData)
{
try
{
string fullPath = Path.Combine(Application.streamingAssetsPath, filePath);
// Load from Addressables
var textAsset = await AddressableManager.Instance.LoadTextAssetAsync(filePath);
if (!File.Exists(fullPath))
if (textAsset == null)
{
Debug.LogError($"GShop file not found: {fullPath}");
BMLogger.LogError($"GShopLoader: Failed to load {filePath} from Addressables. File not found or load failed.");
return false;
}
using (FileStream fs = new FileStream(fullPath, FileMode.Open, FileAccess.Read))
using (BinaryReader reader = new BinaryReader(fs))
if (textAsset.bytes == null || textAsset.bytes.Length == 0)
{
BMLogger.LogError($"GShopLoader: {filePath} loaded from Addressables but bytes array is null or empty.");
return false;
}
// Read binary data from TextAsset.bytes using MemoryStream
using (MemoryStream ms = new MemoryStream(textAsset.bytes))
using (BinaryReader reader = new BinaryReader(ms))
{
// Read timestamp
shopData.timestamp = reader.ReadUInt32();
@@ -133,7 +99,7 @@ public class GShopLoader : MonoBehaviour
}
catch (Exception e)
{
Debug.LogError($"Error loading GShop data from {filePath}: {e.Message}");
BMLogger.LogError($"GShopLoader: Error loading GShop data from {filePath}: {e.Message}\nStackTrace: {e.StackTrace}");
return false;
}
}
@@ -714,6 +714,8 @@ public class CECAttackEvent
szFlyGFX = fullFlyGfx.Length > 4 ? fullFlyGfx.Substring(4) : string.Empty; // skip gfx/
string fullHitGfx = pProjectile.GetFileHitGfx();
szHitGFX = fullHitGfx.Length > 4 ? fullHitGfx.Substring(4) : string.Empty; // skip gfx/*/
BMLogger.Log($"{ByteToStringUtils.UshortArrayToUnicodeString(pProjectile.name)} Use hit effect: {ByteToStringUtils.ByteArrayToCP936String(pProjectile.file_hitgfx)}");
}
else if (dt == DATA_TYPE.DT_WEAPON_ESSENCE)
{
@@ -726,6 +728,8 @@ public class CECAttackEvent
// szFlyGFX = null;
// string fullHitGfx = n//pWeaponType.GetFileHitGfx();
// szHitGFX = fullHitGfx.Length > 4 ? fullHitGfx.Substring(4) : string.Empty; // skip gfx/
BMLogger.Log($"{ByteToStringUtils.UshortArrayToUnicodeString(pWeapon.name)} Use hit effect: {ByteToStringUtils.ByteArrayToCP936String(pWeaponType.file_hitgfx)}");
}
bool bHideFlyGfx = false; // TODO: !CECOptimize.Instance.GetGFX().CanShowFly(m_idHost);
@@ -754,7 +758,7 @@ public class CECAttackEvent
return false;
}
//todo: not set default like this
var fullGfx = "程序联入/击中/拳套击中";
var fullGfx = "gfx/程序联入/击中/刀剑击中.gfx";
CECGameRun.Instance.ShowVfx(fullGfx, target.position, null, 1f);
}
}
@@ -1,4 +1,3 @@
using Animancer;
using BrewMonster;
using BrewMonster.Managers;
using CSNetwork;
@@ -6,10 +5,7 @@ using CSNetwork.GPDataType;
using ModelRenderer.Scripts.Common;
using System;
using System.Threading.Tasks;
using Unity.VisualScripting;
using UnityEngine;
using static UnityEditor.PlayerSettings;
using static BrewMonster.CECHostPlayer;
public class CECNPC : CECObject
{
@@ -0,0 +1,35 @@
using UnityEngine;
// using UniTask;
namespace BrewMonster.Scripts
{
public class CECSunMoon : MonoSingleton<CECSunMoon>
{
private const float TIME_SCALE = 6f;
private const float NIGHT_DAY_START = (3.0f / 24.0f);
private const float NIGHT_SUN_RISE_MIN = (4.0f / 24.0f);
private const float NIGHT_DAY_END = (7.0f / 24.0f);
private const float DAY_NIGHT_START = (18.0f / 24.0f);
private const float DAY_SUN_SET_MAX = (19.5f / 24.0f);
private const float DAY_NIGHT_END = (21.0f / 24.0f);
public double m_vTimeOfTheDay; // time of the day 0.0f means 00:00, 1.0f means 24:00
public float m_fDNFactor; // day or night factor
public float m_fDNFactorDest; // day or night factor dest
protected override void Initialize()
{
base.Initialize();
// keep this alive when scene is loaded
DontDestroyOnLoad(gameObject);
}
public void Update()
{
m_vTimeOfTheDay += Time.deltaTime / 3600.0 / 24.0 * TIME_SCALE;
while( m_vTimeOfTheDay > 1.0 )
m_vTimeOfTheDay -= 1.0;
}
}
}
@@ -0,0 +1,2 @@
fileFormatVersion: 2
guid: 427757edde4d4aa4c8f1f0f45d926e40
-2
View File
@@ -5290,8 +5290,6 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 20694866a3163b342953396044c25a4e, type: 3}
m_Name:
m_EditorClassIdentifier:
gshopDataPath: gshop.data
gshop1DataPath: gshop1.data
--- !u!1 &7409039696840300032
GameObject:
m_ObjectHideFlags: 0
+8
View File
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 087ffbfdea4d80a42a64ebf05e490b55
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
+8
View File
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: a40390e992fe8974f8f27a8744af929b
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 5e6764d07538a5143be3f59ee9684b2b
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant: