├── .editorconfig ├── .github └── workflows │ ├── commitlint.yml │ ├── nightly-build.yml │ └── workflow.yml ├── .gitignore ├── .husky └── commit-msg ├── .nvmrc ├── .oyster.json ├── .releaserc ├── .vsconfig ├── Assets ├── Examples.meta ├── Examples │ ├── CustomEntryTest.meta │ ├── CustomEntryTest │ │ ├── CustomEntrySaveLoadTest.cs │ │ ├── CustomEntrySaveLoadTest.cs.meta │ │ ├── CustomEntryTest.unity │ │ └── CustomEntryTest.unity.meta │ ├── GettingsStarted.meta │ ├── GettingsStarted │ │ ├── ExamplePlayerInventory.cs │ │ ├── ExamplePlayerInventory.cs.meta │ │ ├── GettingStarted.unity │ │ └── GettingStarted.unity.meta │ ├── Resources.meta │ ├── Resources │ │ ├── ItemDatabase.asset │ │ └── ItemDatabase.asset.meta │ ├── Shop.meta │ └── Shop │ │ ├── Definitions.meta │ │ ├── Definitions │ │ ├── AncientGem.asset │ │ ├── AncientGem.asset.meta │ │ ├── CarnFlower.asset │ │ ├── CarnFlower.asset.meta │ │ ├── CustomItem.asset │ │ ├── CustomItem.asset.meta │ │ ├── FlamingSword.asset │ │ ├── FlamingSword.asset.meta │ │ ├── GiantAxe.asset │ │ ├── GiantAxe.asset.meta │ │ ├── Gold.asset │ │ ├── Gold.asset.meta │ │ ├── HealthPotionMedium.asset │ │ ├── HealthPotionMedium.asset.meta │ │ ├── HealthPotionSmall.asset │ │ ├── HealthPotionSmall.asset.meta │ │ ├── HealthPotionSmallRecipe.asset │ │ ├── HealthPotionSmallRecipe.asset.meta │ │ ├── Leather.asset │ │ ├── Leather.asset.meta │ │ ├── Longsword.asset │ │ ├── Longsword.asset.meta │ │ ├── LongswordRecipe.asset │ │ ├── LongswordRecipe.asset.meta │ │ ├── Metal.asset │ │ ├── Metal.asset.meta │ │ ├── MineKey.asset │ │ └── MineKey.asset.meta │ │ ├── Images.meta │ │ ├── Images │ │ ├── README.md │ │ ├── README.md.meta │ │ ├── animal-hide.png │ │ ├── animal-hide.png.meta │ │ ├── battle-axe.png │ │ ├── battle-axe.png.meta │ │ ├── cancel.png │ │ ├── cancel.png.meta │ │ ├── crossed-swords.png │ │ ├── crossed-swords.png.meta │ │ ├── direction-sign.png │ │ ├── direction-sign.png.meta │ │ ├── fire-gem.png │ │ ├── fire-gem.png.meta │ │ ├── fizzing-flask.png │ │ ├── fizzing-flask.png.meta │ │ ├── flower-emblem.png │ │ ├── flower-emblem.png.meta │ │ ├── gladius.png │ │ ├── gladius.png.meta │ │ ├── key.png │ │ ├── key.png.meta │ │ ├── light-backpack.png │ │ ├── light-backpack.png.meta │ │ ├── metal-bar.png │ │ ├── metal-bar.png.meta │ │ ├── notebook.png │ │ ├── notebook.png.meta │ │ ├── round-potion.png │ │ ├── round-potion.png.meta │ │ ├── saber-slash.png │ │ ├── saber-slash.png.meta │ │ ├── scroll-unfurled.png │ │ ├── scroll-unfurled.png.meta │ │ ├── swap-bag.png │ │ ├── swap-bag.png.meta │ │ ├── two-coins.png │ │ └── two-coins.png.meta │ │ ├── Prefabs.meta │ │ ├── Prefabs │ │ ├── ItemSlot.prefab │ │ └── ItemSlot.prefab.meta │ │ ├── Scripts.meta │ │ ├── Scripts │ │ ├── Definitions.meta │ │ ├── Definitions │ │ │ ├── HealthPotion.cs │ │ │ ├── HealthPotion.cs.meta │ │ │ ├── ItemDefinition.cs │ │ │ ├── ItemDefinition.cs.meta │ │ │ ├── ItemDefinitionCustomDisplayName.cs │ │ │ ├── ItemDefinitionCustomDisplayName.cs.meta │ │ │ ├── ItemDefinitionFantasyBase.cs │ │ │ ├── ItemDefinitionFantasyBase.cs.meta │ │ │ ├── Recipes.cs │ │ │ ├── Recipes.cs.meta │ │ │ ├── WeaponDefinition.meta │ │ │ └── WeaponDefinition │ │ │ │ ├── ItemDefinitionWeapon.cs │ │ │ │ ├── ItemDefinitionWeapon.cs.meta │ │ │ │ ├── ItemEntryDataResolverWeapon.cs │ │ │ │ ├── ItemEntryDataResolverWeapon.cs.meta │ │ │ │ ├── ItemEntryWeapon.cs │ │ │ │ └── ItemEntryWeapon.cs.meta │ │ ├── InventorySaveHelper.cs │ │ ├── InventorySaveHelper.cs.meta │ │ ├── Menus.meta │ │ └── Menus │ │ │ ├── InventoryPrinter.meta │ │ │ ├── InventoryPrinter │ │ │ ├── InventoryPrinter.cs │ │ │ ├── InventoryPrinter.cs.meta │ │ │ ├── ItemCategoryButton.cs │ │ │ ├── ItemCategoryButton.cs.meta │ │ │ ├── ItemContextPrinter.cs │ │ │ ├── ItemContextPrinter.cs.meta │ │ │ ├── ItemPrinter.cs │ │ │ ├── ItemPrinter.cs.meta │ │ │ ├── PrintItemQuantity.cs │ │ │ └── PrintItemQuantity.cs.meta │ │ │ ├── MenuNavigator.cs │ │ │ └── MenuNavigator.cs.meta │ │ ├── Shop.unity │ │ └── Shop.unity.meta ├── HealthPotionLarge.asset ├── HealthPotionLarge.asset.meta ├── TextMesh Pro.meta ├── TextMesh Pro │ ├── Documentation.meta │ ├── Documentation │ │ ├── TextMesh Pro User Guide 2016.pdf │ │ └── TextMesh Pro User Guide 2016.pdf.meta │ ├── Fonts.meta │ ├── Fonts │ │ ├── LiberationSans - OFL.txt │ │ ├── LiberationSans - OFL.txt.meta │ │ ├── LiberationSans.ttf │ │ └── LiberationSans.ttf.meta │ ├── Resources.meta │ ├── Resources │ │ ├── Fonts & Materials.meta │ │ ├── Fonts & Materials │ │ │ ├── LiberationSans SDF - Drop Shadow.mat │ │ │ ├── LiberationSans SDF - Drop Shadow.mat.meta │ │ │ ├── LiberationSans SDF - Fallback.asset │ │ │ ├── LiberationSans SDF - Fallback.asset.meta │ │ │ ├── LiberationSans SDF - Outline.mat │ │ │ ├── LiberationSans SDF - Outline.mat.meta │ │ │ ├── LiberationSans SDF.asset │ │ │ └── LiberationSans SDF.asset.meta │ │ ├── LineBreaking Following Characters.txt │ │ ├── LineBreaking Following Characters.txt.meta │ │ ├── LineBreaking Leading Characters.txt │ │ ├── LineBreaking Leading Characters.txt.meta │ │ ├── Sprite Assets.meta │ │ ├── Sprite Assets │ │ │ ├── EmojiOne.asset │ │ │ └── EmojiOne.asset.meta │ │ ├── Style Sheets.meta │ │ ├── Style Sheets │ │ │ ├── Default Style Sheet.asset │ │ │ └── Default Style Sheet.asset.meta │ │ ├── TMP Settings.asset │ │ └── TMP Settings.asset.meta │ ├── Shaders.meta │ ├── Shaders │ │ ├── SDFFunctions.hlsl │ │ ├── SDFFunctions.hlsl.meta │ │ ├── TMP_Bitmap-Custom-Atlas.shader │ │ ├── TMP_Bitmap-Custom-Atlas.shader.meta │ │ ├── TMP_Bitmap-Mobile.shader │ │ ├── TMP_Bitmap-Mobile.shader.meta │ │ ├── TMP_Bitmap.shader │ │ ├── TMP_Bitmap.shader.meta │ │ ├── TMP_SDF Overlay.shader │ │ ├── TMP_SDF Overlay.shader.meta │ │ ├── TMP_SDF SSD.shader │ │ ├── TMP_SDF SSD.shader.meta │ │ ├── TMP_SDF-HDRP LIT.shadergraph │ │ ├── TMP_SDF-HDRP LIT.shadergraph.meta │ │ ├── TMP_SDF-HDRP UNLIT.shadergraph │ │ ├── TMP_SDF-HDRP UNLIT.shadergraph.meta │ │ ├── TMP_SDF-Mobile Masking.shader │ │ ├── TMP_SDF-Mobile Masking.shader.meta │ │ ├── TMP_SDF-Mobile Overlay.shader │ │ ├── TMP_SDF-Mobile Overlay.shader.meta │ │ ├── TMP_SDF-Mobile SSD.shader │ │ ├── TMP_SDF-Mobile SSD.shader.meta │ │ ├── TMP_SDF-Mobile-2-Pass.shader │ │ ├── TMP_SDF-Mobile-2-Pass.shader.meta │ │ ├── TMP_SDF-Mobile.shader │ │ ├── TMP_SDF-Mobile.shader.meta │ │ ├── TMP_SDF-Surface-Mobile.shader │ │ ├── TMP_SDF-Surface-Mobile.shader.meta │ │ ├── TMP_SDF-Surface.shader │ │ ├── TMP_SDF-Surface.shader.meta │ │ ├── TMP_SDF-URP Lit.shadergraph │ │ ├── TMP_SDF-URP Lit.shadergraph.meta │ │ ├── TMP_SDF-URP Unlit.shadergraph │ │ ├── TMP_SDF-URP Unlit.shadergraph.meta │ │ ├── TMP_SDF.shader │ │ ├── TMP_SDF.shader.meta │ │ ├── TMP_Sprite.shader │ │ ├── TMP_Sprite.shader.meta │ │ ├── TMPro.cginc │ │ ├── TMPro.cginc.meta │ │ ├── TMPro_Mobile.cginc │ │ ├── TMPro_Mobile.cginc.meta │ │ ├── TMPro_Properties.cginc │ │ ├── TMPro_Properties.cginc.meta │ │ ├── TMPro_Surface.cginc │ │ └── TMPro_Surface.cginc.meta │ ├── Sprites.meta │ └── Sprites │ │ ├── EmojiOne Attribution.txt │ │ ├── EmojiOne Attribution.txt.meta │ │ ├── EmojiOne.json │ │ ├── EmojiOne.json.meta │ │ ├── EmojiOne.png │ │ └── EmojiOne.png.meta ├── com.fluid.elastic-inventory.meta └── com.fluid.elastic-inventory │ ├── CHANGELOG.md │ ├── CHANGELOG.md.meta │ ├── Documentation~ │ └── com.fluid.elastic-inventory.md │ ├── Editor.meta │ ├── Editor │ ├── Components.meta │ ├── Components │ │ ├── Atoms.meta │ │ ├── Atoms │ │ │ ├── DropdownAdd.cs │ │ │ └── DropdownAdd.cs.meta │ │ ├── Molecules.meta │ │ ├── Molecules │ │ │ ├── SearchInput.meta │ │ │ └── SearchInput │ │ │ │ ├── SearchInput.cs │ │ │ │ ├── SearchInput.cs.meta │ │ │ │ ├── SearchInput.uxml │ │ │ │ └── SearchInput.uxml.meta │ │ ├── Organisms.meta │ │ ├── Organisms │ │ │ ├── ItemEntry.meta │ │ │ └── ItemEntry │ │ │ │ ├── ItemEntry.cs │ │ │ │ ├── ItemEntry.cs.meta │ │ │ │ ├── ItemEntry.uss │ │ │ │ ├── ItemEntry.uss.meta │ │ │ │ ├── ItemEntry.uxml │ │ │ │ └── ItemEntry.uxml.meta │ │ ├── Pages.meta │ │ └── Pages │ │ │ ├── PageItemDatabase.cs │ │ │ ├── PageItemDatabase.cs.meta │ │ │ ├── PageItemDatabase.uss │ │ │ ├── PageItemDatabase.uss.meta │ │ │ ├── PageItemDatabase.uxml │ │ │ └── PageItemDatabase.uxml.meta │ ├── Scripts.meta │ ├── Scripts │ │ ├── ConfigWizard.cs │ │ ├── ConfigWizard.cs.meta │ │ ├── InventoryCategoryDrawer.cs │ │ ├── InventoryCategoryDrawer.cs.meta │ │ ├── InventoryHelperEditor.cs │ │ ├── InventoryHelperEditor.cs.meta │ │ ├── ItemDatabase.meta │ │ └── ItemDatabase │ │ │ ├── ItemDatabaseEditor.cs │ │ │ ├── ItemDatabaseEditor.cs.meta │ │ │ ├── ItemDatabaseWindow.cs │ │ │ └── ItemDatabaseWindow.cs.meta │ ├── TinFoil.meta │ ├── TinFoil │ │ ├── AssetPath.cs │ │ ├── AssetPath.cs.meta │ │ ├── ComponentBase.cs │ │ ├── ComponentBase.cs.meta │ │ ├── README.md │ │ ├── README.md.meta │ │ ├── UxmlConfig.cs │ │ └── UxmlConfig.cs.meta │ ├── com.fluid.elastic-inventory.Editor.asmdef │ └── com.fluid.elastic-inventory.Editor.asmdef.meta │ ├── LICENSE.md │ ├── LICENSE.md.meta │ ├── README.md │ ├── README.md.meta │ ├── Runtime.meta │ ├── Runtime │ ├── Attributes.meta │ ├── Attributes │ │ ├── InventoryCategory.cs │ │ ├── InventoryCategory.cs.meta │ │ ├── ItemDefinitionDetailsAttribute.cs │ │ └── ItemDefinitionDetailsAttribute.cs.meta │ ├── Databases.meta │ ├── Databases │ │ ├── IItemDatabase.cs │ │ ├── IItemDatabase.cs.meta │ │ ├── ItemDatabase.cs │ │ ├── ItemDatabase.cs.meta │ │ ├── ItemDatabaseSaveData.cs │ │ └── ItemDatabaseSaveData.cs.meta │ ├── Inventory.meta │ ├── Inventory │ │ ├── IInventoryInstance.cs │ │ ├── IInventoryInstance.cs.meta │ │ ├── InventoryEvents.cs │ │ ├── InventoryEvents.cs.meta │ │ ├── InventoryHelper.cs │ │ ├── InventoryHelper.cs.meta │ │ ├── InventoryInstance.cs │ │ ├── InventoryInstance.cs.meta │ │ ├── InventoryInstanceSorting.cs │ │ ├── InventoryInstanceSorting.cs.meta │ │ ├── InventorySaveData.cs │ │ └── InventorySaveData.cs.meta │ ├── Items.meta │ ├── Items │ │ ├── Entries.meta │ │ ├── Entries │ │ │ ├── IItemEntry.cs │ │ │ ├── IItemEntry.cs.meta │ │ │ ├── ItemEntry.cs │ │ │ ├── ItemEntry.cs.meta │ │ │ ├── ItemEntryBase.cs │ │ │ ├── ItemEntryBase.cs.meta │ │ │ ├── ItemEntryData.cs │ │ │ ├── ItemEntryData.cs.meta │ │ │ ├── ItemEntryDataResolver.cs │ │ │ ├── ItemEntryDataResolver.cs.meta │ │ │ ├── ItemEntryDataResolverBase.cs │ │ │ └── ItemEntryDataResolverBase.cs.meta │ │ ├── IItemDefinition.cs │ │ ├── IItemDefinition.cs.meta │ │ ├── ItemDefinitionBase.cs │ │ └── ItemDefinitionBase.cs.meta │ ├── com.fluid.elastic-inventory.asmdef │ └── com.fluid.elastic-inventory.asmdef.meta │ ├── Tests.meta │ ├── Tests │ ├── Editor.meta │ └── Editor │ │ ├── Scripts.meta │ │ ├── Scripts │ │ ├── InventoryHelperTest.cs │ │ ├── InventoryHelperTest.cs.meta │ │ ├── InventoryInstanceTest.cs │ │ ├── InventoryInstanceTest.cs.meta │ │ ├── ItemDatabaseTest.cs │ │ └── ItemDatabaseTest.cs.meta │ │ ├── Utilities.meta │ │ ├── Utilities │ │ ├── Builders.meta │ │ └── Builders │ │ │ ├── A.cs │ │ │ ├── A.cs.meta │ │ │ ├── ItemDatabaseBuilder.cs │ │ │ ├── ItemDatabaseBuilder.cs.meta │ │ │ ├── ItemDefinitionBuilder.cs │ │ │ ├── ItemDefinitionBuilder.cs.meta │ │ │ ├── ItemEntryBuilder.cs │ │ │ ├── ItemEntryBuilder.cs.meta │ │ │ ├── ItemEntryReadOnlyBuilder.cs │ │ │ └── ItemEntryReadOnlyBuilder.cs.meta │ │ ├── com.fluid.elastic-inventory.Editor.Tests.asmdef │ │ └── com.fluid.elastic-inventory.Editor.Tests.asmdef.meta │ ├── package.json │ └── package.json.meta ├── CONTRIBUTING.md ├── LICENSE.md ├── Packages ├── manifest.json └── packages-lock.json ├── ProjectSettings ├── AudioManager.asset ├── ClusterInputManager.asset ├── DynamicsManager.asset ├── EditorBuildSettings.asset ├── EditorSettings.asset ├── GraphicsSettings.asset ├── InputManager.asset ├── MemorySettings.asset ├── MultiplayerManager.asset ├── NavMeshAreas.asset ├── PackageManagerSettings.asset ├── Packages │ └── com.unity.testtools.codecoverage │ │ └── Settings.json ├── Physics2DSettings.asset ├── PresetManager.asset ├── ProjectSettings.asset ├── ProjectVersion.txt ├── QualitySettings.asset ├── SceneTemplateSettings.json ├── TagManager.asset ├── TimeManager.asset ├── TimelineSettings.asset ├── UnityConnectSettings.asset ├── VFXManager.asset ├── VersionControlSettings.asset └── XRSettings.asset ├── README.md ├── build.js ├── commitlint.config.js ├── editable-item-entry-proposal.md ├── images ├── example-store.png ├── gold.png ├── inventory-final.png ├── inventory-helper.png ├── item-example.png └── preview.png ├── omnisharp.json ├── package-lock.json ├── package.json └── publish-nightly.sh /.editorconfig: -------------------------------------------------------------------------------- 1 | # Editor configuration, see http://editorconfig.org 2 | root = true 3 | 4 | [*] 5 | charset = utf-8 6 | indent_style = space 7 | indent_size = 4 8 | insert_final_newline = true 9 | trim_trailing_whitespace = true 10 | 11 | [*.md] 12 | max_line_length = off 13 | trim_trailing_whitespace = false 14 | 15 | [manifest.json] 16 | indent_size = 2 17 | -------------------------------------------------------------------------------- /.github/workflows/commitlint.yml: -------------------------------------------------------------------------------- 1 | name: Lint Commit Messages 2 | on: [pull_request] 3 | 4 | jobs: 5 | commitlint: 6 | runs-on: ubuntu-latest 7 | steps: 8 | - uses: actions/checkout@v3 9 | with: 10 | fetch-depth: 0 11 | - uses: wagoid/commitlint-github-action@v5 12 | -------------------------------------------------------------------------------- /.github/workflows/nightly-build.yml: -------------------------------------------------------------------------------- 1 | name: Nightly Build 2 | permissions: 3 | contents: write 4 | on: 5 | push: 6 | branches: 7 | - develop 8 | jobs: 9 | deployNightly: 10 | runs-on: ubuntu-latest 11 | steps: 12 | - uses: actions/checkout@v3 13 | - uses: actions/setup-node@v3 14 | with: 15 | node-version: 16 16 | - run: HUSKY=0 npm ci 17 | - run: npm run build 18 | - name: Deploy nightly branch 19 | run: sh ./publish-nightly.sh 20 | env: 21 | GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} 22 | -------------------------------------------------------------------------------- /.github/workflows/workflow.yml: -------------------------------------------------------------------------------- 1 | name: Release 2 | 3 | on: 4 | push: 5 | branches: 6 | - main 7 | - master 8 | 9 | permissions: 10 | contents: read 11 | 12 | jobs: 13 | release: 14 | name: Release 15 | runs-on: ubuntu-latest 16 | permissions: 17 | contents: write 18 | issues: write 19 | pull-requests: write 20 | id-token: write 21 | steps: 22 | - name: Checkout 23 | uses: actions/checkout@v3 24 | with: 25 | fetch-depth: 0 26 | persist-credentials: false 27 | - name: Setup Node.js 28 | uses: actions/setup-node@v3 29 | with: 30 | node-version: 16 31 | - name: Install dependencies 32 | run: HUSKY=0 npm ci && npm run build 33 | - name: Verify the integrity of provenance attestations and registry signatures for installed dependencies 34 | run: npm audit signatures 35 | - name: Release 36 | env: 37 | GH_TOKEN: ${{ secrets.GH_TOKEN }} 38 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 39 | NPM_TOKEN: ${{ secrets.NPM_TOKEN }} 40 | run: npm run semantic-release -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /[Ll]ibrary/ 2 | /[Tt]emp/ 3 | /[Oo]bj/ 4 | /[Bb]uild/ 5 | /[Bb]uilds/ 6 | /[Ll]ogs/ 7 | /[Uu]ser[Ss]ettings/ 8 | CodeCoverage/ 9 | UIElementsSchema/ 10 | 11 | # MemoryCaptures can get excessive in size. 12 | # They also could contain extremely sensitive data 13 | /[Mm]emoryCaptures/ 14 | 15 | # Recordings can get excessive in size 16 | /[Rr]ecordings/ 17 | 18 | /[Aa]ssets/AssetStoreTools* 19 | 20 | # Autogenerated Jetbrains Rider plugin 21 | /[Aa]ssets/Plugins/Editor/JetBrains* 22 | 23 | # Visual Studio cache directory 24 | .vs/ 25 | 26 | # Gradle cache directory 27 | .gradle/ 28 | 29 | # Autogenerated VS/MD/Consulo solution and project files 30 | ExportedObj/ 31 | .consulo/ 32 | *.csproj 33 | *.unityproj 34 | *.sln 35 | *.suo 36 | *.tmp 37 | *.user 38 | *.userprefs 39 | *.pidb 40 | *.booproj 41 | *.svd 42 | *.pdb 43 | *.mdb 44 | *.opendb 45 | *.VC.db 46 | 47 | # Unity3D generated meta files 48 | *.pidb.meta 49 | *.pdb.meta 50 | *.mdb.meta 51 | 52 | # Unity3D Generated File On Crash Reports 53 | sysinfo.txt 54 | 55 | # Builds 56 | *.apk 57 | *.aab 58 | *.unitypackage 59 | *.app 60 | 61 | # Crashlytics generated file 62 | crashlytics-build.properties 63 | 64 | # Packed Addressables 65 | /[Aa]ssets/[Aa]ddressable[Aa]ssets[Dd]ata/*/*.bin* 66 | 67 | # Temporary auto-generated Android Assets 68 | /[Aa]ssets/[Ss]treamingAssets/aa.meta 69 | /[Aa]ssets/[Ss]treamingAssets/aa/* 70 | 71 | # Node.js 72 | node_modules 73 | dist 74 | dist.zip 75 | -------------------------------------------------------------------------------- /.husky/commit-msg: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env sh 2 | . "$(dirname -- "$0")/_/husky.sh" 3 | 4 | npx --no -- commitlint --edit ${1} 5 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | 16.17.0 2 | -------------------------------------------------------------------------------- /.oyster.json: -------------------------------------------------------------------------------- 1 | { 2 | "description": "A simple inventory micro-framework built with extendability in mind", 3 | "displayName": "Elastic Inventory", 4 | "keywords": [ 5 | "unity3d", 6 | "unity package", 7 | "upm", 8 | "inventory", 9 | "inventory management" 10 | ], 11 | "oysterVersion": "3.0.2", 12 | "packageName": "com.fluid.elastic-inventory", 13 | "packageScope": "com.fluid", 14 | "unityVersion": "2022.2", 15 | "author": { 16 | "name": "Ash Blue", 17 | "email": "ash@clevercrowgames.com", 18 | "url": "https://blueashes.com" 19 | }, 20 | "repo": { 21 | "gitUrl": "https://github.com/ashblue/unity-elastic-inventory", 22 | "gitUrlNoHttp": "github.com/ashblue/unity-elastic-inventory" 23 | } 24 | } -------------------------------------------------------------------------------- /.releaserc: -------------------------------------------------------------------------------- 1 | { 2 | "branches": ["master", "main"], 3 | "plugins": [ 4 | "@semantic-release/commit-analyzer", 5 | "@semantic-release/release-notes-generator", 6 | "@semantic-release/changelog", 7 | [ 8 | "@semantic-release/npm", 9 | { 10 | "npmPublish": false 11 | } 12 | ], 13 | [ 14 | "@semantic-release/exec", 15 | { 16 | "publishCmd": "npm run build" 17 | } 18 | ], 19 | [ 20 | "@semantic-release/npm", 21 | { 22 | "pkgRoot": "Assets/com.fluid.elastic-inventory" 23 | } 24 | ], 25 | [ 26 | "@semantic-release/git", 27 | { 28 | "assets": [ 29 | "CHANGELOG.md", 30 | "package.json", 31 | "package-lock.json", 32 | "npm-shrinkwrap.json", 33 | "Assets/**/*" 34 | ] 35 | } 36 | ], 37 | "@semantic-release/github" 38 | ] 39 | } 40 | -------------------------------------------------------------------------------- /.vsconfig: -------------------------------------------------------------------------------- 1 | { 2 | "version": "1.0", 3 | "components": [ 4 | "Microsoft.VisualStudio.Workload.ManagedGame" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /Assets/Examples.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 71a4bd24df7c342b8986202cf10c3c5d 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/CustomEntryTest.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0a941064e5584f3a87f0cf722e992410 3 | timeCreated: 1688588950 -------------------------------------------------------------------------------- /Assets/Examples/CustomEntryTest/CustomEntrySaveLoadTest.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | using UnityEngine; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | public class CustomEntrySaveLoadTest : MonoBehaviour { 6 | public InventoryHelper inventory; 7 | public ItemDefinitionWeapon weapon; 8 | public int changeDurability = 22; 9 | 10 | private void Start () { 11 | // Create the item and modify the durability 12 | var entry = inventory.Instance.Add(weapon) as ItemEntryWeapon; 13 | Debug.Log("New item durability: " + entry.Durability); 14 | 15 | entry.Durability = changeDurability; 16 | Debug.Log("Changed item durability: " + entry.Durability); 17 | 18 | // Load the item from save data 19 | var save = inventory.Instance.Save(); 20 | var newInventory = new InventoryInstance(ItemDatabase.Current); 21 | newInventory.Load(save); 22 | 23 | // Print the durability of the loaded item 24 | var restoredItem = newInventory.GetEntry(entry.Id) as ItemEntryWeapon; 25 | Debug.Log("Restored item durability: " + restoredItem.Durability); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Assets/Examples/CustomEntryTest/CustomEntrySaveLoadTest.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 925bd843ae1944f9bbcc72d436e6ced0 3 | timeCreated: 1688588966 -------------------------------------------------------------------------------- /Assets/Examples/CustomEntryTest/CustomEntryTest.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0b4a477f700283748ab91a4d5a84413a 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Examples/GettingsStarted.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7b03b9a579bf9ee4a9d6fc3f129bd019 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/GettingsStarted/ExamplePlayerInventory.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using CleverCrow.Fluid.ElasticInventory; 3 | using UnityEngine; 4 | 5 | namespace CleverCrow.Fluid.Examples { 6 | public class ExamplePlayerInventory : MonoBehaviour { 7 | public InventoryHelper inventory; 8 | public List itemsToBuy; 9 | 10 | void Start () { 11 | foreach (var item in itemsToBuy) { 12 | inventory.Instance.Remove("gold", item.Cost); 13 | inventory.Instance.Add(item); 14 | } 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Assets/Examples/GettingsStarted/ExamplePlayerInventory.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 242b5dff00034f75bbb125bf2110ca1f 3 | timeCreated: 1688503211 -------------------------------------------------------------------------------- /Assets/Examples/GettingsStarted/GettingStarted.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 83035390ef752094985cc46ae97256e1 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Examples/Resources.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 160414ce0aa262f42b711e8b8770f660 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Resources/ItemDatabase.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: a600bc502ed14cf5980ca274873f182a, type: 3} 13 | m_Name: ItemDatabase 14 | m_EditorClassIdentifier: 15 | _autoLoad: 1 16 | _definitions: 17 | - {fileID: 11400000, guid: 80d3b6ab2a78e6b418da8aed88e32926, type: 2} 18 | - {fileID: 11400000, guid: d3988ba3f8a2c44e6a1b98201ce75ee2, type: 2} 19 | - {fileID: 11400000, guid: 4e2438a1b36c043e587e88575d07b5ff, type: 2} 20 | - {fileID: 11400000, guid: 5e7593ddbeb614a3984bd7fcc9251406, type: 2} 21 | - {fileID: 11400000, guid: af5f8c4cbc9ca47399a535ac79bca821, type: 2} 22 | - {fileID: 11400000, guid: 253e7bd4ad4eb4c3ea08b7125e4e7372, type: 2} 23 | - {fileID: 11400000, guid: 8bf3e6d26a2462f4ab078b47e1925c4f, type: 2} 24 | - {fileID: 11400000, guid: a4f24e396c14b4438bdac660cb3768e8, type: 2} 25 | - {fileID: 11400000, guid: ab590e04be0294a76b81e859c4263afb, type: 2} 26 | - {fileID: 11400000, guid: f0a0b304827894feb81ecf23309eab1c, type: 2} 27 | - {fileID: 11400000, guid: e7bbdeb0bc0ba42d191d18e2ea1fc743, type: 2} 28 | - {fileID: 11400000, guid: 06eaa045c74964ba182ff9156b55f42e, type: 2} 29 | - {fileID: 11400000, guid: ed8218179ad2a4cff97be93b37f2445b, type: 2} 30 | - {fileID: 11400000, guid: dec899d6e9c7a44e6bdfc1ab1b33cfd6, type: 2} 31 | - {fileID: 11400000, guid: 9f77921cfc0df4d3996ebcabcf7b4f4c, type: 2} 32 | _categories: 33 | - Default 34 | - Important 35 | - Weapon 36 | - Hide 37 | - Potion 38 | - Recipe 39 | -------------------------------------------------------------------------------- /Assets/Examples/Resources/ItemDatabase.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8dc0d664e66f1044cb750c45aa116b68 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 41044116c50ccd2498814b8a92724d60 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: cdef615ab0f4c26468039f3b700bd6ff 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/AncientGem.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: c7eda25e41964b24fb6b9fb1353e5966, type: 3} 13 | m_Name: AncientGem 14 | m_EditorClassIdentifier: 15 | _id: c5d02424-8615-466c-b0ad-890cd7ad1461 16 | _displayName: Ancient Gem 17 | _image: {fileID: 21300000, guid: cb17d85174959467c808508d0f3c5fa8, type: 3} 18 | _cost: 10 19 | _description: The Seraph's Tear, an ancient gem of incomparable beauty and mystique, 20 | has long been the subject of myth and legend. 21 | _category: 1 22 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/AncientGem.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a4f24e396c14b4438bdac660cb3768e8 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/CarnFlower.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: c7eda25e41964b24fb6b9fb1353e5966, type: 3} 13 | m_Name: CarnFlower 14 | m_EditorClassIdentifier: 15 | _id: 434528fd-3fa1-4779-988e-378dcbe9063d 16 | _displayName: Carn Flower 17 | _image: {fileID: 21300000, guid: 2df317ecb508a4281a5a6e644e936523, type: 3} 18 | _cost: 3 19 | _description: The Carn Flower, a fantastical flower that grows in the heart of 20 | the Eldwood Forest, is renowned in all mythical realms for its extraordinary 21 | healing properties. 22 | _category: 0 23 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/CarnFlower.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d3988ba3f8a2c44e6a1b98201ce75ee2 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/CustomItem.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: e149b91f3de145dc9820a3c795b7b05a, type: 3} 13 | m_Name: CustomItem 14 | m_EditorClassIdentifier: 15 | _id: fe563339-c771-4245-9db6-3b38dccf7426 16 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/CustomItem.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 80d3b6ab2a78e6b418da8aed88e32926 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/FlamingSword.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 9fc961584b0948c5a3ccc032573e690b, type: 3} 13 | m_Name: FlamingSword 14 | m_EditorClassIdentifier: 15 | _id: 058532a9-5f3a-4d92-aabe-ac8d81d3e73b 16 | _displayName: Flaming Sword 17 | _image: {fileID: 21300000, guid: 3dadd2f09bccc4174a60fb52d2dcecda, type: 3} 18 | _cost: 20 19 | _description: The Pyroblade, forged from Stariron, is an iconic flaming sword. 20 | Its fiery aura releases searing heat with each strike, reducing foes to ash. 21 | A symbol of bravery, it exemplifies the warrior's indomitable spirit. 22 | _damage: 10 23 | _energyCost: 3 24 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/FlamingSword.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ed8218179ad2a4cff97be93b37f2445b 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/GiantAxe.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 9fc961584b0948c5a3ccc032573e690b, type: 3} 13 | m_Name: GiantAxe 14 | m_EditorClassIdentifier: 15 | _id: 15f3f2c4-c498-479d-876f-a260878a92f3 16 | _displayName: Giant Axe 17 | _image: {fileID: 21300000, guid: a92cca722b46e4ac39fdd45da042c124, type: 3} 18 | _cost: 10 19 | _description: The Titan's Cleaver, a colossal axe, is forged from mountain steel 20 | and ancient oak. Its tremendous blade delivers thunderous swings, decimating 21 | foes with unmatched force. It stands as a symbol of the giants' formidable strength 22 | and resolve. 23 | _damage: 5 24 | _energyCost: 10 25 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/GiantAxe.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: dec899d6e9c7a44e6bdfc1ab1b33cfd6 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Gold.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: c7eda25e41964b24fb6b9fb1353e5966, type: 3} 13 | m_Name: Gold 14 | m_EditorClassIdentifier: 15 | _id: gold 16 | _displayName: Gold 17 | _image: {fileID: 0} 18 | _cost: 0 19 | _description: 20 | _category: 3 21 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Gold.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 06eaa045c74964ba182ff9156b55f42e 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/HealthPotionMedium.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: e164270660ca4f598a280953ed1ab81f, type: 3} 13 | m_Name: HealthPotionMedium 14 | m_EditorClassIdentifier: 15 | _id: c24fb398-ba07-4168-86d5-675200f56e30 16 | _displayName: Health Potion Medium 17 | _image: {fileID: 21300000, guid: 9f05c8edbc90440d8a7ca99fb9673ae7, type: 3} 18 | _cost: 20 19 | _description: The Healing Potion of Halcyon is the stuff of legends, whispered 20 | among the ancient circles of magical healers. Its liquid glows with a radiant 21 | luminescence, reflecting a mesmerizing blend of soothing hues.. 22 | _healAmount: 30 23 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/HealthPotionMedium.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 253e7bd4ad4eb4c3ea08b7125e4e7372 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/HealthPotionSmall.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: e164270660ca4f598a280953ed1ab81f, type: 3} 13 | m_Name: HealthPotionSmall 14 | m_EditorClassIdentifier: 15 | _id: bd6b1a10-222e-4435-9ca6-11c4aaf22638 16 | _displayName: Health Potion Small 17 | _image: {fileID: 21300000, guid: 9f05c8edbc90440d8a7ca99fb9673ae7, type: 3} 18 | _cost: 10 19 | _description: The Healing Potion of Halcyon is the stuff of legends, whispered 20 | among the ancient circles of magical healers. Its liquid glows with a radiant 21 | luminescence, reflecting a mesmerizing blend of soothing hues.. 22 | _healAmount: 5 23 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/HealthPotionSmall.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8bf3e6d26a2462f4ab078b47e1925c4f 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/HealthPotionSmallRecipe.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 482fb64ecffa4001a2d6363de48beb51, type: 3} 13 | m_Name: HealthPotionSmallRecipe 14 | m_EditorClassIdentifier: 15 | _id: 6d1dab0b-a262-4e01-b287-dfbdb1e1f2ee 16 | _displayName: Health Potion Small Recipe 17 | _image: {fileID: 21300000, guid: 857af2546b9e04194afb0da461002771, type: 3} 18 | _cost: 20 19 | _description: Generates a health potion when used. 20 | _ingredients: 21 | - _definition: {fileID: 11400000, guid: d3988ba3f8a2c44e6a1b98201ce75ee2, type: 2} 22 | _quantity: 3 23 | _result: {fileID: 11400000, guid: 8bf3e6d26a2462f4ab078b47e1925c4f, type: 2} 24 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/HealthPotionSmallRecipe.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 5e7593ddbeb614a3984bd7fcc9251406 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Leather.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: c7eda25e41964b24fb6b9fb1353e5966, type: 3} 13 | m_Name: Leather 14 | m_EditorClassIdentifier: 15 | _id: 16bcede9-30ca-4ef6-b1a9-486d57c5ed9c 16 | _displayName: Leather 17 | _image: {fileID: 21300000, guid: 2554010cbdd584354bb1b9d9accab239, type: 3} 18 | _cost: 10 19 | _description: Drakehide, harvested from Ember Peak Drakes, is a prized leather 20 | crafting resource. Its durability and flame-resistance make it ideal for high-quality 21 | armor and accessories. 22 | _category: 0 23 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Leather.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e7bbdeb0bc0ba42d191d18e2ea1fc743 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Longsword.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 9fc961584b0948c5a3ccc032573e690b, type: 3} 13 | m_Name: Longsword 14 | m_EditorClassIdentifier: 15 | _id: 0144b588-bd48-45cb-87d7-a96b94e24cd7 16 | _displayName: Longsword 17 | _image: {fileID: 21300000, guid: b65743150ca544a25ba382709c470005, type: 3} 18 | _cost: 5 19 | _description: Rustfang, the "longsword," is a comedy of errors. Made of rust-infested 20 | iron with an edge as sharp as a spoon, it turns any battle into a slapstick routine. 21 | Truly, it's the warrior's choice for unintentional humor on the battlefield. 22 | _damage: 2 23 | _energyCost: 1 24 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Longsword.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9f77921cfc0df4d3996ebcabcf7b4f4c 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/LongswordRecipe.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 482fb64ecffa4001a2d6363de48beb51, type: 3} 13 | m_Name: LongswordRecipe 14 | m_EditorClassIdentifier: 15 | _id: da290001-9d29-4104-80ba-48efb422f2b2 16 | _displayName: Longsword Recipe 17 | _image: {fileID: 21300000, guid: 857af2546b9e04194afb0da461002771, type: 3} 18 | _cost: 10 19 | _description: Generates a longsword when used. 20 | _ingredients: 21 | - _definition: {fileID: 11400000, guid: f0a0b304827894feb81ecf23309eab1c, type: 2} 22 | _quantity: 10 23 | _result: {fileID: 11400000, guid: 9f77921cfc0df4d3996ebcabcf7b4f4c, type: 2} 24 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/LongswordRecipe.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4e2438a1b36c043e587e88575d07b5ff 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Metal.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: c7eda25e41964b24fb6b9fb1353e5966, type: 3} 13 | m_Name: Metal 14 | m_EditorClassIdentifier: 15 | _id: fe8de451-b933-4e60-a571-bdca52db9640 16 | _displayName: Metal 17 | _image: {fileID: 21300000, guid: 902a87e2441f94725a8ff152d8188fa7, type: 3} 18 | _cost: 10 19 | _description: Stariron, an ethereal metal famed across the fantasy realms, is one 20 | of the most treasured resources for crafting. 21 | _category: 0 22 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/Metal.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f0a0b304827894feb81ecf23309eab1c 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/MineKey.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: c7eda25e41964b24fb6b9fb1353e5966, type: 3} 13 | m_Name: MineKey 14 | m_EditorClassIdentifier: 15 | _id: ce03c95a-1601-4a13-9020-9582e7cd08ab 16 | _displayName: Mine Key 17 | _image: {fileID: 21300000, guid: 164656eebbd2f4832b671fdffbaa2179, type: 3} 18 | _cost: 0 19 | _description: The Veinseeker Key, a symbol of authority and perseverance, is a 20 | legendary artifact crafted specifically for the unfathomable depths of the Crystalline 21 | Caverns. 22 | _category: 1 23 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Definitions/MineKey.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ab590e04be0294a76b81e859c4263afb 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 834f42b7c7ed74e31b3aa343e755cc15 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/README.md: -------------------------------------------------------------------------------- 1 | # Images 2 | 3 | All images provided by https://game-icons.net/ under the [CC BY 3.0](https://creativecommons.org/licenses/by/3.0/) license. 4 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/README.md.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fb608c0a055d4f11a17bd01e960f41c3 3 | timeCreated: 1687909696 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/animal-hide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/animal-hide.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/battle-axe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/battle-axe.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/cancel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/cancel.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/cancel.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c9a19372587234650aeb60b0ac42a201 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 0 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 1 41 | wrapV: 1 42 | wrapW: 0 43 | nPOTScale: 0 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 1 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 1 56 | spriteTessellationDetail: -1 57 | textureType: 8 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | spriteSheet: 110 | serializedVersion: 2 111 | sprites: [] 112 | outline: [] 113 | physicsShape: [] 114 | bones: [] 115 | spriteID: 5e97eb03825dee720800000000000000 116 | internalID: 0 117 | vertices: [] 118 | indices: 119 | edges: [] 120 | weights: [] 121 | secondaryTextures: [] 122 | nameFileIdTable: {} 123 | mipmapLimitGroupName: 124 | pSDRemoveMatte: 0 125 | userData: 126 | assetBundleName: 127 | assetBundleVariant: 128 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/crossed-swords.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/crossed-swords.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/direction-sign.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/direction-sign.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/fire-gem.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/fire-gem.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/fire-gem.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: cb17d85174959467c808508d0f3c5fa8 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 0 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 1 41 | wrapV: 1 42 | wrapW: 0 43 | nPOTScale: 0 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 1 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 1 56 | spriteTessellationDetail: -1 57 | textureType: 8 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | spriteSheet: 110 | serializedVersion: 2 111 | sprites: [] 112 | outline: [] 113 | physicsShape: [] 114 | bones: [] 115 | spriteID: 5e97eb03825dee720800000000000000 116 | internalID: 0 117 | vertices: [] 118 | indices: 119 | edges: [] 120 | weights: [] 121 | secondaryTextures: [] 122 | nameFileIdTable: {} 123 | mipmapLimitGroupName: 124 | pSDRemoveMatte: 0 125 | userData: 126 | assetBundleName: 127 | assetBundleVariant: 128 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/fizzing-flask.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/fizzing-flask.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/flower-emblem.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/flower-emblem.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/gladius.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/gladius.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/gladius.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b65743150ca544a25ba382709c470005 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 0 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 1 41 | wrapV: 1 42 | wrapW: 0 43 | nPOTScale: 0 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 1 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 1 56 | spriteTessellationDetail: -1 57 | textureType: 8 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | spriteSheet: 110 | serializedVersion: 2 111 | sprites: [] 112 | outline: [] 113 | physicsShape: [] 114 | bones: [] 115 | spriteID: 5e97eb03825dee720800000000000000 116 | internalID: 0 117 | vertices: [] 118 | indices: 119 | edges: [] 120 | weights: [] 121 | secondaryTextures: [] 122 | nameFileIdTable: {} 123 | mipmapLimitGroupName: 124 | pSDRemoveMatte: 0 125 | userData: 126 | assetBundleName: 127 | assetBundleVariant: 128 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/key.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/key.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 164656eebbd2f4832b671fdffbaa2179 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 0 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 1 41 | wrapV: 1 42 | wrapW: 0 43 | nPOTScale: 0 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 1 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 1 56 | spriteTessellationDetail: -1 57 | textureType: 8 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | spriteSheet: 110 | serializedVersion: 2 111 | sprites: [] 112 | outline: [] 113 | physicsShape: [] 114 | bones: [] 115 | spriteID: 5e97eb03825dee720800000000000000 116 | internalID: 0 117 | vertices: [] 118 | indices: 119 | edges: [] 120 | weights: [] 121 | secondaryTextures: [] 122 | nameFileIdTable: {} 123 | mipmapLimitGroupName: 124 | pSDRemoveMatte: 0 125 | userData: 126 | assetBundleName: 127 | assetBundleVariant: 128 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/light-backpack.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/light-backpack.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/metal-bar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/metal-bar.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/notebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/notebook.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/round-potion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/round-potion.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/saber-slash.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/saber-slash.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/scroll-unfurled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/scroll-unfurled.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/swap-bag.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/swap-bag.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Images/two-coins.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/Examples/Shop/Images/two-coins.png -------------------------------------------------------------------------------- /Assets/Examples/Shop/Prefabs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 448b7de2c5cc85d4799a598bbaaa00a1 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Prefabs/ItemSlot.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c74de721e2f299847a1ad877e7abb491 3 | PrefabImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 51ae80012d2bec348892feb04a860d9c 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: cda01c72512342b2b872a3816276b6ee 3 | timeCreated: 1687904908 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/HealthPotion.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | using UnityEngine; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | [ItemDefinitionDetails("Potion")] 6 | public class HealthPotion : ItemDefinitionFantasyBase { 7 | [SerializeField] 8 | private int _healAmount; 9 | 10 | public override string Category => "Potion"; 11 | public int HealAmount => _healAmount; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/HealthPotion.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e164270660ca4f598a280953ed1ab81f 3 | timeCreated: 1687907681 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/ItemDefinition.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using CleverCrow.Fluid.ElasticInventory; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | [ItemDefinitionDetails("Generic")] 6 | public class ItemDefinition : ItemDefinitionFantasyBase { 7 | [InventoryCategory] 8 | [SerializeField] 9 | int _category; 10 | 11 | public override string Category => GetCategoryByIndex(_category); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/ItemDefinition.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c7eda25e41964b24fb6b9fb1353e5966 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/ItemDefinitionCustomDisplayName.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | 3 | namespace CleverCrow.Fluid.Examples { 4 | /// 5 | /// Simulates creating a custom display name and category for an item definition 6 | /// 7 | [ItemDefinitionDetails("Custom Display Details")] 8 | public class ItemDefinitionCustomDisplayName : ItemDefinitionBase { 9 | public override string DisplayName => "Custom Display Name"; 10 | public override string Category => "Custom Category"; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/ItemDefinitionCustomDisplayName.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e149b91f3de145dc9820a3c795b7b05a 3 | timeCreated: 1736629859 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/ItemDefinitionFantasyBase.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | using UnityEngine; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | // We strongly recommend declaring your own custom item definition base class. This way you can add/remove your own custom fields 6 | // to any item definition on the fly 7 | public abstract class ItemDefinitionFantasyBase : ItemDefinitionBase { 8 | [SerializeField] 9 | string _displayName; 10 | 11 | [SerializeField] 12 | Sprite _image; 13 | 14 | [SerializeField] 15 | int _cost; 16 | 17 | [TextArea(3, 10)] 18 | [SerializeField] 19 | string _description; 20 | 21 | public override string DisplayName => _displayName; 22 | public Sprite Image => _image; 23 | public int Cost => _cost; 24 | public string Description => _description; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/ItemDefinitionFantasyBase.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 70f7aa78021b483aac2a449acf663165 3 | timeCreated: 1687831837 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/Recipes.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using CleverCrow.Fluid.ElasticInventory; 3 | using UnityEngine; 4 | 5 | namespace CleverCrow.Fluid.Examples { 6 | [ItemDefinitionDetails("Recipe")] 7 | public class Recipes : ItemDefinitionFantasyBase { 8 | [SerializeField] 9 | List _ingredients; 10 | 11 | [SerializeField] 12 | ItemDefinitionFantasyBase _result; 13 | 14 | public override string Category => "Recipe"; 15 | public List Ingredients => _ingredients; 16 | public ItemDefinitionFantasyBase Result => _result; 17 | 18 | // Call this to verify ingredients are present in the inventory before running 19 | public bool HasIngredients (IInventoryInstance inventory) { 20 | foreach (var ingredient in _ingredients) { 21 | if (!inventory.Has(ingredient.Definition, ingredient.Quantity)) { 22 | return false; 23 | } 24 | } 25 | 26 | return true; 27 | } 28 | 29 | public void ConvertIngredientsToItem (IInventoryInstance inventory) { 30 | foreach (var ingredient in _ingredients) { 31 | inventory.Remove(ingredient.Definition, ingredient.Quantity); 32 | } 33 | 34 | inventory.Add(_result); 35 | } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/Recipes.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 482fb64ecffa4001a2d6363de48beb51 3 | timeCreated: 1687908108 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/WeaponDefinition.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fc8f359a97f130146a609947cf909ad5 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/WeaponDefinition/ItemDefinitionWeapon.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | using UnityEngine; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | [ItemDefinitionDetails("Weapon")] 6 | public class ItemDefinitionWeapon : ItemDefinitionFantasyBase { 7 | [SerializeField] 8 | private int _damage; 9 | 10 | [SerializeField] 11 | private int _energyCost; 12 | 13 | public override bool Unique => true; 14 | public override IItemEntryDataResolver DataResolver => new ItemEntryDataResolverWeapon(); 15 | 16 | // Please note this DOES NOT automatically add the category to the dropdown of available categories 17 | // To do that you must add the category to the ItemDatabase 18 | // You don't need to do this if you're not planning to make this category available to the category dropdown 19 | public override string Category => "Weapon"; 20 | public int Damage => _damage; 21 | public int EnergyCost => _energyCost; 22 | 23 | public override IItemEntry CreateItemEntry (IItemDatabase database, int quantity = 1, string id = null, int? createdAt = null, int? updatedAt = null) { 24 | var entry = new ItemEntryWeapon(); 25 | entry.Setup(database, this, quantity, id, createdAt, updatedAt); 26 | 27 | return entry; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/WeaponDefinition/ItemDefinitionWeapon.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9fc961584b0948c5a3ccc032573e690b 3 | timeCreated: 1686617852 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/WeaponDefinition/ItemEntryDataResolverWeapon.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | 3 | namespace CleverCrow.Fluid.Examples { 4 | /// 5 | /// Handle the saving and loading of editable fields for a weapon entry instance 6 | /// 7 | [System.Serializable] 8 | public class ItemEntryDataResolverWeapon : ItemEntryDataResolverBase { 9 | public int level; 10 | public int durability; 11 | 12 | protected override void OnSave (ItemEntryWeapon itemEntry) { 13 | level = itemEntry.Level; 14 | durability = itemEntry.Durability; 15 | } 16 | 17 | protected override void OnLoad (ItemEntryWeapon itemEntry) { 18 | itemEntry.Level = level; 19 | itemEntry.Durability = durability; 20 | } 21 | 22 | protected override void OnReset () { 23 | level = 0; 24 | durability = 0; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/WeaponDefinition/ItemEntryDataResolverWeapon.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 81139ded2f2941ee8bbce34b99bdd1dc 3 | timeCreated: 1686701715 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/WeaponDefinition/ItemEntryWeapon.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | 3 | namespace CleverCrow.Fluid.Examples { 4 | /// 5 | /// Declare editable fields for spawned item instances 6 | /// 7 | public class ItemEntryWeapon : ItemEntryBase { 8 | public int Level { get; set; } = 1; 9 | public int Durability { get; set; } = 1000; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Definitions/WeaponDefinition/ItemEntryWeapon.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6cf68c5f6ee348dba7eb51d31dfe001d 3 | timeCreated: 1686617785 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/InventorySaveHelper.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using CleverCrow.Fluid.Databases; 3 | using CleverCrow.Fluid.ElasticInventory; 4 | using UnityEngine; 5 | 6 | namespace CleverCrow.Fluid.Examples { 7 | /// 8 | /// Please note this script must be executed before the inventory helper and item database scripts 9 | /// You'll need to manually set the index in the script execution order window 10 | /// https://docs.unity3d.com/Manual/class-MonoManager.html 11 | /// 12 | public class InventorySaveHelper : MonoBehaviour { 13 | const string SAVE_KEY = "GLOBAL_DATABASE_SAVE"; 14 | 15 | [SerializeField] 16 | List _inventories; 17 | 18 | void Awake () { 19 | if (!PlayerPrefs.HasKey(SAVE_KEY)) return; 20 | 21 | var save = PlayerPrefs.GetString(SAVE_KEY); 22 | GlobalDatabaseManager.Instance.Load(save); 23 | } 24 | 25 | public void Save () { 26 | _inventories.ForEach(i => i.Save()); 27 | ItemDatabase.Current.Save(); 28 | 29 | var save = GlobalDatabaseManager.Instance.Save(); 30 | PlayerPrefs.SetString(SAVE_KEY, save); 31 | 32 | Debug.Log("Saved"); 33 | } 34 | 35 | public void DeleteSaves () { 36 | PlayerPrefs.DeleteKey(SAVE_KEY); 37 | Debug.Log("Deleted Save Data"); 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/InventorySaveHelper.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: bb3ccbff6f784643902212f38685ee21 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: -50 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ac237de35db943b3937c99af916272ce 3 | timeCreated: 1687904899 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1ed54147cbab4278aa22ea96cbdb86a5 3 | timeCreated: 1688242246 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/InventoryPrinter.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 641c4ac58d804b1d84205093a2f6f2ed 3 | timeCreated: 1688242197 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/ItemCategoryButton.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using UnityEngine.UI; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | public class ItemCategoryButton : MonoBehaviour { 6 | const float _ACTIVE_OPACITY = 1f; 7 | const float _INACTIVE_OPACITY = 0.5f; 8 | 9 | [SerializeField] 10 | string _category; 11 | 12 | [SerializeField] 13 | Button _button; 14 | 15 | [SerializeField] 16 | Image _image; 17 | 18 | public void Setup (InventoryPrinter inventoryPrinter) { 19 | _button.onClick.AddListener(() => { 20 | inventoryPrinter.SetCategory(_category); 21 | inventoryPrinter.ClearCategoryActive(); 22 | SetActive(true); 23 | }); 24 | } 25 | 26 | public void SetActive (bool active) { 27 | _image.color = new Color(1, 1, 1, active ? _ACTIVE_OPACITY : _INACTIVE_OPACITY); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/ItemCategoryButton.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 5064a04ad5e7422ba529b61473e05195 3 | timeCreated: 1688245426 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/ItemContextPrinter.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | using UnityEngine; 3 | using UnityEngine.Events; 4 | using UnityEngine.UI; 5 | 6 | namespace CleverCrow.Fluid.Examples { 7 | public class ItemContextPrinter : MonoBehaviour { 8 | [SerializeField] 9 | private TMPro.TextMeshProUGUI _title; 10 | 11 | [SerializeField] 12 | private TMPro.TextMeshProUGUI _description; 13 | 14 | [SerializeField] 15 | Button _purchaseButton; 16 | 17 | public UnityEvent OnPurchase { get; } = new(); 18 | 19 | void Start () { 20 | Clear(); 21 | } 22 | 23 | public void Clear () { 24 | _title.text = ""; 25 | _description.text = ""; 26 | if (_purchaseButton != null) _purchaseButton.gameObject.SetActive(false); 27 | } 28 | 29 | public void Set (IItemEntryReadOnly entry) { 30 | var definition = entry.Definition as ItemDefinitionFantasyBase; 31 | 32 | _title.text = definition.DisplayName; 33 | var description = definition.Description; 34 | description += $"\n\n- Cost: {definition.Cost}"; 35 | 36 | if (definition is ItemDefinitionWeapon weapon) { 37 | description += $"\n- Damage: {weapon.Damage}\n- Energy Cost: {weapon.EnergyCost}"; 38 | } else if (definition is HealthPotion potion) { 39 | description += $"\n- Heal Amount: {potion.HealAmount}"; 40 | } 41 | 42 | _description.text = description; 43 | 44 | if (_purchaseButton != null) { 45 | _purchaseButton.gameObject.SetActive(true); 46 | _purchaseButton.onClick.RemoveAllListeners(); 47 | _purchaseButton.onClick.AddListener(() => OnPurchase.Invoke(entry)); 48 | } 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/ItemContextPrinter.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 689e1801650c4cc3b7a65f3a9465f155 3 | timeCreated: 1688243134 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/ItemPrinter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | using UnityEngine.UI; 4 | 5 | namespace CleverCrow.Fluid.Examples { 6 | public class ItemPrinter : MonoBehaviour { 7 | [SerializeField] 8 | Image _image; 9 | 10 | [SerializeField] 11 | TMPro.TextMeshProUGUI _quantity; 12 | 13 | [SerializeField] 14 | Button _button; 15 | 16 | public void Setup (ItemDefinitionFantasyBase definition, int quantity) { 17 | _image.sprite = definition.Image; 18 | SetQuantity(quantity); 19 | } 20 | 21 | public void AddClick (Action action) { 22 | _button.onClick.AddListener(() => action()); 23 | } 24 | 25 | public void SetQuantity (int quantity) { 26 | _quantity.text = quantity == 1 ? "" : quantity.ToString(); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/ItemPrinter.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 66f44ed43e1b40d987da4de89c4885dd 3 | timeCreated: 1688242262 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/PrintItemQuantity.cs: -------------------------------------------------------------------------------- 1 | using CleverCrow.Fluid.ElasticInventory; 2 | using UnityEngine; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | public class PrintItemQuantity : MonoBehaviour { 6 | [SerializeField] 7 | private TMPro.TextMeshProUGUI _text; 8 | 9 | [SerializeField] 10 | private InventoryHelper _inventory; 11 | 12 | [SerializeField] 13 | private ItemDefinitionBase _itemDefinition; 14 | 15 | void Start () { 16 | var entry = _inventory.Instance.Get(_itemDefinition); 17 | _text.text = entry != null ? entry.Quantity.ToString() : "0"; 18 | 19 | _inventory.Instance.Events.ItemChanged.AddListener(OnItemChange); 20 | } 21 | 22 | void OnDestroy () { 23 | _inventory.Instance.Events.ItemChanged.RemoveListener(OnItemChange); 24 | } 25 | 26 | void OnItemChange (IItemEntryReadOnly entry) { 27 | if ((ItemDefinitionBase)entry.Definition != _itemDefinition) return; 28 | _text.text = entry.Quantity.ToString(); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/InventoryPrinter/PrintItemQuantity.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f3d80c97a8cf48279e2e1087f02e1b2c 3 | timeCreated: 1688244453 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/MenuNavigator.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using UnityEngine; 3 | 4 | namespace CleverCrow.Fluid.Examples { 5 | public class MenuNavigator : MonoBehaviour { 6 | [SerializeField] 7 | List _menus; 8 | 9 | public void ShowMenu (GameObject menu) { 10 | foreach (var m in _menus) { 11 | m.SetActive(false); 12 | } 13 | 14 | menu.SetActive(true); 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Assets/Examples/Shop/Scripts/Menus/MenuNavigator.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 28437d0317304905a05ef60ca9424443 3 | timeCreated: 1687904929 -------------------------------------------------------------------------------- /Assets/Examples/Shop/Shop.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9fc0d4010bbf28b4594072e72b8655ab 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/HealthPotionLarge.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: e164270660ca4f598a280953ed1ab81f, type: 3} 13 | m_Name: HealthPotionLarge 14 | m_EditorClassIdentifier: 15 | _id: 3d4ebbb8-cf22-4900-8ec9-0e50f416420d 16 | _displayName: Health Potion Large 17 | _image: {fileID: 21300000, guid: 9f05c8edbc90440d8a7ca99fb9673ae7, type: 3} 18 | _cost: 30 19 | _description: The Healing Potion of Halcyon is the stuff of legends, whispered 20 | among the ancient circles of magical healers. Its liquid glows with a radiant 21 | luminescence, reflecting a mesmerizing blend of soothing hues.. 22 | _healAmount: 100 23 | -------------------------------------------------------------------------------- /Assets/HealthPotionLarge.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: af5f8c4cbc9ca47399a535ac79bca821 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f54d1bd14bd3ca042bd867b519fee8cc 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Documentation.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8e7e8f5a82a3a134e91c54efd2274ea9 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Documentation/TextMesh Pro User Guide 2016.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/TextMesh Pro/Documentation/TextMesh Pro User Guide 2016.pdf -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Documentation/TextMesh Pro User Guide 2016.pdf.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1b8d251f9af63b746bf2f7ffe00ebb9b 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Fonts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6ab70aee4d56447429c680537fbf93ed 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Fonts/LiberationSans - OFL.txt.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6e59c59b81ab47f9b6ec5781fa725d2c 3 | timeCreated: 1484171296 4 | licenseType: Pro 5 | TextScriptImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Fonts/LiberationSans.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/TextMesh Pro/Fonts/LiberationSans.ttf -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Fonts/LiberationSans.ttf.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e3265ab4bf004d28a9537516768c1c75 3 | timeCreated: 1484171297 4 | licenseType: Pro 5 | TrueTypeFontImporter: 6 | serializedVersion: 2 7 | fontSize: 16 8 | forceTextureCase: -2 9 | characterSpacing: 1 10 | characterPadding: 0 11 | includeFontData: 1 12 | use2xBehaviour: 0 13 | fontNames: [] 14 | fallbackFontReferences: [] 15 | customCharacters: 16 | fontRenderingMode: 0 17 | userData: 18 | assetBundleName: 19 | assetBundleVariant: 20 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 243e06394e614e5d99fab26083b707fa 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Fonts & Materials.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 731f1baa9d144a9897cb1d341c2092b8 3 | folderAsset: yes 4 | timeCreated: 1442040525 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Drop Shadow.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 6 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: LiberationSans SDF - Drop Shadow 11 | m_Shader: {fileID: 4800000, guid: fe393ace9b354375a9cb14cdbbc28be4, type: 3} 12 | m_ShaderKeywords: OUTLINE_ON UNDERLAY_ON 13 | m_LightmapFlags: 5 14 | m_EnableInstancingVariants: 0 15 | m_DoubleSidedGI: 0 16 | m_CustomRenderQueue: -1 17 | stringTagMap: {} 18 | disabledShaderPasses: [] 19 | m_SavedProperties: 20 | serializedVersion: 3 21 | m_TexEnvs: 22 | - _BumpMap: 23 | m_Texture: {fileID: 0} 24 | m_Scale: {x: 1, y: 1} 25 | m_Offset: {x: 0, y: 0} 26 | - _Cube: 27 | m_Texture: {fileID: 0} 28 | m_Scale: {x: 1, y: 1} 29 | m_Offset: {x: 0, y: 0} 30 | - _FaceTex: 31 | m_Texture: {fileID: 0} 32 | m_Scale: {x: 1, y: 1} 33 | m_Offset: {x: 0, y: 0} 34 | - _MainTex: 35 | m_Texture: {fileID: 28684132378477856, guid: 8f586378b4e144a9851e7b34d9b748ee, 36 | type: 2} 37 | m_Scale: {x: 1, y: 1} 38 | m_Offset: {x: 0, y: 0} 39 | - _OutlineTex: 40 | m_Texture: {fileID: 0} 41 | m_Scale: {x: 1, y: 1} 42 | m_Offset: {x: 0, y: 0} 43 | m_Floats: 44 | - _Ambient: 0.5 45 | - _Bevel: 0.5 46 | - _BevelClamp: 0 47 | - _BevelOffset: 0 48 | - _BevelRoundness: 0 49 | - _BevelWidth: 0 50 | - _BumpFace: 0 51 | - _BumpOutline: 0 52 | - _ColorMask: 15 53 | - _Diffuse: 0.5 54 | - _DiffusePower: 1 55 | - _FaceDilate: 0.1 56 | - _FaceUVSpeedX: 0 57 | - _FaceUVSpeedY: 0 58 | - _GlowInner: 0.05 59 | - _GlowOffset: 0 60 | - _GlowOuter: 0.05 61 | - _GlowPower: 0.75 62 | - _GradientScale: 10 63 | - _LightAngle: 3.1416 64 | - _MaskSoftnessX: 0 65 | - _MaskSoftnessY: 0 66 | - _OutlineSoftness: 0 67 | - _OutlineUVSpeedX: 0 68 | - _OutlineUVSpeedY: 0 69 | - _OutlineWidth: 0.1 70 | - _PerspectiveFilter: 0.875 71 | - _Reflectivity: 10 72 | - _ScaleRatioA: 0.9 73 | - _ScaleRatioB: 0.73125 74 | - _ScaleRatioC: 0.64125 75 | - _ScaleX: 1 76 | - _ScaleY: 1 77 | - _ShaderFlags: 0 78 | - _Sharpness: 0 79 | - _SpecularPower: 2 80 | - _Stencil: 0 81 | - _StencilComp: 8 82 | - _StencilOp: 0 83 | - _StencilReadMask: 255 84 | - _StencilWriteMask: 255 85 | - _TextureHeight: 1024 86 | - _TextureWidth: 1024 87 | - _UnderlayDilate: 0 88 | - _UnderlayOffsetX: 0.5 89 | - _UnderlayOffsetY: -0.5 90 | - _UnderlaySoftness: 0.05 91 | - _VertexOffsetX: 0 92 | - _VertexOffsetY: 0 93 | - _WeightBold: 0.75 94 | - _WeightNormal: 0 95 | m_Colors: 96 | - _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767} 97 | - _Color: {r: 1, g: 1, b: 1, a: 1} 98 | - _EnvMatrixRotation: {r: 0, g: 0, b: 0, a: 0} 99 | - _FaceColor: {r: 1, g: 1, b: 1, a: 1} 100 | - _GlowColor: {r: 0, g: 1, b: 0, a: 0.5} 101 | - _MaskCoord: {r: 0, g: 0, b: 32767, a: 32767} 102 | - _OutlineColor: {r: 0, g: 0, b: 0, a: 1} 103 | - _ReflectFaceColor: {r: 0, g: 0, b: 0, a: 1} 104 | - _ReflectOutlineColor: {r: 0, g: 0, b: 0, a: 1} 105 | - _SpecularColor: {r: 1, g: 1, b: 1, a: 1} 106 | - _UnderlayColor: {r: 0, g: 0, b: 0, a: 0.5} 107 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Drop Shadow.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e73a58f6e2794ae7b1b7e50b7fb811b0 3 | timeCreated: 1484172806 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Fallback.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2e498d1c8094910479dc3e1b768306a4 3 | timeCreated: 1484171803 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Outline.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 6 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: LiberationSans SDF - Outline 11 | m_Shader: {fileID: 4800000, guid: fe393ace9b354375a9cb14cdbbc28be4, type: 3} 12 | m_ShaderKeywords: OUTLINE_ON 13 | m_LightmapFlags: 5 14 | m_EnableInstancingVariants: 0 15 | m_DoubleSidedGI: 0 16 | m_CustomRenderQueue: -1 17 | stringTagMap: {} 18 | disabledShaderPasses: [] 19 | m_SavedProperties: 20 | serializedVersion: 3 21 | m_TexEnvs: 22 | - _BumpMap: 23 | m_Texture: {fileID: 0} 24 | m_Scale: {x: 1, y: 1} 25 | m_Offset: {x: 0, y: 0} 26 | - _Cube: 27 | m_Texture: {fileID: 0} 28 | m_Scale: {x: 1, y: 1} 29 | m_Offset: {x: 0, y: 0} 30 | - _FaceTex: 31 | m_Texture: {fileID: 0} 32 | m_Scale: {x: 1, y: 1} 33 | m_Offset: {x: 0, y: 0} 34 | - _MainTex: 35 | m_Texture: {fileID: 28684132378477856, guid: 8f586378b4e144a9851e7b34d9b748ee, 36 | type: 2} 37 | m_Scale: {x: 1, y: 1} 38 | m_Offset: {x: 0, y: 0} 39 | - _OutlineTex: 40 | m_Texture: {fileID: 0} 41 | m_Scale: {x: 1, y: 1} 42 | m_Offset: {x: 0, y: 0} 43 | m_Floats: 44 | - _Ambient: 0.5 45 | - _Bevel: 0.5 46 | - _BevelClamp: 0 47 | - _BevelOffset: 0 48 | - _BevelRoundness: 0 49 | - _BevelWidth: 0 50 | - _BumpFace: 0 51 | - _BumpOutline: 0 52 | - _ColorMask: 15 53 | - _Diffuse: 0.5 54 | - _FaceDilate: 0.1 55 | - _FaceUVSpeedX: 0 56 | - _FaceUVSpeedY: 0 57 | - _GlowInner: 0.05 58 | - _GlowOffset: 0 59 | - _GlowOuter: 0.05 60 | - _GlowPower: 0.75 61 | - _GradientScale: 10 62 | - _LightAngle: 3.1416 63 | - _MaskSoftnessX: 0 64 | - _MaskSoftnessY: 0 65 | - _OutlineSoftness: 0 66 | - _OutlineUVSpeedX: 0 67 | - _OutlineUVSpeedY: 0 68 | - _OutlineWidth: 0.1 69 | - _PerspectiveFilter: 0.875 70 | - _Reflectivity: 10 71 | - _ScaleRatioA: 0.9 72 | - _ScaleRatioB: 0.73125 73 | - _ScaleRatioC: 0.64125 74 | - _ScaleX: 1 75 | - _ScaleY: 1 76 | - _ShaderFlags: 0 77 | - _Sharpness: 0 78 | - _SpecularPower: 2 79 | - _Stencil: 0 80 | - _StencilComp: 8 81 | - _StencilOp: 0 82 | - _StencilReadMask: 255 83 | - _StencilWriteMask: 255 84 | - _TextureHeight: 1024 85 | - _TextureWidth: 1024 86 | - _UnderlayDilate: 0 87 | - _UnderlayOffsetX: 0 88 | - _UnderlayOffsetY: 0 89 | - _UnderlaySoftness: 0 90 | - _VertexOffsetX: 0 91 | - _VertexOffsetY: 0 92 | - _WeightBold: 0.75 93 | - _WeightNormal: 0 94 | m_Colors: 95 | - _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767} 96 | - _EnvMatrixRotation: {r: 0, g: 0, b: 0, a: 0} 97 | - _FaceColor: {r: 1, g: 1, b: 1, a: 1} 98 | - _GlowColor: {r: 0, g: 1, b: 0, a: 0.5} 99 | - _MaskCoord: {r: 0, g: 0, b: 32767, a: 32767} 100 | - _OutlineColor: {r: 0, g: 0, b: 0, a: 1} 101 | - _ReflectFaceColor: {r: 0, g: 0, b: 0, a: 1} 102 | - _ReflectOutlineColor: {r: 0, g: 0, b: 0, a: 1} 103 | - _SpecularColor: {r: 1, g: 1, b: 1, a: 1} 104 | - _UnderlayColor: {r: 0, g: 0, b: 0, a: 0.5} 105 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Outline.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 79459efec17a4d00a321bdcc27bbc385 3 | timeCreated: 1484172856 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8f586378b4e144a9851e7b34d9b748ee 3 | timeCreated: 1484171803 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/LineBreaking Following Characters.txt: -------------------------------------------------------------------------------- 1 | )]}〕〉》」』】〙〗〟’”⦆»ヽヾーァィゥェォッャュョヮヵヶぁぃぅぇぉっゃゅょゎゕゖㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇺㇻㇼㇽㇾㇿ々〻‐゠–〜?!‼⁇⁈⁉・、%,.:;。!?]):;=}¢°"†‡℃〆%,. -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/LineBreaking Following Characters.txt.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fade42e8bc714b018fac513c043d323b 3 | timeCreated: 1425440388 4 | licenseType: Store 5 | TextScriptImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/LineBreaking Leading Characters.txt: -------------------------------------------------------------------------------- 1 | ([{〔〈《「『【〘〖〝‘“⦅«$—…‥〳〴〵\[({£¥"々〇$¥₩ # -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/LineBreaking Leading Characters.txt.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d82c1b31c7e74239bff1220585707d2b 3 | timeCreated: 1425440388 4 | licenseType: Store 5 | TextScriptImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Sprite Assets.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 512a49d95c0c4332bdd98131869c23c9 3 | folderAsset: yes 4 | timeCreated: 1441876896 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Sprite Assets/EmojiOne.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c41005c129ba4d66911b75229fd70b45 3 | timeCreated: 1480316912 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Style Sheets.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4aecb92fff08436c8303b10eab8da368 3 | folderAsset: yes 4 | timeCreated: 1441876950 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/Style Sheets/Default Style Sheet.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f952c082cb03451daed3ee968ac6c63e 3 | timeCreated: 1432805430 4 | licenseType: Store 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/TMP Settings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 2705215ac5b84b70bacc50632be6e391, type: 3} 13 | m_Name: TMP Settings 14 | m_EditorClassIdentifier: 15 | assetVersion: 2 16 | m_TextWrappingMode: 1 17 | m_enableKerning: 1 18 | m_ActiveFontFeatures: 00000000 19 | m_enableExtraPadding: 0 20 | m_enableTintAllSprites: 0 21 | m_enableParseEscapeCharacters: 1 22 | m_EnableRaycastTarget: 1 23 | m_GetFontFeaturesAtRuntime: 1 24 | m_missingGlyphCharacter: 0 25 | m_ClearDynamicDataOnBuild: 1 26 | m_warningsDisabled: 0 27 | m_defaultFontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} 28 | m_defaultFontAssetPath: Fonts & Materials/ 29 | m_defaultFontSize: 36 30 | m_defaultAutoSizeMinRatio: 0.5 31 | m_defaultAutoSizeMaxRatio: 2 32 | m_defaultTextMeshProTextContainerSize: {x: 20, y: 5} 33 | m_defaultTextMeshProUITextContainerSize: {x: 200, y: 50} 34 | m_autoSizeTextContainer: 0 35 | m_IsTextObjectScaleStatic: 0 36 | m_fallbackFontAssets: [] 37 | m_matchMaterialPreset: 1 38 | m_HideSubTextObjects: 1 39 | m_defaultSpriteAsset: {fileID: 11400000, guid: c41005c129ba4d66911b75229fd70b45, type: 2} 40 | m_defaultSpriteAssetPath: Sprite Assets/ 41 | m_enableEmojiSupport: 1 42 | m_MissingCharacterSpriteUnicode: 0 43 | m_EmojiFallbackTextAssets: [] 44 | m_defaultColorGradientPresetsPath: Color Gradient Presets/ 45 | m_defaultStyleSheet: {fileID: 11400000, guid: f952c082cb03451daed3ee968ac6c63e, type: 2} 46 | m_StyleSheetsResourcePath: 47 | m_leadingCharacters: {fileID: 4900000, guid: d82c1b31c7e74239bff1220585707d2b, type: 3} 48 | m_followingCharacters: {fileID: 4900000, guid: fade42e8bc714b018fac513c043d323b, type: 3} 49 | m_UseModernHangulLineBreakingRules: 0 50 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Resources/TMP Settings.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3f5b5dff67a942289a9defa416b206f3 3 | timeCreated: 1436653997 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e9f693669af91aa45ad615fc681ed29f 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/SDFFunctions.hlsl.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 96de908384869cd409c75efa351d5edf 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | preprocessorOverride: 0 8 | userData: 9 | assetBundleName: 10 | assetBundleVariant: 11 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_Bitmap-Custom-Atlas.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 48bb5f55d8670e349b6e614913f9d910 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_Bitmap-Mobile.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1e3b057af24249748ff873be7fafee47 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_Bitmap.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 128e987d567d4e2c824d754223b3f3b0 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF Overlay.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: dd89cf5b9246416f84610a006f916af7 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF SSD.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 14eb328de4b8eb245bb7cea29e4ac00b 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-HDRP LIT.shadergraph.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ca2ed216f98028c4dae6c5224a952b3c 3 | ScriptedImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 2 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | script: {fileID: 11500000, guid: 625f186215c104763be7675aa2d941aa, type: 3} 11 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-HDRP UNLIT.shadergraph.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f63d574838ccfb44f84acc05fed0af48 3 | ScriptedImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 2 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | script: {fileID: 11500000, guid: 625f186215c104763be7675aa2d941aa, type: 3} 11 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Mobile Masking.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: bc1ede39bf3643ee8e493720e4259791 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Mobile Overlay.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a02a7d8c237544f1962732b55a9aebf1 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Mobile SSD.shader: -------------------------------------------------------------------------------- 1 | // Simplified SDF shader: 2 | // - No Shading Option (bevel / bump / env map) 3 | // - No Glow Option 4 | // - Softness is applied on both side of the outline 5 | 6 | Shader "TextMeshPro/Mobile/Distance Field SSD" { 7 | 8 | Properties { 9 | _FaceColor ("Face Color", Color) = (1,1,1,1) 10 | _FaceDilate ("Face Dilate", Range(-1,1)) = 0 11 | 12 | _OutlineColor ("Outline Color", Color) = (0,0,0,1) 13 | _OutlineWidth ("Outline Thickness", Range(0,1)) = 0 14 | _OutlineSoftness ("Outline Softness", Range(0,1)) = 0 15 | 16 | _UnderlayColor ("Border Color", Color) = (0,0,0,.5) 17 | _UnderlayOffsetX ("Border OffsetX", Range(-1,1)) = 0 18 | _UnderlayOffsetY ("Border OffsetY", Range(-1,1)) = 0 19 | _UnderlayDilate ("Border Dilate", Range(-1,1)) = 0 20 | _UnderlaySoftness ("Border Softness", Range(0,1)) = 0 21 | 22 | _WeightNormal ("Weight Normal", float) = 0 23 | _WeightBold ("Weight Bold", float) = .5 24 | 25 | _ShaderFlags ("Flags", float) = 0 26 | _ScaleRatioA ("Scale RatioA", float) = 1 27 | _ScaleRatioB ("Scale RatioB", float) = 1 28 | _ScaleRatioC ("Scale RatioC", float) = 1 29 | 30 | _MainTex ("Font Atlas", 2D) = "white" {} 31 | _TextureWidth ("Texture Width", float) = 512 32 | _TextureHeight ("Texture Height", float) = 512 33 | _GradientScale ("Gradient Scale", float) = 5 34 | _ScaleX ("Scale X", float) = 1 35 | _ScaleY ("Scale Y", float) = 1 36 | _PerspectiveFilter ("Perspective Correction", Range(0, 1)) = 0.875 37 | _Sharpness ("Sharpness", Range(-1,1)) = 0 38 | 39 | _VertexOffsetX ("Vertex OffsetX", float) = 0 40 | _VertexOffsetY ("Vertex OffsetY", float) = 0 41 | 42 | _ClipRect ("Clip Rect", vector) = (-32767, -32767, 32767, 32767) 43 | _MaskSoftnessX ("Mask SoftnessX", float) = 0 44 | _MaskSoftnessY ("Mask SoftnessY", float) = 0 45 | _MaskTex ("Mask Texture", 2D) = "white" {} 46 | _MaskInverse ("Inverse", float) = 0 47 | _MaskEdgeColor ("Edge Color", Color) = (1,1,1,1) 48 | _MaskEdgeSoftness ("Edge Softness", Range(0, 1)) = 0.01 49 | _MaskWipeControl ("Wipe Position", Range(0, 1)) = 0.5 50 | 51 | _StencilComp ("Stencil Comparison", Float) = 8 52 | _Stencil ("Stencil ID", Float) = 0 53 | _StencilOp ("Stencil Operation", Float) = 0 54 | _StencilWriteMask ("Stencil Write Mask", Float) = 255 55 | _StencilReadMask ("Stencil Read Mask", Float) = 255 56 | 57 | _CullMode ("Cull Mode", Float) = 0 58 | _ColorMask ("Color Mask", Float) = 15 59 | } 60 | 61 | SubShader { 62 | Tags { 63 | "Queue"="Transparent" 64 | "IgnoreProjector"="True" 65 | "RenderType"="Transparent" 66 | } 67 | 68 | Stencil 69 | { 70 | Ref [_Stencil] 71 | Comp [_StencilComp] 72 | Pass [_StencilOp] 73 | ReadMask [_StencilReadMask] 74 | WriteMask [_StencilWriteMask] 75 | } 76 | 77 | Cull [_CullMode] 78 | ZWrite Off 79 | Lighting Off 80 | Fog { Mode Off } 81 | ZTest [unity_GUIZTestMode] 82 | Blend One OneMinusSrcAlpha 83 | ColorMask [_ColorMask] 84 | 85 | Pass { 86 | CGPROGRAM 87 | #pragma vertex VertShader 88 | #pragma fragment PixShader 89 | #pragma shader_feature __ OUTLINE_ON 90 | #pragma shader_feature __ UNDERLAY_ON UNDERLAY_INNER 91 | 92 | #pragma multi_compile __ UNITY_UI_CLIP_RECT 93 | #pragma multi_compile __ UNITY_UI_ALPHACLIP 94 | 95 | #include "UnityCG.cginc" 96 | #include "UnityUI.cginc" 97 | #include "TMPro_Properties.cginc" 98 | 99 | #include "TMPro_Mobile.cginc" 100 | 101 | ENDCG 102 | } 103 | } 104 | 105 | CustomEditor "TMPro.EditorUtilities.TMP_SDFShaderGUI" 106 | } 107 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Mobile SSD.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c8d12adcee749c344b8117cf7c7eb912 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Mobile-2-Pass.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0178fcb869bafef4690d177d31d17db8 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Mobile.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fe393ace9b354375a9cb14cdbbc28be4 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Surface-Mobile.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 85187c2149c549c5b33f0cdb02836b17 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-Surface.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f7ada0af4f174f0694ca6a487b8f543d 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-URP Lit.shadergraph.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a3d800b099a06e0478fb790c5e79057a 3 | ScriptedImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 2 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | script: {fileID: 11500000, guid: 625f186215c104763be7675aa2d941aa, type: 3} 11 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF-URP Unlit.shadergraph.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 124c112a6e8f1a54e8b0870e881b56d8 3 | ScriptedImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 2 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | script: {fileID: 11500000, guid: 625f186215c104763be7675aa2d941aa, type: 3} 11 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_SDF.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 68e6db2ebdc24f95958faec2be5558d6 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMP_Sprite.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: cf81c85f95fe47e1a27f6ae460cf182c 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMPro.cginc: -------------------------------------------------------------------------------- 1 | float2 UnpackUV(float uv) 2 | { 3 | float2 output; 4 | output.x = floor(uv / 4096); 5 | output.y = uv - 4096 * output.x; 6 | 7 | return output * 0.001953125; 8 | } 9 | 10 | fixed4 GetColor(half d, fixed4 faceColor, fixed4 outlineColor, half outline, half softness) 11 | { 12 | half faceAlpha = 1-saturate((d - outline * 0.5 + softness * 0.5) / (1.0 + softness)); 13 | half outlineAlpha = saturate((d + outline * 0.5)) * sqrt(min(1.0, outline)); 14 | 15 | faceColor.rgb *= faceColor.a; 16 | outlineColor.rgb *= outlineColor.a; 17 | 18 | faceColor = lerp(faceColor, outlineColor, outlineAlpha); 19 | 20 | faceColor *= faceAlpha; 21 | 22 | return faceColor; 23 | } 24 | 25 | float3 GetSurfaceNormal(float4 h, float bias) 26 | { 27 | bool raisedBevel = step(1, fmod(_ShaderFlags, 2)); 28 | 29 | h += bias+_BevelOffset; 30 | 31 | float bevelWidth = max(.01, _OutlineWidth+_BevelWidth); 32 | 33 | // Track outline 34 | h -= .5; 35 | h /= bevelWidth; 36 | h = saturate(h+.5); 37 | 38 | if(raisedBevel) h = 1 - abs(h*2.0 - 1.0); 39 | h = lerp(h, sin(h*3.141592/2.0), _BevelRoundness); 40 | h = min(h, 1.0-_BevelClamp); 41 | h *= _Bevel * bevelWidth * _GradientScale * -2.0; 42 | 43 | float3 va = normalize(float3(1.0, 0.0, h.y - h.x)); 44 | float3 vb = normalize(float3(0.0, -1.0, h.w - h.z)); 45 | 46 | return cross(va, vb); 47 | } 48 | 49 | float3 GetSurfaceNormal(float2 uv, float bias, float3 delta) 50 | { 51 | // Read "height field" 52 | float4 h = {tex2D(_MainTex, uv - delta.xz).a, 53 | tex2D(_MainTex, uv + delta.xz).a, 54 | tex2D(_MainTex, uv - delta.zy).a, 55 | tex2D(_MainTex, uv + delta.zy).a}; 56 | 57 | return GetSurfaceNormal(h, bias); 58 | } 59 | 60 | float3 GetSpecular(float3 n, float3 l) 61 | { 62 | float spec = pow(max(0.0, dot(n, l)), _Reflectivity); 63 | return _SpecularColor.rgb * spec * _SpecularPower; 64 | } 65 | 66 | float4 GetGlowColor(float d, float scale) 67 | { 68 | float glow = d - (_GlowOffset*_ScaleRatioB) * 0.5 * scale; 69 | float t = lerp(_GlowInner, (_GlowOuter * _ScaleRatioB), step(0.0, glow)) * 0.5 * scale; 70 | glow = saturate(abs(glow/(1.0 + t))); 71 | glow = 1.0-pow(glow, _GlowPower); 72 | glow *= sqrt(min(1.0, t)); // Fade off glow thinner than 1 screen pixel 73 | return float4(_GlowColor.rgb, saturate(_GlowColor.a * glow * 2)); 74 | } 75 | 76 | float4 BlendARGB(float4 overlying, float4 underlying) 77 | { 78 | overlying.rgb *= overlying.a; 79 | underlying.rgb *= underlying.a; 80 | float3 blended = overlying.rgb + ((1-overlying.a)*underlying.rgb); 81 | float alpha = underlying.a + (1-underlying.a)*overlying.a; 82 | return float4(blended, alpha); 83 | } 84 | 85 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMPro.cginc.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 407bc68d299748449bbf7f48ee690f8d 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: Version 2.0 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMPro_Mobile.cginc.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c334973cef89a9840b0b0c507e0377ab 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMPro_Properties.cginc: -------------------------------------------------------------------------------- 1 | // UI Editable properties 2 | uniform sampler2D _FaceTex; // Alpha : Signed Distance 3 | uniform float _FaceUVSpeedX; 4 | uniform float _FaceUVSpeedY; 5 | uniform fixed4 _FaceColor; // RGBA : Color + Opacity 6 | uniform float _FaceDilate; // v[ 0, 1] 7 | uniform float _OutlineSoftness; // v[ 0, 1] 8 | 9 | uniform sampler2D _OutlineTex; // RGBA : Color + Opacity 10 | uniform float _OutlineUVSpeedX; 11 | uniform float _OutlineUVSpeedY; 12 | uniform fixed4 _OutlineColor; // RGBA : Color + Opacity 13 | uniform float _OutlineWidth; // v[ 0, 1] 14 | 15 | uniform float _Bevel; // v[ 0, 1] 16 | uniform float _BevelOffset; // v[-1, 1] 17 | uniform float _BevelWidth; // v[-1, 1] 18 | uniform float _BevelClamp; // v[ 0, 1] 19 | uniform float _BevelRoundness; // v[ 0, 1] 20 | 21 | uniform sampler2D _BumpMap; // Normal map 22 | uniform float _BumpOutline; // v[ 0, 1] 23 | uniform float _BumpFace; // v[ 0, 1] 24 | 25 | uniform samplerCUBE _Cube; // Cube / sphere map 26 | uniform fixed4 _ReflectFaceColor; // RGB intensity 27 | uniform fixed4 _ReflectOutlineColor; 28 | //uniform float _EnvTiltX; // v[-1, 1] 29 | //uniform float _EnvTiltY; // v[-1, 1] 30 | uniform float3 _EnvMatrixRotation; 31 | uniform float4x4 _EnvMatrix; 32 | 33 | uniform fixed4 _SpecularColor; // RGB intensity 34 | uniform float _LightAngle; // v[ 0,Tau] 35 | uniform float _SpecularPower; // v[ 0, 1] 36 | uniform float _Reflectivity; // v[ 5, 15] 37 | uniform float _Diffuse; // v[ 0, 1] 38 | uniform float _Ambient; // v[ 0, 1] 39 | 40 | uniform fixed4 _UnderlayColor; // RGBA : Color + Opacity 41 | uniform float _UnderlayOffsetX; // v[-1, 1] 42 | uniform float _UnderlayOffsetY; // v[-1, 1] 43 | uniform float _UnderlayDilate; // v[-1, 1] 44 | uniform float _UnderlaySoftness; // v[ 0, 1] 45 | 46 | uniform fixed4 _GlowColor; // RGBA : Color + Intesity 47 | uniform float _GlowOffset; // v[-1, 1] 48 | uniform float _GlowOuter; // v[ 0, 1] 49 | uniform float _GlowInner; // v[ 0, 1] 50 | uniform float _GlowPower; // v[ 1, 1/(1+4*4)] 51 | 52 | // API Editable properties 53 | uniform float _ShaderFlags; 54 | uniform float _WeightNormal; 55 | uniform float _WeightBold; 56 | 57 | uniform float _ScaleRatioA; 58 | uniform float _ScaleRatioB; 59 | uniform float _ScaleRatioC; 60 | 61 | uniform float _VertexOffsetX; 62 | uniform float _VertexOffsetY; 63 | 64 | //uniform float _UseClipRect; 65 | uniform float _MaskID; 66 | uniform sampler2D _MaskTex; 67 | uniform float4 _MaskCoord; 68 | uniform float4 _ClipRect; // bottom left(x,y) : top right(z,w) 69 | uniform float _MaskSoftnessX; 70 | uniform float _MaskSoftnessY; 71 | 72 | // Font Atlas properties 73 | uniform sampler2D _MainTex; 74 | uniform float _TextureWidth; 75 | uniform float _TextureHeight; 76 | uniform float _GradientScale; 77 | uniform float _ScaleX; 78 | uniform float _ScaleY; 79 | uniform float _PerspectiveFilter; 80 | uniform float _Sharpness; 81 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMPro_Properties.cginc.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3997e2241185407d80309a82f9148466 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Shaders/TMPro_Surface.cginc.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d930090c0cd643c7b55f19a38538c162 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Sprites.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d0603b6d5186471b96c778c3949c7ce2 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Sprites/EmojiOne Attribution.txt: -------------------------------------------------------------------------------- 1 | This sample of beautiful emojis are provided by EmojiOne https://www.emojione.com/ 2 | 3 | Please visit their website to view the complete set of their emojis and review their licensing terms. -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Sprites/EmojiOne Attribution.txt.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 381dcb09d5029d14897e55f98031fca5 3 | TextScriptImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Sprites/EmojiOne.json.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8f05276190cf498a8153f6cbe761d4e6 3 | timeCreated: 1480316860 4 | licenseType: Pro 5 | TextScriptImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/TextMesh Pro/Sprites/EmojiOne.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashblue/unity-elastic-inventory/981cc0d9e2ac64553ee1383258d84b5dab46b86f/Assets/TextMesh Pro/Sprites/EmojiOne.png -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: bb52ea475aff9412398a7b7fd15572f4 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | Replaced when project is built from commit logs via Semantic Release. 2 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/CHANGELOG.md.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 738a34c22e4054e0a9c06d5e9919a4cc 3 | TextScriptImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Documentation~/com.fluid.elastic-inventory.md: -------------------------------------------------------------------------------- 1 | Documentation beyond README.md goes here. 2 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b86cd99dfac11486f829781bc5f81db9 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 699c1cdf6b6745028d78c7cf7c6b35d2 3 | timeCreated: 1684875207 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Atoms.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a105d96d3ce44d899180fd2fdd6f9a38 3 | timeCreated: 1685131372 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Atoms/DropdownAdd.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using UnityEngine.UIElements; 3 | 4 | namespace CleverCrow.Fluid.ElasticInventory.Editors { 5 | public class DropdownAdd : ComponentBase { 6 | readonly DropdownField _dropdown; 7 | readonly List> _choices; 8 | readonly string _addText; 9 | readonly VisualElement _containerParent; 10 | readonly bool _resetOnInteract; 11 | 12 | // @TODO Make addText optional so the categories will update on click 13 | public DropdownAdd ( 14 | VisualElement containerParent, 15 | string addText, 16 | List> choices, 17 | bool resetOnInteract = true 18 | ) : base(containerParent) { 19 | _containerParent = containerParent; 20 | _choices = choices; 21 | _addText = addText; 22 | _resetOnInteract = resetOnInteract; 23 | 24 | var keys = choices.ConvertAll(choice => choice.Key); 25 | keys.Insert(0, addText); 26 | 27 | _dropdown = CreateDropdownField(keys); 28 | } 29 | 30 | public void BindClick (System.Action callback) { 31 | _dropdown.RegisterCallback>(e => { 32 | if (_resetOnInteract) _dropdown.value = _addText; 33 | if (e.newValue == _addText) { 34 | callback(default); 35 | return; 36 | } 37 | 38 | var choice = _choices.Find(c => c.Key == e.newValue); 39 | callback(choice.Value); 40 | }); 41 | } 42 | 43 | private DropdownField CreateDropdownField (List keys) { 44 | var dropdown = new DropdownField() { 45 | choices = keys, 46 | value = _addText 47 | }; 48 | 49 | _containerParent.Add(dropdown); 50 | 51 | return dropdown; 52 | } 53 | 54 | public void SetValue (int indexOf) { 55 | if (indexOf < 0 || indexOf >= _choices.Count) return; 56 | _dropdown.value = _choices[indexOf].Key; 57 | } 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Atoms/DropdownAdd.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a56c8ee0400e4882937932ebbbf8a923 3 | timeCreated: 1685131381 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Molecules.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a786f15a2afb46b2b81f9c8891c80ba0 3 | timeCreated: 1687027657 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Molecules/SearchInput.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2ed41a3d070d4be78f6b4fde5ea4b8de 3 | timeCreated: 1687027004 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Molecules/SearchInput/SearchInput.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine.UIElements; 2 | 3 | namespace CleverCrow.Fluid.ElasticInventory.Editors { 4 | public class SearchInput : ComponentBase { 5 | public SearchInput (VisualElement container) : base(container) { 6 | } 7 | 8 | public void BindChange (System.Action callback) { 9 | _container 10 | .Q("search-input__text") 11 | .RegisterValueChangedCallback(evt => { 12 | callback(evt.newValue); 13 | }); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Molecules/SearchInput/SearchInput.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9c1e019e610b4760b08103ddfb46c965 3 | timeCreated: 1687026948 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Molecules/SearchInput/SearchInput.uxml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Molecules/SearchInput/SearchInput.uxml.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3286c8d6a80c4136b7085788ed96667c 3 | timeCreated: 1687027033 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Organisms.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f0de0154cb114d03a31b3ad92e70a2b6 3 | timeCreated: 1685139178 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Organisms/ItemEntry.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c8b9f1d5d48b4d53a28e6e9b15050dd7 3 | timeCreated: 1685139047 -------------------------------------------------------------------------------- /Assets/com.fluid.elastic-inventory/Editor/Components/Organisms/ItemEntry/ItemEntry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEditor; 3 | using UnityEditor.UIElements; 4 | using UnityEngine.UIElements; 5 | 6 | namespace CleverCrow.Fluid.ElasticInventory.Editors { 7 | public class ItemEntry : ComponentBase { 8 | public ItemEntry ( 9 | VisualElement container, 10 | ItemDefinitionBase definition, 11 | Action deleteCallback 12 | ) : base(container) { 13 | var title = _container.Q