Browse Source

Add complete item info display with class, description, stats

master
Devin 4 years ago
parent
commit
ef19cedaed
  1. 77
      Assets/Prefabs/GridViewItem.prefab
  2. 216
      Assets/Prefabs/ListViewItemSingle.prefab
  3. 470
      Assets/Scenes/NewShop.unity
  4. 25
      Assets/Scripts/Shop/Components/ItemClassDisplay.cs
  5. 11
      Assets/Scripts/Shop/Components/ItemClassDisplay.cs.meta
  6. 24
      Assets/Scripts/Shop/Components/ItemDescriptionDisplay.cs
  7. 11
      Assets/Scripts/Shop/Components/ItemDescriptionDisplay.cs.meta
  8. 24
      Assets/Scripts/Shop/Components/ItemPriceDisplay.cs
  9. 11
      Assets/Scripts/Shop/Components/ItemPriceDisplay.cs.meta
  10. 24
      Assets/Scripts/Shop/Components/ItemStatsDisplay.cs
  11. 11
      Assets/Scripts/Shop/Components/ItemStatsDisplay.cs.meta
  12. 24
      Assets/Scripts/Shop/Components/ItemTypeDisplay.cs
  13. 11
      Assets/Scripts/Shop/Components/ItemTypeDisplay.cs.meta
  14. 21
      Assets/Scripts/Shop/Model/Item.cs
  15. 2
      Assets/Scripts/Shop/Model/ItemWeapon.cs
  16. 2
      Assets/Scripts/Shop/Scriptable Objects/ScriptedWeapon.cs
  17. 37
      Assets/Scripts/Shop/View/ViewItemInfoPanel.cs

77
Assets/Prefabs/GridViewItem.prefab

