修改细节

This commit is contained in:
DESKTOP-DDTRVOR\asus 2024-12-25 16:04:25 +08:00
parent a00ecd193d
commit 31fe7d1838
16 changed files with 4847 additions and 2029 deletions

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

View File

@ -0,0 +1,153 @@
fileFormatVersion: 2
guid: 6bdbc2cabf58d03459ac8cd128d9ad99
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 13
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: 1
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: 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: 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: iPhone
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: WebGL
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: Android
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:

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

View File

@ -0,0 +1,153 @@
fileFormatVersion: 2
guid: eda84e15597e8bd4aba6f800948d6bb3
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 13
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: 1
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: 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: 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: iPhone
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: WebGL
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: Android
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:

File diff suppressed because it is too large Load Diff

View File

@ -905,6 +905,78 @@ PrefabInstance:
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 528826267512590966, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 528826267512590966, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 528826267512590966, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 528826267512590966, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1665911083449093460, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: -111.904785
objectReference: {fileID: 0}
- target: {fileID: 2574726802163157375, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.x
value: -27.221924
objectReference: {fileID: 0}
- target: {fileID: 2662286465274299668, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2687063965730892539, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2687063965730892539, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2918795219920107842, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.x
value: 114.15991
objectReference: {fileID: 0}
- target: {fileID: 2921766666265342482, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: -0.0011856371
objectReference: {fileID: 0}
- target: {fileID: 3005541637376198884, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3005541637376198884, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3013028099631266930, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_IsActive
value: 1
objectReference: {fileID: 0}
- target: {fileID: 3254490145894505257, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3254490145894505257, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3254490145894505257, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3266282737059014160, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_IsActive
value: 1
objectReference: {fileID: 0}
- target: {fileID: 3339919109361498372, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
@ -929,6 +1001,38 @@ PrefabInstance:
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3535150357896660372, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0.000009536743
objectReference: {fileID: 0}
- target: {fileID: 4086530264551283400, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4086530264551283400, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4086530264551283400, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMin.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4857330973713300467, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_IsActive
value: 1
objectReference: {fileID: 0}
- target: {fileID: 4892172892484661290, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4892172892484661290, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4892172892484661290, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 5101466207984114834, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
@ -937,6 +1041,22 @@ PrefabInstance:
propertyPath: m_SizeDelta.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 5223320113814838066, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 5223320113814838066, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 5260272100325979286, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_IsActive
value: 1
objectReference: {fileID: 0}
- target: {fileID: 5421308355464003349, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 5610340814941642952, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_Size
value: 1
@ -953,6 +1073,22 @@ PrefabInstance:
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 6402981133169486863, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 6402981133169486863, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 6788654942803207861, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: -81.609375
objectReference: {fileID: 0}
- target: {fileID: 7017910154464183053, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: -0.00001020357
objectReference: {fileID: 0}
- target: {fileID: 7146434732382592202, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_SizeDelta.y
value: 0
@ -965,6 +1101,10 @@ PrefabInstance:
propertyPath: m_AnchoredPosition.y
value: -0.00012395334
objectReference: {fileID: 0}
- target: {fileID: 7353981888873689265, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0.000009536743
objectReference: {fileID: 0}
- target: {fileID: 7637600488991758092, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_Size
value: 1
@ -977,6 +1117,18 @@ PrefabInstance:
propertyPath: m_SizeDelta.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8734534549119924968, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8734534549119924968, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8734534549119924968, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_AnchorMin.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8740125470161128311, guid: 0e52b314be6e069439c3bb54fb42807e, type: 3}
propertyPath: m_Name
value: Canvas

View File

@ -308,11 +308,15 @@ public class GameSystem : MonoBehaviour
{
drawingManager.CraftItem(bo, () =>
{
forgePanel.ResetItemData();
forgePanel.ResetSlotItem();
ResetItemPanel();
});
}
public void ResetItemPanel()
{
forgePanel.ResetItemData();
forgePanel.ResetSlotItem();
}
public void SaveSeledID(int sendID)
{
id = sendID;

View File

@ -15,6 +15,7 @@ public class GuidePanel : MonoBehaviour
[SerializeField] private RogenItem _rogenItem;
[SerializeField] private Image _sceleImage;
[SerializeField] private Text _text;
[SerializeField] private RectTransform text2Tra;
[SerializeField] private Text _text2;
[SerializeField] private GameObject crafting;
[SerializeField] private GameObject cra2;
@ -41,7 +42,7 @@ public class GuidePanel : MonoBehaviour
{
_sceleImage.gameObject.SetActive(false);
_text.text = "点击开店";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[0].position;
_text2.gameObject.SetActive(false);
seleTra.position = lock1.position;
eventButton.onClick.AddListener(Event1);
@ -54,7 +55,7 @@ public class GuidePanel : MonoBehaviour
eventButton.onClick.AddListener(SaveE1);
_sceleImage.gameObject.SetActive(true);
_text.text = "拖拽到锻造栏";
_text.GetComponent<RectTransform>().position = textList[3].position;
text2Tra.position = textList[3].position;
_forgePanel.GuideV1();
var data = JsonTab.Instance.tables.Item.Get(1011);
_sceleImage.sprite = AssetBundleManager.ins.Sprite(data.Icon, AtlasType.ItemIcon);
@ -89,7 +90,7 @@ public class GuidePanel : MonoBehaviour
ani.Kill();
ani= hand.GetComponent<RectTransform>().DOLocalMove(Vector3.zero, 0.1f);
_text.text = "点击锻造";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[2].position;
seleTra.position = lock3.position;
eventButton.onClick.AddListener(Event2);
}
@ -117,7 +118,7 @@ public class GuidePanel : MonoBehaviour
_text2.gameObject.SetActive(false);
GetComponent<Image>().enabled = true;
_text.text = "点击任意区域关闭页面";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[0].position;
}
private void Event4()
@ -127,7 +128,7 @@ public class GuidePanel : MonoBehaviour
eventButton.onClick.RemoveListener(Event4);
eventButton.onClick.AddListener(Event4c1);
_text.text = "拖拽铁剑给客户";
_text.GetComponent<RectTransform>().position = textList[1].position;
text2Tra.position = textList[1].position;
_sceleImage.gameObject.SetActive(true);
var data = JsonTab.Instance.tables.Item.Get(2011);
_sceleImage.sprite = AssetBundleManager.ins.Sprite(data.Icon, AtlasType.ItemIcon);
@ -149,7 +150,7 @@ public class GuidePanel : MonoBehaviour
eventButton.onClick.AddListener(Event5);
GameSystem.ins.GuideV2();
_text.text = "点击关闭";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[0].position;
}
private void Event5()
{
@ -158,7 +159,7 @@ public class GuidePanel : MonoBehaviour
eventButton.onClick.RemoveListener(Event5);
eventButton.onClick.AddListener(Event6);
_text.text = "点击关店";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[1].position;
}
private void Event6()
@ -180,7 +181,7 @@ public class GuidePanel : MonoBehaviour
_text2.gameObject.SetActive(false);
seleTra.position = lock6.position;
_text.text = "点击开始进入关卡";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[0].position;
eventButton.onClick.AddListener(Event8);
}
private void Event8()
@ -188,7 +189,7 @@ public class GuidePanel : MonoBehaviour
eventButton.onClick.RemoveListener(Event8);
seleTra.position = lock7.position;
_text.text = "点击放置武器";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[0].position;
DataManager.AddItem(2011,3);
_battlePanel.OpenCombatPanel();
eventButton.onClick.AddListener(Event9);
@ -225,6 +226,7 @@ public class GuidePanel : MonoBehaviour
UIMgr.ins.ResetBattleReadyPanel();
}
seleTra.position = lock8.position;
_text.text = "点击开始游戏";
eventButton.onClick.AddListener(Event12);
}
private void Event12()
@ -240,7 +242,7 @@ public class GuidePanel : MonoBehaviour
_text2.gameObject.SetActive(false);
seleTra.position = _rogenItem.transform.position;
_text.text = "点击随机技能";
_text.GetComponent<RectTransform>().position = textList[0].position;
text2Tra.position = textList[0].position;
eventButton.onClick.AddListener(Event14);
}
public void Event14()

View File

@ -1,3 +1,4 @@
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
@ -8,18 +9,41 @@ public class SlotUI : MonoBehaviour
[SerializeField] private int index;
[SerializeField] private Image icon;
[SerializeField] private Button _button;
private void Awake()
{
_button = GetComponent<Button>();
}
// Start is called before the first frame update
void Start()
{
}
private void OnEnable()
{
_button.onClick.AddListener(ButtonEvent);
}
// Update is called once per frame
void Update()
{
}
private void OnDisable()
{
_button.onClick.RemoveListener(ButtonEvent);
}
public void ButtonEvent()
{
GameSystem.ins.drawingManager.itemsSlot[index] = 0;
GameSystem.ins.ResetItemPanel();
}
public void SaveIndex()
{
GameSystem.ins.SaveIndex(index);

View File

@ -18,6 +18,9 @@ public class StorePanel : MonoBehaviour
[SerializeField] private GameObject stroeback;
[SerializeField] private Button lottery;
[SerializeField] private GameObject lotteryback;
[SerializeField] private Text _goldNum;
[SerializeField] private Text _diamondNum;
[SerializeField] private Text _physicalNum;
private void Awake()
{
@ -62,6 +65,7 @@ public class StorePanel : MonoBehaviour
lotteryParent.SetActive(false);
stroeback.gameObject.SetActive(true);
lotteryback.gameObject.SetActive(false);
ResetGold();
}
public void ResetLottery()
@ -75,6 +79,7 @@ public class StorePanel : MonoBehaviour
lotteryParent.SetActive(true);
stroeback.gameObject.SetActive(false);
lotteryback.gameObject.SetActive(true);
ResetGold();
}
public void SetRandomData(int id)
@ -98,5 +103,17 @@ public class StorePanel : MonoBehaviour
{
_panel.gameObject.SetActive(true);
_panel.SaveData(itemDatas);
foreach (var s in dayStoreItems)
{
s.ResetItem();
}
ResetGold();
}
public void ResetGold()
{
_goldNum.text = DataManager.GetItem(2).ToString();
_diamondNum.text = DataManager.GetItem(3).ToString();
_physicalNum.text=DataManager.GetPhysical().ToString();
}
}

View File

@ -8,6 +8,7 @@ public class StoreItem : MonoBehaviour
{
[SerializeField] private int id;
[SerializeField] private Image icon;
[SerializeField] private Image buyIcon;
[SerializeField] private Sprite storeIcon;
[SerializeField] private Text name;
[SerializeField] private Text num;
@ -46,10 +47,12 @@ public class StoreItem : MonoBehaviour
if (DataManager.NextDay("storeDay"+id))
{
num.text = "免费获得";
_button.interactable = true;
}
else
{
num.text = "已售罄";
_button.interactable = false;
}
}
else if (id == 102 || id == 104)