Potion Logic
Most of the potion logic for now
This commit is contained in:
@@ -6,7 +6,7 @@ TextureImporter:
|
||||
serializedVersion: 13
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 1
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 1
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
@@ -37,24 +37,24 @@ TextureImporter:
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 0
|
||||
wrapV: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 0
|
||||
nPOTScale: 1
|
||||
nPOTScale: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteMode: 1
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
alignment: 6
|
||||
spritePivot: {x: 0, y: 0}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 0
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 0
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
@@ -93,6 +93,32 @@ TextureImporter:
|
||||
ignorePlatformSupport: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 4
|
||||
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
|
||||
- serializedVersion: 4
|
||||
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
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
@@ -100,8 +126,8 @@ TextureImporter:
|
||||
customData:
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID:
|
||||
internalID: 0
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 1537655665
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
|
||||
@@ -271,8 +271,9 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
skill: 2
|
||||
cardname: Arrows
|
||||
skill: 6
|
||||
potionType: 2
|
||||
--- !u!1 &3122354635776285422
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
||||
@@ -407,5 +407,6 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
skill: 3
|
||||
cardname: Arrows2
|
||||
skill: 7
|
||||
potionType: 2
|
||||
|
||||
@@ -271,8 +271,9 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: Test
|
||||
cardname: Dash
|
||||
skill: 0
|
||||
potionType: 2
|
||||
--- !u!1 &7178843274670826893
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
||||
@@ -407,5 +407,6 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
skill: 3
|
||||
cardname: Reflection
|
||||
skill: 1
|
||||
potionType: 2
|
||||
|
||||
@@ -407,5 +407,6 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
skill: 3
|
||||
cardname: Reflection2
|
||||
skill: 2
|
||||
potionType: 2
|
||||
|
||||
@@ -408,4 +408,5 @@ MonoBehaviour:
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
skill: 3
|
||||
skill: 5
|
||||
potionType: 1
|
||||
|
||||
@@ -407,5 +407,6 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
skill: 3
|
||||
cardname: Heal
|
||||
skill: 5
|
||||
potionType: 0
|
||||
|
||||
@@ -407,5 +407,6 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
cardname: Shockwave
|
||||
skill: 3
|
||||
potionType: 2
|
||||
|
||||
@@ -407,5 +407,6 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 0da9907611db3a04382aa4902957927c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
cardname: TETE
|
||||
skill: 3
|
||||
cardname: Spin
|
||||
skill: 4
|
||||
potionType: 2
|
||||
|
||||
@@ -1,5 +1,158 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1 &899870898099151441
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 7719046263152882697}
|
||||
- component: {fileID: 3729392411308814688}
|
||||
- component: {fileID: 535055519960375857}
|
||||
- component: {fileID: 2492104367656422644}
|
||||
m_Layer: 0
|
||||
m_Name: Text (TMP)
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &7719046263152882697
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 899870898099151441}
|
||||
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: 6205739523742799753}
|
||||
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: 100, y: 0}
|
||||
m_SizeDelta: {x: 200, y: 50}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &3729392411308814688
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 899870898099151441}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!114 &535055519960375857
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 899870898099151441}
|
||||
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: '0
|
||||
|
||||
'
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
m_fontColor32:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontColor: {r: 1, g: 1, b: 1, 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_TextWrappingMode: 1
|
||||
m_wordWrappingRatios: 0.4
|
||||
m_overflowMode: 0
|
||||
m_linkedTextComponent: {fileID: 0}
|
||||
parentLinkedComponent: {fileID: 0}
|
||||
m_enableKerning: 0
|
||||
m_ActiveFontFeatures: 6e72656b
|
||||
m_enableExtraPadding: 0
|
||||
checkPaddingRequired: 0
|
||||
m_isRichText: 1
|
||||
m_EmojiFallbackSupport: 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!114 &2492104367656422644
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 899870898099151441}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 9e65daa0fc513fe4fa2efcaf544035ff, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
textMeshProUGUI: {fileID: 535055519960375857}
|
||||
potionType: 0
|
||||
--- !u!1 &1246198998110393468
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -34,6 +187,8 @@ RectTransform:
|
||||
m_Children:
|
||||
- {fileID: 8991658504906099272}
|
||||
- {fileID: 1831891111370080197}
|
||||
- {fileID: 3235429507807963288}
|
||||
- {fileID: 6205739523742799753}
|
||||
m_Father: {fileID: 1302341320372733696}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
@@ -121,7 +276,167 @@ MonoBehaviour:
|
||||
- {fileID: 2718716012460538970, guid: f18c87f66ef0458478c34abf2c27e0c1, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: 4b296bbf922e87547a1c0639f9ae5306, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: 41bc361959173964e843a2e6bc2bf09a, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: 02e592fbd37230a429ed1be65632e53b, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: bc67a918715c89e4eaf0d797e54f37a6, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: 254d6c7b3eb32b0448e6c3e014e6d2e0, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: 03cf2a84338018f489844e9ab1e1ae25, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: be66b8bfca2b02845accf87205f3b53b, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: 2a7de02be9763204180603fa87749453, type: 3}
|
||||
- {fileID: 2718716012460538970, guid: 6c143f9f897ce394d937c8accc059fed, type: 3}
|
||||
cardsParent: {fileID: 1831891111370080197}
|
||||
--- !u!1 &1910830737072409311
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5308692316206545099}
|
||||
- component: {fileID: 5692096231889078255}
|
||||
- component: {fileID: 4795552151069639100}
|
||||
- component: {fileID: 4576974581871443905}
|
||||
m_Layer: 0
|
||||
m_Name: Text (TMP)
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &5308692316206545099
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1910830737072409311}
|
||||
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: 3235429507807963288}
|
||||
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: 100, y: 0}
|
||||
m_SizeDelta: {x: 200, y: 50}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &5692096231889078255
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1910830737072409311}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!114 &4795552151069639100
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1910830737072409311}
|
||||
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: '0
|
||||
|
||||
'
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
m_fontColor32:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontColor: {r: 1, g: 1, b: 1, 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_TextWrappingMode: 1
|
||||
m_wordWrappingRatios: 0.4
|
||||
m_overflowMode: 0
|
||||
m_linkedTextComponent: {fileID: 0}
|
||||
parentLinkedComponent: {fileID: 0}
|
||||
m_enableKerning: 0
|
||||
m_ActiveFontFeatures: 6e72656b
|
||||
m_enableExtraPadding: 0
|
||||
checkPaddingRequired: 0
|
||||
m_isRichText: 1
|
||||
m_EmojiFallbackSupport: 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!114 &4576974581871443905
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1910830737072409311}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 9e65daa0fc513fe4fa2efcaf544035ff, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
textMeshProUGUI: {fileID: 4795552151069639100}
|
||||
potionType: 1
|
||||
--- !u!1 &2520153335582361885
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -323,6 +638,158 @@ CharacterController:
|
||||
m_SkinWidth: 0.08
|
||||
m_MinMoveDistance: 0.001
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &4992829604954765258
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 3235429507807963288}
|
||||
- component: {fileID: 6461244435717521612}
|
||||
- component: {fileID: 6735253032573513453}
|
||||
m_Layer: 0
|
||||
m_Name: HealthBig
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &3235429507807963288
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 4992829604954765258}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 5, y: 10, z: 0}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 5308692316206545099}
|
||||
m_Father: {fileID: 8807664616337023072}
|
||||
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: -1619, y: -857}
|
||||
m_SizeDelta: {x: 100, y: 100}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &6461244435717521612
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 4992829604954765258}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!114 &6735253032573513453
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 4992829604954765258}
|
||||
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: 21300000, guid: 5e2137c570e6a9e468045134285db993, type: 3}
|
||||
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!1 &6110688628256452560
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 6205739523742799753}
|
||||
- component: {fileID: 1263416616809526134}
|
||||
- component: {fileID: 4019702115256759913}
|
||||
m_Layer: 0
|
||||
m_Name: HealthSmall
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &6205739523742799753
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6110688628256452560}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 3, y: 5, z: 0}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 7719046263152882697}
|
||||
m_Father: {fileID: 8807664616337023072}
|
||||
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: -1619, y: -566}
|
||||
m_SizeDelta: {x: 100, y: 100}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &1263416616809526134
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6110688628256452560}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!114 &4019702115256759913
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6110688628256452560}
|
||||
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: 21300000, guid: 5e2137c570e6a9e468045134285db993, type: 3}
|
||||
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!1 &6983871523237736218
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
||||
@@ -13,6 +13,7 @@ public class CardManager : MonoBehaviour
|
||||
|
||||
private PlayerSkillTree playerSkillTree;
|
||||
private GameObject cards;
|
||||
private PotionHandler potionHandler;
|
||||
|
||||
|
||||
private void Awake()
|
||||
@@ -25,6 +26,7 @@ public class CardManager : MonoBehaviour
|
||||
{
|
||||
Destroy(gameObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void Start()
|
||||
@@ -79,9 +81,9 @@ public class CardManager : MonoBehaviour
|
||||
}
|
||||
}
|
||||
|
||||
public void SelectCard(PlayerSkillTree.Skills skill)
|
||||
public void SelectCard(PlayerSkillTree.Skills skill, PotionHandler.PotionType potionType)
|
||||
{
|
||||
playerSkillTree.UnlockSkill(skill);
|
||||
playerSkillTree.UnlockSkill(skill, potionType);
|
||||
|
||||
foreach (Transform child in cardsParent)
|
||||
{
|
||||
|
||||
@@ -7,6 +7,8 @@ public class CardUI : MonoBehaviour
|
||||
[SerializeField] private string cardname;
|
||||
[SerializeField] private PlayerSkillTree.Skills skill;
|
||||
|
||||
[SerializeField] private PotionHandler.PotionType potionType = PotionHandler.PotionType.None;
|
||||
|
||||
public PlayerSkillTree.Skills Skill { get => skill; private set => skill = value; }
|
||||
public string Name { get => cardname; private set => cardname = value; }
|
||||
|
||||
@@ -18,6 +20,6 @@ public class CardUI : MonoBehaviour
|
||||
|
||||
private void OnCardClicked()
|
||||
{
|
||||
CardManager.Instance.SelectCard(Skill);
|
||||
CardManager.Instance.SelectCard(Skill, potionType);
|
||||
}
|
||||
}
|
||||
@@ -28,6 +28,18 @@ public class PlayerMovement : MonoBehaviour
|
||||
{
|
||||
HandleDash();
|
||||
}
|
||||
|
||||
if (Input.GetKeyDown(KeyCode.L))
|
||||
{
|
||||
if(PlayerSkills.TryUsePotion(PotionHandler.PotionType.HealthBig))
|
||||
{
|
||||
Debug.Log("Potion used!");
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Log("Potion not available!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void FixedUpdate()
|
||||
|
||||
@@ -6,6 +6,7 @@ public class PlayerSkillTree
|
||||
{
|
||||
|
||||
private static PlayerSkillTree _instance;
|
||||
private PotionHandler potionHandler;
|
||||
|
||||
public static PlayerSkillTree Instance
|
||||
{
|
||||
@@ -23,9 +24,13 @@ public class PlayerSkillTree
|
||||
public enum Skills
|
||||
{
|
||||
Dash,
|
||||
Rush,
|
||||
Kek,
|
||||
LMAO
|
||||
Reflection1,
|
||||
Reflection2,
|
||||
Shockwave,
|
||||
Spin,
|
||||
Potion,
|
||||
Arrows1,
|
||||
Arrows2
|
||||
}
|
||||
|
||||
private List<Skills> playerSkills;
|
||||
@@ -33,13 +38,29 @@ public class PlayerSkillTree
|
||||
public PlayerSkillTree()
|
||||
{
|
||||
playerSkills = new List<Skills>();
|
||||
potionHandler = new PotionHandler();
|
||||
}
|
||||
|
||||
public void UnlockSkill(Skills skill)
|
||||
public void UnlockSkill(Skills skill, PotionHandler.PotionType potionType)
|
||||
{
|
||||
|
||||
if(skill == Skills.Potion){
|
||||
potionHandler.AddPotion(potionType);
|
||||
return;
|
||||
}
|
||||
|
||||
if (playerSkills.Contains(skill)) return;
|
||||
|
||||
playerSkills.Add(skill);
|
||||
}
|
||||
|
||||
public bool TryUsePotion(PotionHandler.PotionType potionType)
|
||||
{
|
||||
if(potionHandler.IsEmpty(potionType)) return false;
|
||||
return potionHandler.UsePotion(potionType);
|
||||
}
|
||||
|
||||
|
||||
public bool IsSkillUnlocked(Skills skill)
|
||||
{
|
||||
return playerSkills.Contains(skill);
|
||||
|
||||
8
3D blobici/Assets/Scripts/PotionsSkills.meta
Normal file
8
3D blobici/Assets/Scripts/PotionsSkills.meta
Normal file
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9c6ab0dc1eb08ce43bbbb64d72bec3b1
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
61
3D blobici/Assets/Scripts/PotionsSkills/PotionHandler.cs
Normal file
61
3D blobici/Assets/Scripts/PotionsSkills/PotionHandler.cs
Normal file
@@ -0,0 +1,61 @@
|
||||
using System.Collections.Generic;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
|
||||
public class PotionHandler:MonoBehaviour
|
||||
{
|
||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||
|
||||
private Dictionary<PotionType, int> potions = new Dictionary<PotionType, int>();
|
||||
[SerializeField] private TextMeshProUGUI textMeshProUGUI;
|
||||
[SerializeField] private PotionType potionType;
|
||||
|
||||
public enum PotionType
|
||||
{
|
||||
HealthSmall,
|
||||
HealthBig,
|
||||
Mana,
|
||||
None
|
||||
}
|
||||
|
||||
public PotionHandler()
|
||||
{
|
||||
foreach (PotionType type in System.Enum.GetValues(typeof(PotionType)))
|
||||
{
|
||||
potions.Add(type, 0);
|
||||
}
|
||||
|
||||
//textMeshProUGUI.text = potions[potionType].ToString();
|
||||
|
||||
}
|
||||
|
||||
|
||||
public void AddPotion(PotionType type, int amount = 1)
|
||||
{
|
||||
potions[type] += amount;
|
||||
Debug.Log(potions[type]);
|
||||
|
||||
if(type == potionType)
|
||||
{
|
||||
textMeshProUGUI.text= potions[type].ToString();
|
||||
}
|
||||
|
||||
//Debug.Log("Text is: " + textMeshProUGUI.text);
|
||||
}
|
||||
|
||||
public bool UsePotion(PotionType type, int amount = 1)
|
||||
{
|
||||
potions[type] -= amount;
|
||||
return true;
|
||||
}
|
||||
|
||||
public int GetAmount(PotionType type)
|
||||
{
|
||||
return potions[type];
|
||||
}
|
||||
|
||||
public bool IsEmpty(PotionType type)
|
||||
{
|
||||
return GetAmount(type) == 0;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9e65daa0fc513fe4fa2efcaf544035ff
|
||||
File diff suppressed because one or more lines are too long
@@ -2,7 +2,7 @@
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!78 &1
|
||||
TagManager:
|
||||
serializedVersion: 2
|
||||
serializedVersion: 3
|
||||
tags:
|
||||
- Walls
|
||||
layers:
|
||||
@@ -42,3 +42,5 @@ TagManager:
|
||||
- name: Default
|
||||
uniqueID: 0
|
||||
locked: 0
|
||||
m_RenderingLayers:
|
||||
- Default
|
||||
|
||||
Reference in New Issue
Block a user