@ -282,7 +282,7 @@ MonoBehaviour:
m_isUsingLegacyAnimationComponent: 0 m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0 m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0} m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 1 m_hasFontAssetChanged: 0
m_subTextObjects: m_subTextObjects:
- {fileID: 0} - {fileID: 0}
- {fileID: 0} - {fileID: 0}
@ -317,6 +317,7 @@ GameObject:
- component: {fileID: 3459871029912935000} - component: {fileID: 3459871029912935000}
- component: {fileID: 6746999582958781488} - component: {fileID: 6746999582958781488}
- component: {fileID: 2360704200307441066} - component: {fileID: 2360704200307441066}
- component: {fileID: 9016483325449273412}
m_Layer: 5 m_Layer: 5
m_Name: Description m_Name: Description
m_TagString: Untagged m_TagString: Untagged
@ -450,7 +451,7 @@ MonoBehaviour:
m_isUsingLegacyAnimationComponent: 0 m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0 m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0} m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 1 m_hasFontAssetChanged: 0
m_subTextObjects: m_subTextObjects:
- {fileID: 0} - {fileID: 0}
- {fileID: 0} - {fileID: 0}
@ -462,6 +463,18 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &9016483325449273412
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1522873078225282773}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: ba8fdcedafab8e249b5476506605049d, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &1985633671483540191 --- !u!1 &1985633671483540191
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -801,6 +814,7 @@ GameObject:
- component: {fileID: 9090275076447713121} - component: {fileID: 9090275076447713121}
- component: {fileID: 3676162603302212405} - component: {fileID: 3676162603302212405}
- component: {fileID: 6714676216107572490} - component: {fileID: 6714676216107572490}
- component: {fileID: 9129586492570065324}
m_Layer: 5 m_Layer: 5
m_Name: Price m_Name: Price
m_TagString: Untagged m_TagString: Untagged
@ -934,7 +948,7 @@ MonoBehaviour:
m_isUsingLegacyAnimationComponent: 0 m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0 m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0} m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 1 m_hasFontAssetChanged: 0
m_subTextObjects: m_subTextObjects:
- {fileID: 0} - {fileID: 0}
- {fileID: 0} - {fileID: 0}
@ -946,6 +960,18 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &9129586492570065324
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2428313010144644473}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 659f6736a974d674d9c581e9868deec1, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &3047109206375685073 --- !u!1 &3047109206375685073
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -1061,6 +1087,7 @@ GameObject:
- component: {fileID: 6246543070715428860} - component: {fileID: 6246543070715428860}
- component: {fileID: 2677774126614840048} - component: {fileID: 2677774126614840048}
- component: {fileID: 2492011378434963668} - component: {fileID: 2492011378434963668}
- component: {fileID: 4378136650993717263}
m_Layer: 5 m_Layer: 5
m_Name: Rarity m_Name: Rarity
m_TagString: Untagged m_TagString: Untagged
@ -1194,7 +1221,7 @@ MonoBehaviour:
m_isUsingLegacyAnimationComponent: 0 m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0 m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0} m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 1 m_hasFontAssetChanged: 0
m_subTextObjects: m_subTextObjects:
- {fileID: 0} - {fileID: 0}
- {fileID: 0} - {fileID: 0}
@ -1206,6 +1233,18 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &4378136650993717263
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4137419382413454986}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 41a101ea814db6a49a3bab946736dba5, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &4356379507601593410 --- !u!1 &4356379507601593410
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -1217,6 +1256,7 @@ GameObject:
- component: {fileID: 7180420147949674902} - component: {fileID: 7180420147949674902}
- component: {fileID: 6572675765595622057} - component: {fileID: 6572675765595622057}
- component: {fileID: 4983456753740745199} - component: {fileID: 4983456753740745199}
- component: {fileID: 6704532864936545534}
m_Layer: 5 m_Layer: 5
m_Name: Category m_Name: Category
m_TagString: Untagged m_TagString: Untagged
@ -1350,7 +1390,7 @@ MonoBehaviour:
m_isUsingLegacyAnimationComponent: 0 m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0 m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0} m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 1 m_hasFontAssetChanged: 0
m_subTextObjects: m_subTextObjects:
- {fileID: 0} - {fileID: 0}
- {fileID: 0} - {fileID: 0}
@ -1362,6 +1402,18 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &6704532864936545534
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4356379507601593410}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c538448bdfe2f11438498c4856029913, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &4763744946543245952 --- !u!1 &4763744946543245952
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -1671,6 +1723,7 @@ GameObject:
- component: {fileID: 4280569444292194324} - component: {fileID: 4280569444292194324}
- component: {fileID: 1794332670372956633} - component: {fileID: 1794332670372956633}
- component: {fileID: 1719929256159360204} - component: {fileID: 1719929256159360204}
- component: {fileID: 8846883938861528772}
m_Layer: 5 m_Layer: 5
m_Name: Attributes m_Name: Attributes
m_TagString: Untagged m_TagString: Untagged
@ -1804,7 +1857,7 @@ MonoBehaviour:
m_isUsingLegacyAnimationComponent: 0 m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0 m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0} m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 1 m_hasFontAssetChanged: 0
m_subTextObjects: m_subTextObjects:
- {fileID: 0} - {fileID: 0}
- {fileID: 0} - {fileID: 0}
@ -1816,3 +1869,15 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &8846883938861528772
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8777873161867183048}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: ee409d11cde740d418f31eb42f60e4f7, type: 3}
m_Name:
m_EditorClassIdentifier:

216
Assets/Prefabs/ListViewItemSingle.prefab

