diff --git a/Assets/Icons/cow-selected.png b/Assets/Icons/cow-selected.png new file mode 100644 index 0000000..999aa1e Binary files /dev/null and b/Assets/Icons/cow-selected.png differ diff --git a/Assets/Icons/cow-selected.png.meta b/Assets/Icons/cow-selected.png.meta new file mode 100644 index 0000000..8582ad6 --- /dev/null +++ b/Assets/Icons/cow-selected.png.meta @@ -0,0 +1,122 @@ +fileFormatVersion: 2 +guid: 432d303bbfc9d6f409aa93b6081306e5 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + 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 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 0 + 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: 32 + 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 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 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 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + nameFileIdTable: {} + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/AnimalShopSlot.prefab b/Assets/Resources/AnimalShopSlot.prefab new file mode 100644 index 0000000..e1e5e52 --- /dev/null +++ b/Assets/Resources/AnimalShopSlot.prefab @@ -0,0 +1,665 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &5121261191727116857 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 5121261191727116854} + - component: {fileID: 5121261191727116852} + - component: {fileID: 5121261191727116855} + m_Layer: 5 + m_Name: Image + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &5121261191727116854 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261191727116857} + 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: 5121261193055935940} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0.5} + m_AnchorMax: {x: 0, y: 0.5} + m_AnchoredPosition: {x: 40, y: 0} + m_SizeDelta: {x: 64, y: 64} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &5121261191727116852 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261191727116857} + m_CullTransparentMesh: 1 +--- !u!114 &5121261191727116855 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261191727116857} + m_Enabled: 0 + 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: 0 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!1 &5121261192300927451 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 5121261192300927448} + - component: {fileID: 5121261192300927446} + - component: {fileID: 5121261192300927449} + m_Layer: 5 + m_Name: Animal Cost + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &5121261192300927448 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192300927451} + 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: 5121261193055935940} + 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: 111.99999, y: -56} + m_SizeDelta: {x: 60, y: 32} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &5121261192300927446 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192300927451} + m_CullTransparentMesh: 1 +--- !u!114 &5121261192300927449 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192300927451} + 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: 0 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: + 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: 16 + m_fontSizeBase: 16 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 1 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!1 &5121261192606669394 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 5121261192606669395} + - component: {fileID: 5121261192606669393} + - component: {fileID: 5121261192606669392} + m_Layer: 5 + m_Name: Animal Amount + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &5121261192606669395 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192606669394} + 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: 5121261193055935940} + m_RootOrder: 3 + 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: 62, y: -16} + m_SizeDelta: {x: 60, y: 32} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &5121261192606669393 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192606669394} + m_CullTransparentMesh: 1 +--- !u!114 &5121261192606669392 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192606669394} + 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: 0 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: + 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: 16 + m_fontSizeBase: 16 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 1 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!1 &5121261192692990486 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 5121261192692990487} + - component: {fileID: 5121261192692990485} + - component: {fileID: 5121261192692990484} + m_Layer: 5 + m_Name: Animal Name + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &5121261192692990487 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192692990486} + 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: 5121261193055935940} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 142, y: -24} + m_SizeDelta: {x: 120, y: 32} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &5121261192692990485 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192692990486} + m_CullTransparentMesh: 1 +--- !u!114 &5121261192692990484 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261192692990486} + 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: 0 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: + 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: 18 + m_fontSizeBase: 18 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 1 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 1 + 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!1 &5121261193055935943 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 5121261193055935940} + - component: {fileID: 5121261193055935937} + - component: {fileID: 5121261193055935936} + - component: {fileID: 5121261193055935939} + - component: {fileID: 3899904024433046149} + - component: {fileID: 5121261193055935941} + m_Layer: 5 + m_Name: AnimalShopSlot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &5121261193055935940 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261193055935943} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 5121261191727116854} + - {fileID: 5121261192692990487} + - {fileID: 5121261192300927448} + - {fileID: 5121261192606669395} + m_Father: {fileID: 0} + m_RootOrder: 0 + 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: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &5121261193055935937 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261193055935943} + m_CullTransparentMesh: 1 +--- !u!114 &5121261193055935936 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261193055935943} + 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: 349d3f5d7a4156146b8e923d5c06314d, 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!114 &5121261193055935939 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261193055935943} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 0 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 5121261193055935936} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 3899904024433046149} + m_TargetAssemblyTypeName: AnimalShopSlot, Assembly-CSharp + m_MethodName: UseElement + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &3899904024433046149 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261193055935943} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 12dc6c16906d3994380888118d0da675, type: 3} + m_Name: + m_EditorClassIdentifier: + image: {fileID: 5121261191727116855} + amountText: {fileID: 5121261192606669392} + timeToWait: 0.5 + nameText: {fileID: 5121261192692990484} + costText: {fileID: 5121261192300927449} +--- !u!61 &5121261193055935941 +BoxCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5121261193055935943} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 1 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: 0, y: 0} + m_SpriteTilingProperty: + border: {x: 0, y: 0, z: 0, w: 0} + pivot: {x: 0, y: 0} + oldSize: {x: 0, y: 0} + newSize: {x: 0, y: 0} + adaptiveTilingThreshold: 0 + drawMode: 0 + adaptiveTiling: 0 + m_AutoTiling: 0 + serializedVersion: 2 + m_Size: {x: 1, y: 1} + m_EdgeRadius: 0 diff --git a/Assets/Resources/AnimalShopSlot.prefab.meta b/Assets/Resources/AnimalShopSlot.prefab.meta new file mode 100644 index 0000000..9ee735a --- /dev/null +++ b/Assets/Resources/AnimalShopSlot.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 5719971c822f74e4ca86130b5e77b1d5 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/Cow.prefab b/Assets/Resources/Cow.prefab index b5d49c8..31b8184 100644 --- a/Assets/Resources/Cow.prefab +++ b/Assets/Resources/Cow.prefab @@ -157,6 +157,12 @@ MonoBehaviour: m_EditorClassIdentifier: producedItem: {fileID: 11400000, guid: 510712f2d23afc147979bcd564ef7943, type: 2} movementSpeed: 1 + animalPrefab: {fileID: 2510115116361252817} + defaultSprite: {fileID: 21300000, guid: e2bde586482642d44a270276574c0129, type: 3} + selectedSprite: {fileID: 21300000, guid: 432d303bbfc9d6f409aa93b6081306e5, type: 3} + displayName: Cow + description: Mach Milch, hat Fell + price: 500 --- !u!95 &3084876974777557816 Animator: serializedVersion: 4 diff --git a/Assets/Resources/InventorySlot.prefab b/Assets/Resources/InventorySlot.prefab index 517a66a..cbdbea9 100644 --- a/Assets/Resources/InventorySlot.prefab +++ b/Assets/Resources/InventorySlot.prefab @@ -147,7 +147,7 @@ GameObject: - component: {fileID: 3510585822736120664} - component: {fileID: 3510585822736120665} m_Layer: 5 - m_Name: Icon + m_Name: Image m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -360,7 +360,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 92863b15e86b5b94e9a331f3c97dddca, type: 3} m_Name: m_EditorClassIdentifier: - icon: {fileID: 3510585822736120665} + image: {fileID: 3510585822736120665} amountText: {fileID: 2490526733276001243} timeToWait: 0.5 --- !u!61 &-6709197434562003015 diff --git a/Assets/Resources/ShopSlot.prefab b/Assets/Resources/ItemShopSlot.prefab similarity index 99% rename from Assets/Resources/ShopSlot.prefab rename to Assets/Resources/ItemShopSlot.prefab index b0d8865..8e41c51 100644 --- a/Assets/Resources/ShopSlot.prefab +++ b/Assets/Resources/ItemShopSlot.prefab @@ -12,7 +12,7 @@ GameObject: - component: {fileID: 5121261191727116852} - component: {fileID: 5121261191727116855} m_Layer: 5 - m_Name: Icon + m_Name: Image m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -496,7 +496,7 @@ GameObject: - component: {fileID: 5121261193055935938} - component: {fileID: 5121261193055935941} m_Layer: 5 - m_Name: ShopSlot + m_Name: ItemShopSlot m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -632,7 +632,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 3e6f808bd381a554eb64a7e84f997f45, type: 3} m_Name: m_EditorClassIdentifier: - icon: {fileID: 5121261191727116855} + image: {fileID: 5121261191727116855} amountText: {fileID: 5121261192606669392} timeToWait: 0.5 nameText: {fileID: 5121261192692990484} diff --git a/Assets/Resources/ShopSlot.prefab.meta b/Assets/Resources/ItemShopSlot.prefab.meta similarity index 100% rename from Assets/Resources/ShopSlot.prefab.meta rename to Assets/Resources/ItemShopSlot.prefab.meta diff --git a/Assets/Scenes/MainScene.unity b/Assets/Scenes/MainScene.unity index 68417ff..95b802c 100644 --- a/Assets/Scenes/MainScene.unity +++ b/Assets/Scenes/MainScene.unity @@ -463,6 +463,11 @@ BoxCollider2D: serializedVersion: 2 m_Size: {x: 1, y: 12} m_EdgeRadius: 0 +--- !u!224 &73476565 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 328099661} + m_PrefabAsset: {fileID: 0} --- !u!224 &94990416 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} @@ -573,6 +578,141 @@ PrefabInstance: objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} +--- !u!1 &118246656 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 118246661} + - component: {fileID: 118246660} + - component: {fileID: 118246659} + - component: {fileID: 118246658} + - component: {fileID: 118246657} + - component: {fileID: 118246662} + m_Layer: 5 + m_Name: ViewportAnimals + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &118246657 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118246656} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 30649d3a9faa99c48a7b1166b86bf2a0, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_ChildAlignment: 0 + m_Spacing: 0 + m_ChildForceExpandWidth: 1 + m_ChildForceExpandHeight: 1 + m_ChildControlWidth: 1 + m_ChildControlHeight: 1 + m_ChildScaleWidth: 0 + m_ChildScaleHeight: 0 + m_ReverseArrangement: 0 +--- !u!114 &118246658 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118246656} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 31a19414c41e5ae4aae2af33fee712f6, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ShowMaskGraphic: 0 +--- !u!114 &118246659 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118246656} + 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: 10917, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &118246660 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118246656} + m_CullTransparentMesh: 1 +--- !u!224 &118246661 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118246656} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 1727335397} + m_Father: {fileID: 656110741} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: -40} + m_SizeDelta: {x: -17, y: -40} + m_Pivot: {x: 0, y: 1} +--- !u!114 &118246662 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118246656} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2c06d4c2082cfaa48ab284fbf112290b, type: 3} + m_Name: + m_EditorClassIdentifier: + startElements: + - {fileID: 4094795090309576525, guid: 547dbbf4c5377dc409dfea772c096434, type: 3} + - {fileID: 4094795090309576525, guid: 547dbbf4c5377dc409dfea772c096434, type: 3} + - {fileID: 4094795090309576525, guid: 547dbbf4c5377dc409dfea772c096434, type: 3} --- !u!1 &131335458 GameObject: m_ObjectHideFlags: 0 @@ -1041,7 +1181,7 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} - m_AnchoredPosition: {x: -10.000069, y: 313.96454} + m_AnchoredPosition: {x: -9.999996, y: 313.96454} m_SizeDelta: {x: -170, y: -573.1271} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &157569881 @@ -1195,6 +1335,11 @@ PrefabInstance: objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} +--- !u!224 &171006844 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 1856825636} + m_PrefabAsset: {fileID: 0} --- !u!224 &261459150 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} @@ -1415,6 +1560,103 @@ RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} m_PrefabInstance: {fileID: 1214393276} m_PrefabAsset: {fileID: 0} +--- !u!1001 &328099661 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 3 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (3) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} --- !u!224 &360765099 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} @@ -1572,6 +1814,11 @@ PrefabInstance: objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} +--- !u!224 &457472324 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 1060658400} + m_PrefabAsset: {fileID: 0} --- !u!1 &479705986 GameObject: m_ObjectHideFlags: 0 @@ -1635,6 +1882,103 @@ RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} m_PrefabInstance: {fileID: 1794784497} m_PrefabAsset: {fileID: 0} +--- !u!1001 &487963575 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 2 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (2) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} --- !u!1001 &495860598 PrefabInstance: m_ObjectHideFlags: 0 @@ -1900,6 +2244,103 @@ RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} m_PrefabInstance: {fileID: 296679588} m_PrefabAsset: {fileID: 0} +--- !u!1001 &549617644 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} --- !u!1 &580139580 GameObject: m_ObjectHideFlags: 0 @@ -1933,7 +2374,7 @@ RectTransform: m_Children: - {fileID: 1169358018} m_Father: {fileID: 656110741} - m_RootOrder: 1 + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 1, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -1983,8 +2424,8 @@ MonoBehaviour: m_TargetGraphic: {fileID: 2006577139} m_HandleRect: {fileID: 2006577138} m_Direction: 2 - m_Value: 0.9999998 - m_Size: 0.59851277 + m_Value: 1 + m_Size: 0.59851265 m_NumberOfSteps: 0 m_OnValueChanged: m_PersistentCalls: @@ -2207,8 +2648,9 @@ GameObject: - component: {fileID: 610140156} - component: {fileID: 610140155} - component: {fileID: 610140158} + - component: {fileID: 610140159} m_Layer: 5 - m_Name: Viewport + m_Name: ViewportItems m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -2312,6 +2754,44 @@ MonoBehaviour: m_ChildScaleWidth: 0 m_ChildScaleHeight: 0 m_ReverseArrangement: 0 +--- !u!114 &610140159 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 610140153} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: bc5eb8967b8912c42b93a2086383ddd9, type: 3} + m_Name: + m_EditorClassIdentifier: + startElements: + - {fileID: 11400000, guid: a5d525b8ca07172499e8678eb6f73fb2, type: 2} + - {fileID: 11400000, guid: a5d525b8ca07172499e8678eb6f73fb2, type: 2} + - {fileID: 11400000, guid: a5d525b8ca07172499e8678eb6f73fb2, type: 2} + - {fileID: 11400000, guid: a5d525b8ca07172499e8678eb6f73fb2, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} + itemWasBought: 0 --- !u!1 &615358670 GameObject: m_ObjectHideFlags: 0 @@ -2421,6 +2901,7 @@ RectTransform: m_ConstrainProportionsScale: 0 m_Children: - {fileID: 610140154} + - {fileID: 118246661} - {fileID: 580139581} m_Father: {fileID: 1203044072} m_RootOrder: 0 @@ -2498,6 +2979,103 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 656110740} m_CullTransparentMesh: 1 +--- !u!1001 &690902564 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (1) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} --- !u!1001 &729139770 PrefabInstance: m_ObjectHideFlags: 0 @@ -4219,6 +4797,200 @@ RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} m_PrefabInstance: {fileID: 160321877} m_PrefabAsset: {fileID: 0} +--- !u!1001 &1057055184 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (5) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} +--- !u!1001 &1060658400 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 7 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (7) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} --- !u!1 &1061398530 GameObject: m_ObjectHideFlags: 0 @@ -5338,8 +6110,8 @@ RectTransform: m_ConstrainProportionsScale: 0 m_Children: - {fileID: 656110741} - - {fileID: 1785473025} - {fileID: 1566847388} + - {fileID: 1785473025} - {fileID: 157569880} m_Father: {fileID: 1671356617} m_RootOrder: 0 @@ -5830,7 +6602,7 @@ RectTransform: m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 16, y: 16} + m_SizeDelta: {x: 26, y: 26} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &1271600642 MonoBehaviour: @@ -5839,7 +6611,7 @@ MonoBehaviour: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1271600640} - m_Enabled: 1 + m_Enabled: 0 m_EditorHideFlags: 0 m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} m_Name: @@ -5852,7 +6624,7 @@ MonoBehaviour: m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_Sprite: {fileID: 21300000, guid: e2bde586482642d44a270276574c0129, type: 3} + m_Sprite: {fileID: 0} m_Type: 0 m_PreserveAspect: 0 m_FillCenter: 1 @@ -6601,6 +7373,11 @@ Canvas: m_SortingLayerID: 0 m_SortingOrder: 20 m_TargetDisplay: 0 +--- !u!224 &1427673767 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 549617644} + m_PrefabAsset: {fileID: 0} --- !u!1001 &1437854976 PrefabInstance: m_ObjectHideFlags: 0 @@ -7227,10 +8004,10 @@ RectTransform: m_Father: {fileID: 157569880} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.5, y: 0.5} - m_AnchorMax: {x: 0.5, y: 0.5} - m_AnchoredPosition: {x: -0.00006866455, y: -0.000030517578} - m_SizeDelta: {x: 200, y: 50} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0.000030517578, y: 0} + m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &1520388889 MonoBehaviour: @@ -7246,13 +8023,13 @@ MonoBehaviour: m_EditorClassIdentifier: m_Material: {fileID: 0} m_Color: {r: 1, g: 1, b: 1, a: 1} - m_RaycastTarget: 1 + m_RaycastTarget: 0 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_text: Shop + m_text: Item \nShop m_isRightToLeft: 0 m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} @@ -7279,8 +8056,8 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 32 - m_fontSizeBase: 32 + m_fontSize: 20 + m_fontSizeBase: 20 m_fontWeight: 400 m_enableAutoSizing: 0 m_fontSizeMin: 18 @@ -7444,8 +8221,14 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: itemsParent: {fileID: 610140154} + animalsParent: {fileID: 118246661} shopUI: {fileID: 1671356616} inventoryUI: {fileID: 1609015285} +--- !u!224 &1548945806 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 1057055184} + m_PrefabAsset: {fileID: 0} --- !u!224 &1551890462 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} @@ -7485,12 +8268,12 @@ RectTransform: m_Children: - {fileID: 1271600641} m_Father: {fileID: 1203044072} - m_RootOrder: 2 + m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} - m_AnchoredPosition: {x: 82.5, y: 292.75} - m_SizeDelta: {x: -225, y: -604.5} + m_AnchoredPosition: {x: 83, y: 291.75} + m_SizeDelta: {x: -218, y: -602.5} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &1566847389 MonoBehaviour: @@ -7504,8 +8287,13 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 47545d0c6734b804c9407d5752a08ee4, type: 3} m_Name: m_EditorClassIdentifier: - animalShopSprite: {fileID: 0} - itemShopSprite: {fileID: 0} + animalShopSprite: {fileID: 21300000, guid: e2bde586482642d44a270276574c0129, type: 3} + itemShopSprite: {fileID: 21300156, guid: 2700e06d970d112489ff23cfb58c3f78, type: 3} + switchButtonImage: {fileID: 1271600642} + shopTitleText: {fileID: 1520388889} + viewportItems: {fileID: 610140153} + viewportAnimals: {fileID: 118246656} + undoPurchaseButton: {fileID: 1785473024} --- !u!114 &1566847390 MonoBehaviour: m_ObjectHideFlags: 0 @@ -7550,9 +8338,9 @@ MonoBehaviour: m_OnClick: m_PersistentCalls: m_Calls: - - m_Target: {fileID: 1671356619} - m_TargetAssemblyTypeName: Shop, Assembly-CSharp - m_MethodName: UndoLastPurchase + - m_Target: {fileID: 1566847389} + m_TargetAssemblyTypeName: ShopSwitcher, Assembly-CSharp + m_MethodName: SwitchShops m_Mode: 1 m_Arguments: m_ObjectArgument: {fileID: 0} @@ -7793,7 +8581,6 @@ GameObject: m_Component: - component: {fileID: 1671356617} - component: {fileID: 1671356618} - - component: {fileID: 1671356619} m_Layer: 5 m_Name: Shop m_TagString: Untagged @@ -7830,40 +8617,11 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1671356616} m_CullTransparentMesh: 1 ---- !u!114 &1671356619 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} +--- !u!224 &1682972070 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 1959746384} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1671356616} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: bc5eb8967b8912c42b93a2086383ddd9, type: 3} - m_Name: - m_EditorClassIdentifier: - startElements: - - {fileID: 11400000, guid: 7fc4aaa640c1c1e49a0c0a9241fbcf07, type: 2} - - {fileID: 11400000, guid: a5d525b8ca07172499e8678eb6f73fb2, type: 2} - - {fileID: 11400000, guid: a5d525b8ca07172499e8678eb6f73fb2, type: 2} - - {fileID: 11400000, guid: a5d525b8ca07172499e8678eb6f73fb2, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: d115e153d89653b4f9a74f920d055a93, type: 2} - - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} - - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} - - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} - - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} - - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} - - {fileID: 11400000, guid: bb9777a7d5804bd6bf25d5510206aaf0, type: 2} - itemWasBought: 0 --- !u!1001 &1701153146 PrefabInstance: m_ObjectHideFlags: 0 @@ -7969,6 +8727,76 @@ PrefabInstance: objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} +--- !u!1 &1727335396 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1727335397} + - component: {fileID: 1727335398} + m_Layer: 5 + m_Name: Content + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1727335397 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1727335396} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 1427673767} + - {fileID: 2111272053} + - {fileID: 1867225434} + - {fileID: 73476565} + - {fileID: 171006844} + - {fileID: 1548945806} + - {fileID: 1682972070} + - {fileID: 457472324} + - {fileID: 1858155276} + m_Father: {fileID: 118246661} + m_RootOrder: 0 + 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: 0, y: 0} + m_Pivot: {x: 0, y: 1} +--- !u!114 &1727335398 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1727335396} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8a8695521f0d02e499659fee002a26c2, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 20 + m_Right: 20 + m_Top: 0 + m_Bottom: 20 + m_ChildAlignment: 0 + m_StartCorner: 0 + m_StartAxis: 0 + m_CellSize: {x: 220, y: 80} + m_Spacing: {x: 20, y: 20} + m_Constraint: 0 + m_ConstraintCount: 2 --- !u!1 &1785473024 GameObject: m_ObjectHideFlags: 0 @@ -7997,16 +8825,16 @@ RectTransform: m_GameObject: {fileID: 1785473024} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1.0640067, y: 1.0640067, z: 1.0640067} + m_LocalScale: {x: 1.0640069, y: 1.0640069, z: 1.0640069} m_ConstrainProportionsScale: 0 m_Children: - {fileID: 144989858} m_Father: {fileID: 1203044072} - m_RootOrder: 1 + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} - m_AnchoredPosition: {x: -10, y: 255} + m_AnchoredPosition: {x: -9.999996, y: 255} m_SizeDelta: {x: -100, y: -590} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &1785473026 @@ -8053,7 +8881,7 @@ MonoBehaviour: m_OnClick: m_PersistentCalls: m_Calls: - - m_Target: {fileID: 1671356619} + - m_Target: {fileID: 0} m_TargetAssemblyTypeName: Shop, Assembly-CSharp m_MethodName: UndoLastPurchase m_Mode: 1 @@ -8420,6 +9248,103 @@ PrefabInstance: objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} +--- !u!1001 &1806125927 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 8 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (8) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} --- !u!1 &1822910517 GameObject: m_ObjectHideFlags: 0 @@ -8544,6 +9469,113 @@ PrefabInstance: objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 547dbbf4c5377dc409dfea772c096434, type: 3} +--- !u!1001 &1856825636 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 4 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (4) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} +--- !u!224 &1858155276 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 1806125927} + m_PrefabAsset: {fileID: 0} +--- !u!224 &1867225434 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 487963575} + m_PrefabAsset: {fileID: 0} --- !u!1001 &1868238650 PrefabInstance: m_ObjectHideFlags: 0 @@ -8956,6 +9988,103 @@ RectTransform: m_CorrespondingSourceObject: {fileID: 3510585822996971025, guid: 44dae5fbdb6f7df4f93a10807f66956f, type: 3} m_PrefabInstance: {fileID: 2069667813} m_PrefabAsset: {fileID: 0} +--- !u!1001 &1959746384 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 1727335397} + m_Modifications: + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_RootOrder + value: 6 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_SizeDelta.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5121261193055935943, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + propertyPath: m_Name + value: AnimalShopSlot (6) + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} --- !u!1 &1960980871 GameObject: m_ObjectHideFlags: 0 @@ -9732,6 +10861,11 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 2091640948} m_CullTransparentMesh: 1 +--- !u!224 &2111272053 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 5121261193055935940, guid: 5719971c822f74e4ca86130b5e77b1d5, type: 3} + m_PrefabInstance: {fileID: 690902564} + m_PrefabAsset: {fileID: 0} --- !u!1 &2129367633 GameObject: m_ObjectHideFlags: 0 diff --git a/Assets/Scripts/Animal.cs b/Assets/Scripts/Animal.cs index 62fa039..3c6b821 100644 --- a/Assets/Scripts/Animal.cs +++ b/Assets/Scripts/Animal.cs @@ -1,29 +1,32 @@ using System; using System.Collections; -using Actions; -using DefaultNamespace; using UnityEngine; -using Object = System.Object; using Random = UnityEngine.Random; public class Animal : MonoBehaviour { private Rigidbody2D _rigidbody; private SpriteRenderer _spriteRenderer; - private Sprite _animalSprite; private Animator _animator; private int _animMoveID; - public Sprite AnimalSprite => _animalSprite; + public int SellPrice => Convert.ToInt32(price * 0.8); public Item producedItem; public int movementSpeed; + public GameObject animalPrefab; + public Sprite defaultSprite; + public Sprite selectedSprite; + public string displayName; + public string description; + public int price; private void Start() { _rigidbody = gameObject.GetComponent(); _spriteRenderer = gameObject.GetComponent(); - _animalSprite = _spriteRenderer.GetComponent(); _animator = gameObject.GetComponent(); _animMoveID = Animator.StringToHash("moving"); + + _spriteRenderer.sprite = defaultSprite; // Move the Animal in any random direction every 1-5s InvokeRepeating(nameof(MoveInRandomDirection), 2f, Random.Range(1f, 5f)); diff --git a/Assets/Scripts/ElementStorage.cs b/Assets/Scripts/ElementStorage.cs index b907c1c..de85859 100644 --- a/Assets/Scripts/ElementStorage.cs +++ b/Assets/Scripts/ElementStorage.cs @@ -1,4 +1,5 @@ using System.Collections.Generic; +using UnityEditorInternal; using UnityEngine; public class ElementStorage : MonoBehaviour { @@ -7,7 +8,7 @@ public class ElementStorage : MonoBehaviour { public T[] startElements; /** - * Methods can be added to this and they will get called every time onItemChangedCallback gets Invoked + * Methods can be added to this and they will get called every time onElementChangedCallback gets Invoked */ public delegate void OnElementChanged(); public OnElementChanged onElementChangedCallback; diff --git a/Assets/Scripts/ElementStorageSlot.cs b/Assets/Scripts/ElementStorageSlot.cs index 62c9b9f..e72e4ec 100644 --- a/Assets/Scripts/ElementStorageSlot.cs +++ b/Assets/Scripts/ElementStorageSlot.cs @@ -5,7 +5,7 @@ using UnityEngine.EventSystems; using UnityEngine.UI; public class ElementStorageSlot : MonoBehaviour, IPointerEnterHandler, IPointerExitHandler { - public Image icon; + public Image image; public TextMeshProUGUI amountText; public T Element => _element; @@ -30,20 +30,22 @@ public class ElementStorageSlot : MonoBehaviour, IPointerEnterHandler, IPoint } private void ShowMessage() { - if(_element is Item) { //TODO: add animal description showing + if(_element is Item) { Item item = (Item)(object)_element; HoverManager.onMouseHoverDescription(item.description, Input.mousePosition); + } else if(_element is Animal) { + Animal animal = (Animal)(object)_element; + HoverManager.onMouseHoverDescription(animal.description, Input.mousePosition); } } public void ChangeElementSelectedSprite(bool on) { if(_element is Item) { //TODO: add animal sprite change Item item = (Item)(object)_element; - if(on) { - icon.sprite = item.selectedSprite; - } else { - icon.sprite = item.defaultSprite; - } + image.sprite = on ? item.selectedSprite : item.defaultSprite; + }else if(_element is Animal) { + Animal animal = (Animal)(object)_element; + image.sprite = on ? animal.selectedSprite : animal.defaultSprite; } } @@ -61,12 +63,15 @@ public class ElementStorageSlot : MonoBehaviour, IPointerEnterHandler, IPoint public void AddElement(T newElement) { _element = newElement; - if(_element is Item) { //TODO: add animal sprite change + if(_element is Item) { Item item = (Item)(object)_element; - icon.sprite = item.defaultSprite; + image.sprite = item.defaultSprite; + } else if (_element is Animal) { + Animal animal = (Animal)(object)_element; + image.sprite = animal.defaultSprite; } - icon.enabled = true; + image.enabled = true; } /** @@ -74,8 +79,8 @@ public class ElementStorageSlot : MonoBehaviour, IPointerEnterHandler, IPoint */ public virtual void ClearSlot() { _element = default; - icon.sprite = null; - icon.enabled = false; + image.sprite = null; + image.enabled = false; amountText.text = ""; } diff --git a/Assets/Scripts/Inventory.cs b/Assets/Scripts/Inventory.cs index 6b431e5..256f79c 100644 --- a/Assets/Scripts/Inventory.cs +++ b/Assets/Scripts/Inventory.cs @@ -1,4 +1,5 @@ using System; +using Shop; using UnityEngine; public class Inventory : ElementStorage { @@ -50,7 +51,7 @@ public class Inventory : ElementStorage { */ public void SellItem(Item item, int amount) { PlayerController.instance.ChangeMoney(item.SellPrice); - Shop.instance.AddElement(item, amount); + ItemShop.instance.AddElement(item, amount); RemoveElement(item, amount); } } \ No newline at end of file diff --git a/Assets/Scripts/InventorySlot.cs b/Assets/Scripts/InventorySlot.cs index 666afe4..ff709c1 100644 --- a/Assets/Scripts/InventorySlot.cs +++ b/Assets/Scripts/InventorySlot.cs @@ -34,7 +34,7 @@ public class InventorySlot : ElementStorageSlot, IPointerClickHandler { // When clicked on with right Mouse Button sell the Item if(eventData.button == PointerEventData.InputButton.Right) { if(Element) { - _inventory.SellItem(Element, 1); //TODO: wie machen mehr als 1 verkaufen?! + _inventory.SellItem(Element, 1); } } } diff --git a/Assets/Scripts/InventoryUI.cs b/Assets/Scripts/InventoryUI.cs index e0d7bb3..1119c72 100644 --- a/Assets/Scripts/InventoryUI.cs +++ b/Assets/Scripts/InventoryUI.cs @@ -20,7 +20,7 @@ public class InventoryUI : MonoBehaviour { // Set the icon to not be a raycast target for the Description Hovering to work foreach(InventorySlot slot in _slots) { - slot.icon.raycastTarget = false; + slot.image.raycastTarget = false; } } diff --git a/Assets/Scripts/Item.cs b/Assets/Scripts/Item.cs index be06519..64974b0 100644 --- a/Assets/Scripts/Item.cs +++ b/Assets/Scripts/Item.cs @@ -19,7 +19,7 @@ public class Item : ScriptableObject, IComparable { } public int CompareTo(Item other) { - return this._id - other._id; + return _id - other._id; } public void SetID(int id) { diff --git a/Assets/Scripts/Shop.cs b/Assets/Scripts/Shop.cs deleted file mode 100644 index 6bd6e7e..0000000 --- a/Assets/Scripts/Shop.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine; - -public class Shop : ElementStorage { - #region Singleton - - public static Shop instance; - - private void Awake() { - if(instance != null) { - Debug.LogWarning("More than one instance of Shop found"); - } - - instance = this; - } - - #endregion - - public bool itemWasBought; - - private PlayerController _playerController; - private Inventory _inventory; - private Item _lastBoughtItem; - private int _lastBoughtItemAmount; - - /** - * Calls ItemStorage.RemoveItem() and sets 2 Variables to remember the last bought item - */ - public override void RemoveElement(Item item, int amount) { - base.RemoveElement(item, amount); - if(itemWasBought){ - _lastBoughtItem = item; - _lastBoughtItemAmount = amount; - } - } - - public void UndoLastPurchase() { - if(itemWasBought){ - _inventory = Inventory.instance; - _playerController = PlayerController.instance; - - if(_lastBoughtItem) { - _playerController.ChangeMoney(_lastBoughtItem.price); - _inventory.RemoveElement(_lastBoughtItem, _lastBoughtItemAmount); - AddElement(_lastBoughtItem, _lastBoughtItemAmount); - itemWasBought = false; - } - } - } -} \ No newline at end of file diff --git a/Assets/Scripts/Shop.meta b/Assets/Scripts/Shop.meta new file mode 100644 index 0000000..f9c8792 --- /dev/null +++ b/Assets/Scripts/Shop.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: f4055d199c2a43b6a92f4a3704e3018a +timeCreated: 1656014917 \ No newline at end of file diff --git a/Assets/Scripts/Shop/AnimalShop.cs b/Assets/Scripts/Shop/AnimalShop.cs new file mode 100644 index 0000000..1391c42 --- /dev/null +++ b/Assets/Scripts/Shop/AnimalShop.cs @@ -0,0 +1,21 @@ +using UnityEngine; + +namespace Shop { + + + public class AnimalShop : ElementStorage { + #region Singleton + + public static AnimalShop instance; + + private void Awake() { + if(instance != null) { + Debug.LogWarning("More than one instance of AnimalShop found"); + } + + instance = this; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Scripts/Shop/AnimalShop.cs.meta b/Assets/Scripts/Shop/AnimalShop.cs.meta new file mode 100644 index 0000000..4fd449b --- /dev/null +++ b/Assets/Scripts/Shop/AnimalShop.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2c06d4c2082cfaa48ab284fbf112290b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/Shop/AnimalShopSlot.cs b/Assets/Scripts/Shop/AnimalShopSlot.cs new file mode 100644 index 0000000..3de548c --- /dev/null +++ b/Assets/Scripts/Shop/AnimalShopSlot.cs @@ -0,0 +1,61 @@ +using TMPro; +using UnityEngine; + +namespace Shop { + + public class AnimalShopSlot : ElementStorageSlot { + public TextMeshProUGUI nameText; + public TextMeshProUGUI costText; + + private AnimalShop _animalShop; + private PlayerController _playerController; + + private void Start() { + _animalShop = AnimalShop.instance; + _playerController = PlayerController.instance; + } + + /** + * Clears the Shop Slot + */ + public override void ClearSlot() { + nameText.text = ""; + costText.text = ""; + amountText.text = ""; + base.ClearSlot(); + } + + /** + * Gets called when the Shop Slot is clicked + */ + public override void UseElement() { + if(Element) { + if(_playerController.Money >= Element.price) { + if(Element) { + _playerController.ChangeMoney(-Element.price); + // Debug.Log("Buying Animal: " + Element.displayName); + } + + PlaceCowRandomlyOnScreen(); + _animalShop.RemoveElement(Element, 1); + } else { + // Debug.Log("Not enough money to buy Animal."); + } + + _animalShop.onElementChangedCallback?.Invoke(); + } + } + + private void PlaceCowRandomlyOnScreen() { + float spawnY = Random.Range + (Camera.main.ScreenToWorldPoint(new Vector2(0, 0)).y, + Camera.main.ScreenToWorldPoint(new Vector2(0, Screen.height)).y); + float spawnX = Random.Range + (Camera.main.ScreenToWorldPoint(new Vector2(0, 0)).x, + Camera.main.ScreenToWorldPoint(new Vector2(Screen.width, 0)).x); + + Vector2 spawnPosition = new Vector2(spawnX, spawnY); + Instantiate(Element.animalPrefab, spawnPosition, Quaternion.identity); + } + } +} \ No newline at end of file diff --git a/Assets/Scripts/Shop/AnimalShopSlot.cs.meta b/Assets/Scripts/Shop/AnimalShopSlot.cs.meta new file mode 100644 index 0000000..7c6ce59 --- /dev/null +++ b/Assets/Scripts/Shop/AnimalShopSlot.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 12dc6c16906d3994380888118d0da675 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/Shop/ItemShop.cs b/Assets/Scripts/Shop/ItemShop.cs new file mode 100644 index 0000000..f3f8b8c --- /dev/null +++ b/Assets/Scripts/Shop/ItemShop.cs @@ -0,0 +1,53 @@ +using UnityEngine; + +namespace Shop { + + + public class ItemShop : ElementStorage { + #region Singleton + + public static ItemShop instance; + + private void Awake() { + if(instance != null) { + Debug.LogWarning("More than one instance of ItemShop found"); + } + + instance = this; + } + + #endregion + + public bool itemWasBought; + + private PlayerController _playerController; + private Inventory _inventory; + private Item _lastBoughtItem; + private int _lastBoughtItemAmount; + + /** + * Calls ElementStorage.RemoveItem() and sets 2 Variables to remember the last bought item + */ + public override void RemoveElement(Item item, int amount) { + base.RemoveElement(item, amount); + if(itemWasBought) { + _lastBoughtItem = item; + _lastBoughtItemAmount = amount; + } + } + + public void UndoLastPurchase() { + if(itemWasBought) { + _inventory = Inventory.instance; + _playerController = PlayerController.instance; + + if(_lastBoughtItem) { + _playerController.ChangeMoney(_lastBoughtItem.price); + _inventory.RemoveElement(_lastBoughtItem, _lastBoughtItemAmount); + AddElement(_lastBoughtItem, _lastBoughtItemAmount); + itemWasBought = false; + } + } + } + } +} \ No newline at end of file diff --git a/Assets/Scripts/Shop.cs.meta b/Assets/Scripts/Shop/ItemShop.cs.meta similarity index 100% rename from Assets/Scripts/Shop.cs.meta rename to Assets/Scripts/Shop/ItemShop.cs.meta diff --git a/Assets/Scripts/Shop/ItemShopSlot.cs b/Assets/Scripts/Shop/ItemShopSlot.cs new file mode 100644 index 0000000..63fb946 --- /dev/null +++ b/Assets/Scripts/Shop/ItemShopSlot.cs @@ -0,0 +1,51 @@ +using TMPro; + +namespace Shop { + public class ItemShopSlot : ElementStorageSlot { + public TextMeshProUGUI nameText; + public TextMeshProUGUI costText; + + private ItemShop _itemShop; + private Inventory _inventory; + private PlayerController _playerController; + + private void Start() { + _itemShop = ItemShop.instance; + _inventory = Inventory.instance; + _playerController = PlayerController.instance; + } + + /** + * Clears the Shop Slot + */ + public override void ClearSlot() { + nameText.text = ""; + costText.text = ""; + amountText.text = ""; + base.ClearSlot(); + } + + /** + * Gets called when the Shop Slot is clicked + */ + public override void UseElement() { + if(Element) { + if(_playerController.Money >= Element.price) { + if(Element) { + _playerController.ChangeMoney(-Element.price); + _itemShop.itemWasBought = true; + // Debug.Log("Buying Item: " + Element.displayName); + } + + _inventory.AddElement(Element, 1); + _itemShop.RemoveElement(Element, 1); + } else { + // Debug.Log("Not enough money to buy Item."); + } + + _itemShop.onElementChangedCallback?.Invoke(); + _inventory.onElementChangedCallback?.Invoke(); + } + } + } +} \ No newline at end of file diff --git a/Assets/Scripts/ShopSlot.cs.meta b/Assets/Scripts/Shop/ItemShopSlot.cs.meta similarity index 100% rename from Assets/Scripts/ShopSlot.cs.meta rename to Assets/Scripts/Shop/ItemShopSlot.cs.meta diff --git a/Assets/Scripts/Shop/ShopSwitcher.cs b/Assets/Scripts/Shop/ShopSwitcher.cs new file mode 100644 index 0000000..1eb6433 --- /dev/null +++ b/Assets/Scripts/Shop/ShopSwitcher.cs @@ -0,0 +1,45 @@ +using TMPro; +using UnityEngine; +using UnityEngine.UI; + +namespace Shop { + + + public class ShopSwitcher : MonoBehaviour { + public Sprite animalShopSprite; + public Sprite itemShopSprite; + public Image switchButtonImage; + public TextMeshProUGUI shopTitleText; + public GameObject viewportItems; + public GameObject viewportAnimals; + public GameObject undoPurchaseButton; + + private void Start() { + switchButtonImage.enabled = true; + switchButtonImage.sprite = animalShopSprite; + + viewportItems.SetActive(true); + viewportAnimals.SetActive(false); + } + + public void SwitchShops() { + // switch Shop Title text and Image of the Button + if(shopTitleText.text.StartsWith("Item")) { + shopTitleText.text = "Animal \nShop"; + switchButtonImage.sprite = itemShopSprite; + } else { + shopTitleText.text = "Item \nShop"; + switchButtonImage.sprite = animalShopSprite; + } + + // switch the shown shops + viewportItems.SetActive(!viewportItems.activeSelf); + viewportAnimals.SetActive(!viewportAnimals.activeSelf); + + // turn off undoPurchaseButton when opening Animal Shop because of lack of undoing purchases in the Animal Shop + undoPurchaseButton.SetActive(!undoPurchaseButton.activeSelf); + + // remove undo purchase button when switching to an animal shop and fix content alignement + } + } +} diff --git a/Assets/Scripts/ShopSwitcher.cs.meta b/Assets/Scripts/Shop/ShopSwitcher.cs.meta similarity index 100% rename from Assets/Scripts/ShopSwitcher.cs.meta rename to Assets/Scripts/Shop/ShopSwitcher.cs.meta diff --git a/Assets/Scripts/Shop/ShopUI.cs b/Assets/Scripts/Shop/ShopUI.cs new file mode 100644 index 0000000..0c0071d --- /dev/null +++ b/Assets/Scripts/Shop/ShopUI.cs @@ -0,0 +1,85 @@ +using System.Linq; +using UnityEngine; + +namespace Shop { + public class ShopUI : MonoBehaviour { + public Transform itemsParent; + public Transform animalsParent; + public GameObject shopUI; + public GameObject inventoryUI; + + private ItemShop _itemShop; + private AnimalShop _animalShop; + private ItemShopSlot[] _itemSlots; + private AnimalShopSlot[] _animalSlots; + + private void Start() { + // Get Shop instance and add UpdateUI method to OnItemChanged delegate + _itemShop = ItemShop.instance; + _animalShop = AnimalShop.instance; + _itemShop.onElementChangedCallback += UpdateUI; + _animalShop.onElementChangedCallback += UpdateUI; + + // Add all ItemShopSlot GameObjects to _itemSlots and turn off the Shop UI + _itemSlots = itemsParent.GetComponentsInChildren(); + _animalSlots = animalsParent.GetComponentsInChildren(); + ToggleShop(); + + // Set the icon to not be a raycast target for the Description Hovering to work + foreach(ItemShopSlot slot in _itemSlots) { + slot.image.raycastTarget = false; + } + + foreach(AnimalShopSlot slot in _animalSlots) { + slot.image.raycastTarget = false; + } + + UpdateUI(); + } + + private void Update() { + // When "Shop" button is pressed turn on/off Shop UI + if(Input.GetButtonDown("Shop")) { + ToggleShop(); + } + } + + /** + * Turn on/off the Shop UI + */ + private void ToggleShop() { + inventoryUI.gameObject.SetActive(!shopUI.activeSelf); + HoverManager.instance.HideDescription(); + shopUI.SetActive(!shopUI.activeSelf); + } + + /** + * Is called when something in the Shop UI should update + */ + private void UpdateUI() { + // Add all items to the correct slots and clear the ones where no item should be + for(int i = 0; i < _itemSlots.Length; i++) { + // Item Slots + if(i < _itemShop.Elements.Count) { + _itemSlots[i].AddElement(_itemShop.Elements.ElementAt(i).Key); + _itemSlots[i].nameText.text = _itemSlots[i].Element.displayName; + _itemSlots[i].costText.text = _itemSlots[i].Element.price + " µ"; + _itemSlots[i].amountText.text = _itemShop.Elements[_itemShop.Elements.ElementAt(i).Key] + " #"; + } else { + _itemSlots[i].ClearSlot(); + } + + // Animal SLots + if(i < _animalShop.Elements.Count) { + _animalSlots[i].AddElement(_animalShop.Elements.ElementAt(i).Key); + _animalSlots[i].nameText.text = _animalSlots[i].Element.displayName; + _animalSlots[i].costText.text = _animalSlots[i].Element.price + " µ"; + _animalSlots[i].amountText.text = + _animalShop.Elements[_animalShop.Elements.ElementAt(i).Key] + " #"; + } else { + _animalSlots[i].ClearSlot(); + } + } + } + } +} \ No newline at end of file diff --git a/Assets/Scripts/ShopUI.cs.meta b/Assets/Scripts/Shop/ShopUI.cs.meta similarity index 100% rename from Assets/Scripts/ShopUI.cs.meta rename to Assets/Scripts/Shop/ShopUI.cs.meta diff --git a/Assets/Scripts/ShopSlot.cs b/Assets/Scripts/ShopSlot.cs deleted file mode 100644 index 14564ef..0000000 --- a/Assets/Scripts/ShopSlot.cs +++ /dev/null @@ -1,50 +0,0 @@ -using TMPro; -using UnityEngine; - -public class ShopSlot : ElementStorageSlot { - public TextMeshProUGUI nameText; - public TextMeshProUGUI costText; - - private Shop _shop; - private Inventory _inventory; - private PlayerController _playerController; - - private void Start() { - _shop = Shop.instance; - _inventory = Inventory.instance; - _playerController = PlayerController.instance; - } - - /** - * Clears the Shop Slot - */ - public override void ClearSlot() { - nameText.text = ""; - costText.text = ""; - amountText.text = ""; - base.ClearSlot(); - } - - /** - * Gets called when the Shop Slot is clicked - */ - public override void UseElement() { - if(Element) { - if(_playerController.Money >= Element.price) { - if(Element) { - _playerController.ChangeMoney(-Element.price); - _shop.itemWasBought = true; - - Debug.Log("Buying Item: " + Element.displayName); - } - _inventory.AddElement(Element, 1); - _shop.RemoveElement(Element, 1); - } else { - Debug.Log("Not enough money to buy item."); - } - - _shop.onElementChangedCallback?.Invoke(); - _inventory.onElementChangedCallback?.Invoke(); - } - } -} diff --git a/Assets/Scripts/ShopSwitcher.cs b/Assets/Scripts/ShopSwitcher.cs deleted file mode 100644 index eeb059e..0000000 --- a/Assets/Scripts/ShopSwitcher.cs +++ /dev/null @@ -1,13 +0,0 @@ -using UnityEngine; - -public class ShopSwitcher : MonoBehaviour { - public Sprite animalShopSprite; - public Sprite itemShopSprite; - - public void SwitchShops() { - // switch text in Shop Title - // switch image on switch Button - // turn off one content and turn on the other - // remove undo purchase button when switching to an animal shop - } -} diff --git a/Assets/Scripts/ShopUI.cs b/Assets/Scripts/ShopUI.cs deleted file mode 100644 index 0bc2184..0000000 --- a/Assets/Scripts/ShopUI.cs +++ /dev/null @@ -1,60 +0,0 @@ -using System.Linq; -using UnityEngine; - -public class ShopUI : MonoBehaviour { - public Transform itemsParent; - public GameObject shopUI; - public GameObject inventoryUI; - - private Shop _shop; - private ShopSlot[] _slots; - - private void Start() { - // Get Shop instance and add UpdateUI method to OnItemChanged delegate - _shop = Shop.instance; - _shop.onElementChangedCallback += UpdateUI; - - // Add all ShopSlot GameObjects to _slots and turn off the Shop UI - _slots = itemsParent.GetComponentsInChildren(); - ToggleShop(); - - // Set the icon to not be a raycast target for the Description Hovering to work - foreach (ShopSlot slot in _slots) { - slot.icon.raycastTarget = false; - } - } - - private void Update() { - // When "Shop" button is pressed turn on/off Shop UI - if (Input.GetButtonDown("Shop")) { - ToggleShop(); - } - } - - /** - * Turn on/off the Shop UI - */ - private void ToggleShop() { - inventoryUI.gameObject.SetActive(!shopUI.activeSelf); - HoverManager.instance.HideDescription(); - shopUI.SetActive(!shopUI.activeSelf); - } - - /** - * Is called when something in the Shop UI should update - */ - private void UpdateUI() { - // Add all items to the correct slots and clear the ones where no item should be - for (int i = 0; i < _slots.Length; i++) { - if (i < _shop.Elements.Count) { - _slots[i].AddElement(_shop.Elements.ElementAt(i).Key); - _slots[i].nameText.text = _slots[i].Element.displayName; - _slots[i].costText.text = _slots[i].Element.price + " µ"; - _slots[i].amountText.text = _shop.Elements[_shop.Elements.ElementAt(i).Key] + " #"; - } - else { - _slots[i].ClearSlot(); - } - } - } -} \ No newline at end of file diff --git a/Packages/packages-lock.json b/Packages/packages-lock.json index 4f0557e..40769bb 100644 --- a/Packages/packages-lock.json +++ b/Packages/packages-lock.json @@ -137,12 +137,21 @@ "dependencies": {}, "url": "https://packages.unity.com" }, + "com.unity.nuget.newtonsoft-json": { + "version": "3.0.2", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://packages.unity.com" + }, "com.unity.services.core": { - "version": "1.0.1", + "version": "1.3.1", "depth": 1, "source": "registry", "dependencies": { - "com.unity.modules.unitywebrequest": "1.0.0" + "com.unity.modules.unitywebrequest": "1.0.0", + "com.unity.nuget.newtonsoft-json": "3.0.2", + "com.unity.modules.androidjni": "1.0.0" }, "url": "https://packages.unity.com" },