@ -156,6 +156,175 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!1 &531148804892751498
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6107274172656383818}
- component: {fileID: 7534987933543151908}
- component: {fileID: 2486900104262856394}
- component: {fileID: 7395536492347756257}
m_Layer: 5
m_Name: Class
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &6107274172656383818
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 531148804892751498}
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_Children: []
m_Father: {fileID: 8487823816882720629}
m_RootOrder: 4
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 150, y: 40.22}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &7534987933543151908
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 531148804892751498}
m_CullTransparentMesh: 0
--- !u!114 &2486900104262856394
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 531148804892751498}
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_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Weppen
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_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_outlineColor:
serializedVersion: 2
rgba: 4278190080
m_fontSize: 20
m_fontSizeBase: 20
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 1
m_textAlignment: 513
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_firstOverflowCharacterIndex: -1
m_linkedTextComponent: {fileID: 0}
m_isLinkedTextComponent: 0
m_isTextTruncated: 0
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_ignoreRectMaskCulling: 0
m_ignoreCulling: 1
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_VertexBufferAutoSizeReduction: 1
m_firstVisibleCharacter: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_textInfo:
textComponent: {fileID: 2486900104262856394}
characterCount: 6
spriteCount: 0
spaceCount: 0
wordCount: 1
linkCount: 0
lineCount: 1
pageCount: 1
materialCount: 1
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 0
m_subTextObjects:
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &7395536492347756257
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 531148804892751498}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 41a101ea814db6a49a3bab946736dba5, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &1051434554266799280 --- !u!1 &1051434554266799280
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -502,6 +671,7 @@ RectTransform:
- {fileID: 6553243021295918078} - {fileID: 6553243021295918078}
- {fileID: 6553243022573261483} - {fileID: 6553243022573261483}
- {fileID: 420949937691898570} - {fileID: 420949937691898570}
- {fileID: 6107274172656383818}
m_Father: {fileID: 6553243021197451809} m_Father: {fileID: 6553243021197451809}
m_RootOrder: 1 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
@ -836,15 +1006,15 @@ RectTransform:
m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: m_Children:
- {fileID: 3012085300077830278}
- {fileID: 3968500489605247670} - {fileID: 3968500489605247670}
- {fileID: 3012085300077830278}
m_Father: {fileID: 8487823816882720629} m_Father: {fileID: 8487823816882720629}
m_RootOrder: 3 m_RootOrder: 3
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 100, y: 30.4} m_SizeDelta: {x: 150, y: 30.4}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &8756767049164552714 --- !u!222 &8756767049164552714
CanvasRenderer: CanvasRenderer:
@ -997,8 +1167,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 42.7, y: 0}
m_SizeDelta: {x: 750, y: 49.26866} m_SizeDelta: {x: 835.3318, y: 49.26866}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &6553243021197451812 --- !u!222 &6553243021197451812
CanvasRenderer: CanvasRenderer:
@ -1270,6 +1440,7 @@ GameObject:
- component: {fileID: 6553243022573261483} - component: {fileID: 6553243022573261483}
- component: {fileID: 6553243022573261485} - component: {fileID: 6553243022573261485}
- component: {fileID: 6553243022573261484} - component: {fileID: 6553243022573261484}
- component: {fileID: 227190811353608066}
m_Layer: 5 m_Layer: 5
m_Name: Type m_Name: Type
m_TagString: Untagged m_TagString: Untagged
@ -1323,7 +1494,7 @@ MonoBehaviour:
m_OnCullStateChanged: m_OnCullStateChanged:
m_PersistentCalls: m_PersistentCalls:
m_Calls: [] m_Calls: []
m_text: Weapon m_text: Weppen
m_isRightToLeft: 0 m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
@ -1415,6 +1586,18 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &227190811353608066
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6553243022573261482}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c538448bdfe2f11438498c4856029913, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &6611248640760052035 --- !u!1 &6611248640760052035
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -1445,11 +1628,11 @@ RectTransform:
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: [] m_Children: []
m_Father: {fileID: 420949937691898570} m_Father: {fileID: 420949937691898570}
m_RootOrder: 0 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: -10, y: 0} m_AnchoredPosition: {x: 40, y: -0.2}
m_SizeDelta: {x: 40, y: 30} m_SizeDelta: {x: 40, y: 30}
m_Pivot: {x: 1, y: 0.5} m_Pivot: {x: 1, y: 0.5}
--- !u!222 &988215966894402235 --- !u!222 &988215966894402235
@ -1657,6 +1840,7 @@ GameObject:
- component: {fileID: 3968500489605247670} - component: {fileID: 3968500489605247670}
- component: {fileID: 3096015503570208038} - component: {fileID: 3096015503570208038}
- component: {fileID: 6180242757122334151} - component: {fileID: 6180242757122334151}
- component: {fileID: 521378806774809644}
m_Layer: 5 m_Layer: 5
m_Name: Price m_Name: Price
m_TagString: Untagged m_TagString: Untagged
@ -1676,11 +1860,11 @@ RectTransform:
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: [] m_Children: []
m_Father: {fileID: 420949937691898570} m_Father: {fileID: 420949937691898570}
m_RootOrder: 1 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 1, y: 0} m_AnchoredPosition: {x: -60, y: 0.2}
m_SizeDelta: {x: 60, y: 30} m_SizeDelta: {x: 60, y: 30}
m_Pivot: {x: 0, y: 0.5} m_Pivot: {x: 0, y: 0.5}
--- !u!222 &3096015503570208038 --- !u!222 &3096015503570208038
@ -1745,7 +1929,7 @@ MonoBehaviour:
m_fontSizeMin: 18 m_fontSizeMin: 18
m_fontSizeMax: 72 m_fontSizeMax: 72
m_fontStyle: 1 m_fontStyle: 1
m_textAlignment: 513 m_textAlignment: 516
m_characterSpacing: 0 m_characterSpacing: 0
m_wordSpacing: 0 m_wordSpacing: 0
m_lineSpacing: 0 m_lineSpacing: 0
@ -1802,6 +1986,18 @@ MonoBehaviour:
- {fileID: 0} - {fileID: 0}
m_baseMaterial: {fileID: 0} m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &521378806774809644
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8336597677835632212}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 659f6736a974d674d9c581e9868deec1, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &9143945233084444160 --- !u!1 &9143945233084444160
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0

470
Assets/Scenes/NewShop.unity

@ -141,7 +141,7 @@ GameObject:
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
m_IsActive: 1 m_IsActive: 0
--- !u!224 &78292603 --- !u!224 &78292603
RectTransform: RectTransform:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -767,13 +767,14 @@ RectTransform:
- {fileID: 904235319} - {fileID: 904235319}
- {fileID: 1966788904} - {fileID: 1966788904}
- {fileID: 1701112577} - {fileID: 1701112577}
- {fileID: 777484099}
m_Father: {fileID: 274071969} m_Father: {fileID: 274071969}
m_RootOrder: 0 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 375, y: -24.63433} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 750, y: 49.26866} m_SizeDelta: {x: 933.3689, y: 49.26866}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &240970668 --- !u!114 &240970668
MonoBehaviour: MonoBehaviour:
@ -869,9 +870,9 @@ RectTransform:
m_Father: {fileID: 849412833} m_Father: {fileID: 849412833}
m_RootOrder: 0 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 58.397293, y: -20}
m_SizeDelta: {x: 116.794586, y: 38.03768} m_SizeDelta: {x: 116.794586, y: 38.03768}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &242976726 --- !u!114 &242976726
@ -1106,6 +1107,7 @@ GameObject:
- component: {fileID: 317898840} - component: {fileID: 317898840}
- component: {fileID: 317898842} - component: {fileID: 317898842}
- component: {fileID: 317898841} - component: {fileID: 317898841}
- component: {fileID: 317898843}
m_Layer: 5 m_Layer: 5
m_Name: Description m_Name: Description
m_TagString: Untagged m_TagString: Untagged
@ -1251,6 +1253,18 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 317898839} m_GameObject: {fileID: 317898839}
m_CullTransparentMesh: 0 m_CullTransparentMesh: 0
--- !u!114 &317898843
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 317898839}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: ba8fdcedafab8e249b5476506605049d, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &368472841 --- !u!1 &368472841
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -2225,9 +2239,9 @@ RectTransform:
m_Father: {fileID: 849412833} m_Father: {fileID: 849412833}
m_RootOrder: 1 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 136.79459, y: -20}
m_SizeDelta: {x: 20, y: 20} m_SizeDelta: {x: 20, y: 20}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &552208507 --- !u!114 &552208507
@ -2375,9 +2389,9 @@ RectTransform:
m_Father: {fileID: 779240604} m_Father: {fileID: 779240604}
m_RootOrder: 1 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 136.79459, y: -20} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 20, y: 20} m_SizeDelta: {x: 20, y: 20}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &591197038 --- !u!114 &591197038
@ -2569,9 +2583,9 @@ RectTransform:
m_Father: {fileID: 779240604} m_Father: {fileID: 779240604}
m_RootOrder: 2 m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 208.98698, y: -20} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 104.384796, y: 40} m_SizeDelta: {x: 104.384796, y: 40}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &741829286 --- !u!114 &741829286
@ -2695,6 +2709,162 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 741829284} m_GameObject: {fileID: 741829284}
m_CullTransparentMesh: 0 m_CullTransparentMesh: 0
--- !u!1 &777484098
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 777484099}
- component: {fileID: 777484101}
- component: {fileID: 777484100}
m_Layer: 5
m_Name: Class
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &777484099
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 777484098}
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_Children: []
m_Father: {fileID: 240970667}
m_RootOrder: 4
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 150, y: 40.22}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &777484100
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 777484098}
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_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Class
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_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_outlineColor:
serializedVersion: 2
rgba: 4278190080
m_fontSize: 30
m_fontSizeBase: 30
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_textAlignment: 257
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_firstOverflowCharacterIndex: -1
m_linkedTextComponent: {fileID: 0}
m_isLinkedTextComponent: 0
m_isTextTruncated: 0
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_ignoreRectMaskCulling: 0
m_ignoreCulling: 1
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_VertexBufferAutoSizeReduction: 1
m_firstVisibleCharacter: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_textInfo:
textComponent: {fileID: 777484100}
characterCount: 5
spriteCount: 0
spaceCount: 0
wordCount: 1
linkCount: 0
lineCount: 1
pageCount: 1
materialCount: 1
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 0
m_subTextObjects:
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!222 &777484101
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 777484098}
m_CullTransparentMesh: 0
--- !u!1 &779240603 --- !u!1 &779240603
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -2829,6 +2999,7 @@ RectTransform:
m_Children: m_Children:
- {fileID: 2071906704} - {fileID: 2071906704}
- {fileID: 1287258905} - {fileID: 1287258905}
- {fileID: 1112132933}
m_Father: {fileID: 1808186923} m_Father: {fileID: 1808186923}
m_RootOrder: 0 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
@ -2892,7 +3063,7 @@ GameObject:
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
m_IsActive: 0 m_IsActive: 1
--- !u!224 &822572996 --- !u!224 &822572996
RectTransform: RectTransform:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -3294,9 +3465,9 @@ RectTransform:
m_Father: {fileID: 240970667} m_Father: {fileID: 240970667}
m_RootOrder: 1 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 199.62448, y: -24.63433} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 150, y: 40.22} m_SizeDelta: {x: 150, y: 40.22}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &904235320 --- !u!114 &904235320
@ -3760,9 +3931,9 @@ RectTransform:
m_Father: {fileID: 779240604} m_Father: {fileID: 779240604}
m_RootOrder: 0 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 58.397293, y: -20} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 116.794586, y: 38.03768} m_SizeDelta: {x: 116.794586, y: 38.03768}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1071789911 --- !u!114 &1071789911
@ -4276,6 +4447,188 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1106438846} m_GameObject: {fileID: 1106438846}
m_CullTransparentMesh: 0 m_CullTransparentMesh: 0
--- !u!1 &1112132932
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1112132933}
- component: {fileID: 1112132937}
- component: {fileID: 1112132936}
- component: {fileID: 1112132935}
- component: {fileID: 1112132934}
m_Layer: 5
m_Name: Type
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1112132933
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1112132932}
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_Children: []
m_Father: {fileID: 797243233}
m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 100, y: -42.2}
m_SizeDelta: {x: 200, y: 37.808884}
m_Pivot: {x: 0, y: 1}
--- !u!114 &1112132934
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1112132932}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c538448bdfe2f11438498c4856029913, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &1112132935
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1112132932}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f1bf98089f9db1b4aacb219d05609744, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &1112132936
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1112132932}
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_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Student Sword
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_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_outlineColor:
serializedVersion: 2
rgba: 4278190080
m_fontSize: 13
m_fontSizeBase: 13
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 1
m_textAlignment: 514
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_firstOverflowCharacterIndex: -1
m_linkedTextComponent: {fileID: 0}
m_isLinkedTextComponent: 0
m_isTextTruncated: 0
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_ignoreRectMaskCulling: 0
m_ignoreCulling: 1
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_VertexBufferAutoSizeReduction: 1
m_firstVisibleCharacter: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_textInfo:
textComponent: {fileID: 1112132936}
characterCount: 13
spriteCount: 0
spaceCount: 1
wordCount: 2
linkCount: 0
lineCount: 1
pageCount: 1
materialCount: 1
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_spriteAnimator: {fileID: 0}
m_hasFontAssetChanged: 0
m_subTextObjects:
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
- {fileID: 0}
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!222 &1112132937
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1112132932}
m_CullTransparentMesh: 0
--- !u!1 &1161978529 --- !u!1 &1161978529
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -5506,9 +5859,9 @@ RectTransform:
m_Father: {fileID: 240970667} m_Father: {fileID: 240970667}
m_RootOrder: 0 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 42.31224, y: -24.63433} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 64.62448, y: 40.22} m_SizeDelta: {x: 64.62448, y: 40.22}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1374344515 --- !u!114 &1374344515
@ -6541,9 +6894,9 @@ RectTransform:
m_Father: {fileID: 240970667} m_Father: {fileID: 240970667}
m_RootOrder: 3 m_RootOrder: 3
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 599.6245, y: -24.63433} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 150, y: 40.22} m_SizeDelta: {x: 150, y: 40.22}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1701112578 --- !u!114 &1701112578
@ -7135,9 +7488,9 @@ RectTransform:
m_Father: {fileID: 1424701243} m_Father: {fileID: 1424701243}
m_RootOrder: 2 m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 400, y: 0}
m_SizeDelta: {x: 160, y: 50} m_SizeDelta: {x: 160, y: 50}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &1763223519 --- !u!114 &1763223519
@ -7411,9 +7764,9 @@ RectTransform:
m_Father: {fileID: 1424701243} m_Father: {fileID: 1424701243}
m_RootOrder: 0 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 80, y: 0}
m_SizeDelta: {x: 160, y: 50} m_SizeDelta: {x: 160, y: 50}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &1779774928 --- !u!114 &1779774928
@ -7609,6 +7962,7 @@ GameObject:
- component: {fileID: 1825988454} - component: {fileID: 1825988454}
- component: {fileID: 1825988456} - component: {fileID: 1825988456}
- component: {fileID: 1825988455} - component: {fileID: 1825988455}
- component: {fileID: 1825988457}
m_Layer: 5 m_Layer: 5
m_Name: Attributes m_Name: Attributes
m_TagString: Untagged m_TagString: Untagged
@ -7754,6 +8108,18 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1825988453} m_GameObject: {fileID: 1825988453}
m_CullTransparentMesh: 0 m_CullTransparentMesh: 0
--- !u!114 &1825988457
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1825988453}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: ee409d11cde740d418f31eb42f60e4f7, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &1865708445 --- !u!1 &1865708445
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -7787,9 +8153,9 @@ RectTransform:
m_Father: {fileID: 274071969} m_Father: {fileID: 274071969}
m_RootOrder: 1 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 475, y: -49.26866} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 950, y: 602} m_SizeDelta: {x: 950, y: 602}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &1865708447 --- !u!114 &1865708447
@ -8093,9 +8459,9 @@ RectTransform:
m_Father: {fileID: 1424701243} m_Father: {fileID: 1424701243}
m_RootOrder: 3 m_RootOrder: 3
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 560, y: 0}
m_SizeDelta: {x: 160, y: 50} m_SizeDelta: {x: 160, y: 50}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &1918696018 --- !u!114 &1918696018
@ -8518,9 +8884,9 @@ RectTransform:
m_Father: {fileID: 849412833} m_Father: {fileID: 849412833}
m_RootOrder: 2 m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 208.98698, y: -20}
m_SizeDelta: {x: 104.384796, y: 40} m_SizeDelta: {x: 104.384796, y: 40}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1947464188 --- !u!114 &1947464188
@ -8676,9 +9042,9 @@ RectTransform:
m_Father: {fileID: 240970667} m_Father: {fileID: 240970667}
m_RootOrder: 2 m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 399.62448, y: -24.63433} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 150, y: 40.22} m_SizeDelta: {x: 150, y: 40.22}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1966788905 --- !u!114 &1966788905
@ -8998,9 +9364,9 @@ RectTransform:
m_Father: {fileID: 1424701243} m_Father: {fileID: 1424701243}
m_RootOrder: 1 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 240, y: 0}
m_SizeDelta: {x: 160, y: 50} m_SizeDelta: {x: 160, y: 50}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &1982954963 --- !u!114 &1982954963
@ -9352,7 +9718,7 @@ GameObject:
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
m_IsActive: 1 m_IsActive: 0
--- !u!224 &2131558511 --- !u!224 &2131558511
RectTransform: RectTransform:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0

25
Assets/Scripts/Shop/Components/ItemClassDisplay.cs

@ -0,0 +1,25 @@
using System;
using System.Collections;
using System.Collections.Generic;
using TMPro;
using UnityEngine;
/// <summary>
/// This class' only purpose is to set the class of an item view prototype. Could be the item itself, or the infobox, or anything!
/// </summary>
[RequireComponent(typeof(TextMeshProUGUI))]
public class ItemClassDisplay : MonoBehaviour
{
private TextMeshProUGUI text;
private void Start()
{
text = GetComponent<TextMeshProUGUI>(); // Because of the meta tag, Unity will make sure this exists. No sanity checks
}
public void SetClass(ItemRarity clas)
{
if(text == null) text = GetComponent<TextMeshProUGUI>(); // Just in case this gets called before Start()
text.text = clas.ToString();
text.color = new Color32((byte)((uint)clas >> 24), (byte)((uint)clas >> 16), (byte)((uint)clas >> 8), (byte)((uint)clas));
}
}

11
Assets/Scripts/Shop/Components/ItemClassDisplay.cs.meta

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 41a101ea814db6a49a3bab946736dba5
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

24
Assets/Scripts/Shop/Components/ItemDescriptionDisplay.cs

@ -0,0 +1,24 @@
using System;
using System.Collections;
using System.Collections.Generic;
using TMPro;
using UnityEngine;
/// <summary>
/// This class' only purpose is to set the description of a UI element
/// </summary>
[RequireComponent(typeof(TextMeshProUGUI))]
public class ItemDescriptionDisplay : MonoBehaviour
{
private TextMeshProUGUI text;
private void Start()
{
text = GetComponent<TextMeshProUGUI>(); // Because of the meta tag, Unity will make sure this exists. No sanity checks
}
public void SetDescription(string desc)
{
if(text == null) text = GetComponent<TextMeshProUGUI>(); // Just in case this gets called before Start()
text.text = desc.ToString();
}
}

11
Assets/Scripts/Shop/Components/ItemDescriptionDisplay.cs.meta

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: ba8fdcedafab8e249b5476506605049d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

24
Assets/Scripts/Shop/Components/ItemPriceDisplay.cs

@ -0,0 +1,24 @@
using System;
using System.Collections;
using System.Collections.Generic;
using TMPro;
using UnityEngine;
/// <summary>
/// This class' only purpose is to set the price of a UI element
/// </summary>
[RequireComponent(typeof(TextMeshProUGUI))]
public class ItemPriceDisplay : MonoBehaviour
{
private TextMeshProUGUI text;
private void Start()
{
text = GetComponent<TextMeshProUGUI>(); // Because of the meta tag, Unity will make sure this exists. No sanity checks
}
public void SetPrice(int price)
{
if(text == null) text = GetComponent<TextMeshProUGUI>(); // Just in case this gets called before Start()
text.text = price.ToString();
}
}

11
Assets/Scripts/Shop/Components/ItemPriceDisplay.cs.meta

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 659f6736a974d674d9c581e9868deec1
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

24
Assets/Scripts/Shop/Components/ItemStatsDisplay.cs

@ -0,0 +1,24 @@
using System;
using System.Collections;
using System.Collections.Generic;
using TMPro;
using UnityEngine;
/// <summary>
/// This class' only purpose is to set the stats string of a UI element
/// </summary>
[RequireComponent(typeof(TextMeshProUGUI))]
public class ItemStatsDisplay : MonoBehaviour
{
private TextMeshProUGUI text;
private void Start()
{
text = GetComponent<TextMeshProUGUI>(); // Because of the meta tag, Unity will make sure this exists. No sanity checks
}
public void SetStats(string stats)
{
if(text == null) text = GetComponent<TextMeshProUGUI>(); // Just in case this gets called before Start()
text.text = stats;
}
}

11
Assets/Scripts/Shop/Components/ItemStatsDisplay.cs.meta

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: ee409d11cde740d418f31eb42f60e4f7
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

24
Assets/Scripts/Shop/Components/ItemTypeDisplay.cs

@ -0,0 +1,24 @@
using System;
using System.Collections;
using System.Collections.Generic;
using TMPro;
using UnityEngine;
/// <summary>
/// This class' only purpose is to set the type string of a UI element
/// </summary>
[RequireComponent(typeof(TextMeshProUGUI))]
public class ItemTypeDisplay : MonoBehaviour
{
private TextMeshProUGUI text;
private void Start()
{
text = GetComponent<TextMeshProUGUI>(); // Because of the meta tag, Unity will make sure this exists. No sanity checks
}
public void SetType(string txt)
{
if(text == null) text = GetComponent<TextMeshProUGUI>(); // Just in case this gets called before Start()
text.text = txt;
}
}

11
Assets/Scripts/Shop/Components/ItemTypeDisplay.cs.meta

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: c538448bdfe2f11438498c4856029913
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

21
Assets/Scripts/Shop/Model/Item.cs

@ -1,21 +1,29 @@
/// <summary> using UnityEditor.Graphs;
using UnityEngine;
/// <summary>
/// This class holds data for an Item. Currently it has a name, an iconName and a base price. /// This class holds data for an Item. Currently it has a name, an iconName and a base price.
/// </summary> /// </summary>
public abstract class Item public abstract class Item
{ {
public readonly string name; public readonly string name;
public readonly string iconName; public readonly string iconName;
public readonly string description;
public readonly ItemRarity rarity;
public int basePrice { get; private set; } // This is the base price for the item, the buying and selling prices can be public int basePrice { get; private set; } // This is the base price for the item, the buying and selling prices can be
// generated based on this value. // generated based on this value.
//------------------------------------------------------------------------------------------------------------------------ //------------------------------------------------------------------------------------------------------------------------
// Item() // Item()
//------------------------------------------------------------------------------------------------------------------------ //------------------------------------------------------------------------------------------------------------------------
public Item(string name, string iconName, int pbasePrice) public Item(string name, string iconName, int pbasePrice, string itemDescr = "")
{ {
this.name = name; this.name = name;
this.iconName = iconName; this.iconName = iconName;
this.basePrice = pbasePrice; this.basePrice = pbasePrice;
description = itemDescr;
rarity = ItemRarity.UltraRare;
} }
// This is supposed to return what type an item identifies as, purely used for filtering // This is supposed to return what type an item identifies as, purely used for filtering
@ -35,3 +43,12 @@ public enum ItemType
Potion Potion
} }
public enum ItemRarity : uint // Int representing color, so that this enum not only works as an identifier, but also contains name and col in just 32 bits. C#-Magic!
{
Common = 0xFFFFFFFF,
Uncommon = 0xFFFF00FF,
Rare = 0xFF0000FF,
UltraRare = 0xFF00FFFF,
Unique = 0x00FF00FF
}

2
Assets/Scripts/Shop/Model/ItemWeapon.cs

@ -6,7 +6,7 @@ public class ItemWeapon : Item
{ {
public readonly int Attack; public readonly int Attack;
public readonly int Damage; public readonly int Damage;
public ItemWeapon(string name, string iconName, int pbasePrice,int pAttack, int pDamage) : base(name, iconName, pbasePrice) public ItemWeapon(string name, string iconName, int pbasePrice,int pAttack, int pDamage, string descr = "") : base(name, iconName, pbasePrice, descr)
{ {
Attack = pAttack; Attack = pAttack;
Damage = pDamage; Damage = pDamage;

2
Assets/Scripts/Shop/Scriptable Objects/ScriptedWeapon.cs

@ -11,6 +11,6 @@ public class ScriptedWeapon : ScriptedItem
public int Damage; public int Damage;
public override Item GenerateItem() public override Item GenerateItem()
{ {
return new ItemWeapon(Name, Sprite.name, Price, Attack, Damage); return new ItemWeapon(Name, Sprite.name, Price, Attack, Damage,Description);
} }
} }

37
Assets/Scripts/Shop/View/ViewItemInfoPanel.cs

@ -11,7 +11,12 @@ using UnityEngine;
/// </summary> /// </summary>
public class ViewItemInfoPanel : MonoBehaviour public class ViewItemInfoPanel : MonoBehaviour
{ {
private List<ItemNameDisplay> names;// = new List<ItemNameDisplay>(); private List<ItemNameDisplay> names;
private List<ItemStatsDisplay> stats;
private List<ItemTypeDisplay> types;
private List<ItemPriceDisplay> prices;
private List<ItemDescriptionDisplay> descr;
private List<ItemClassDisplay> rarity;
private void Awake() private void Awake()
{ {
UpdateComponentInfo(); UpdateComponentInfo();
@ -21,6 +26,11 @@ public class ViewItemInfoPanel : MonoBehaviour
{ {
names = GetComponentsInChildren<ItemNameDisplay>().ToList(); names = GetComponentsInChildren<ItemNameDisplay>().ToList();
Debug.Assert(names != null,this); Debug.Assert(names != null,this);
stats = GetComponentsInChildren<ItemStatsDisplay>().ToList();
types = GetComponentsInChildren<ItemTypeDisplay>().ToList();
prices = GetComponentsInChildren<ItemPriceDisplay>().ToList();
descr = GetComponentsInChildren<ItemDescriptionDisplay>().ToList();
rarity = GetComponentsInChildren<ItemClassDisplay>().ToList();
//if (names == null) names = ; //if (names == null) names = ;
// TODO: Create and add all other types in here as components! // TODO: Create and add all other types in here as components!
} }
@ -39,5 +49,30 @@ public class ViewItemInfoPanel : MonoBehaviour
{ {
name.SetName(item.name); name.SetName(item.name);
} }
foreach (var itemStatsDisplay in stats)
{
itemStatsDisplay.SetStats(item.GetStats());
}
foreach (var type in types)
{
type.SetType(item.GetItemType().ToString());
}
foreach (var price in prices)
{
price.SetPrice(item.basePrice); // TODO: Price modifier here!
}
foreach (var descriptionDisplay in descr)
{
descriptionDisplay.SetDescription(item.description);
}
foreach (var itemClass in rarity)
{
itemClass.SetClass(item.rarity);
}
} }
} }

Loading…
Cancel
Save