Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
412bf37
Hiro Store Bootstart
DannyIsYog Nov 19, 2025
534cd1e
Populated image mapping correctly
DannyIsYog Nov 20, 2025
968ba1c
Fixed StoreItemView
DannyIsYog Nov 20, 2025
c4cbd6b
Refactor code to remove inventory mentions and SKUs
DannyIsYog Nov 20, 2025
6ae8556
Add lootbox
DannyIsYog Nov 25, 2025
8d66a11
Added lucky chest icon
DannyIsYog Nov 27, 2025
43e04e0
update tab and refresh buttons
trandromeda Dec 5, 2025
a43f8c7
remove unused button handler
trandromeda Dec 5, 2025
198f891
fix coins and gems display bug
trandromeda Dec 5, 2025
d02dd42
standardize store items
trandromeda Dec 5, 2025
c5f7ce2
stylize store item and buttons
trandromeda Dec 5, 2025
2a629a1
rename file
trandromeda Dec 5, 2025
b93544f
update store view
trandromeda Dec 5, 2025
1dc5c09
re-organize tabs
trandromeda Dec 5, 2025
777180b
refactor variable names
trandromeda Dec 8, 2025
b456087
sort currency items
trandromeda Dec 8, 2025
43e6126
refactor and simplify purchase buttons
trandromeda Dec 8, 2025
34dffe3
simplify badge UI
trandromeda Dec 9, 2025
39bf2ba
update store item layout
trandromeda Dec 9, 2025
e609577
update featured item UI
trandromeda Dec 9, 2025
5fdd89c
refactor featured item UI and behaviour
trandromeda Dec 9, 2025
40e9872
refactor economy config to be more consistent
trandromeda Dec 9, 2025
30fbc75
update config item names and update modals
trandromeda Dec 9, 2025
95c4d5b
update all store items to match inventory items
trandromeda Dec 9, 2025
486d949
fix reward modal for item purchases
trandromeda Dec 9, 2025
3fab6ab
display reward from server response
trandromeda Dec 10, 2025
d1d131b
update README asset
trandromeda Dec 10, 2025
a2bac06
add inventory system
trandromeda Dec 10, 2025
e34371e
refactor and update featured item rewards
trandromeda Dec 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
399 changes: 396 additions & 3 deletions Nakama+Hiro/definitions/dev1/base-economy.json

Large diffs are not rendered by default.

258 changes: 258 additions & 0 deletions Nakama+Hiro/definitions/dev1/base-inventory.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,258 @@
{
"items": {
"iron_sword": {
"name": "Iron Sword",
"description": "A sharp sword made of iron.",
"category": "weapons",
"item_sets": ["common_weapons"],
"max_count": 99,
"stackable": false,
"consumable": false,
"string_properties": {
"equipment_slot": "right_hand",
"rarity": "common"
},
"numeric_properties": {
"rank": 1
},
"disabled": false
},
"gold_stack": {
"name": "Gold Stack",
"description": "A stack of golden coins. So shiny!",
"category": "currency",
"max_count": 99,
"stackable": true,
"consumable": true,
"string_properties": {
"rarity": "common"
},
"keep_zero": true,
"consume_reward": {
"guaranteed": {
"currencies": {
"coins": {
"min": 100
}
}
}
}
},
"bomb": {
"name": "Bomb",
"description": "Goes BOOM!",
"category": "weapons",
"max_count": 99,
"stackable": true,
"consumable": true,
"string_properties": {
"rarity": "uncommon"
},
"keep_zero": true,
"consume_reward": {
"guaranteed": {
"currencies": {
"coins": {
"min": 100
}
}
}
}
},
"small_crafting_bag": {
"name": "Small Crafting Bag",
"description": "A small bag of miscellaneous crafting materials.",
"category": "crafting_materials",
"max_count": 99,
"stackable": false,
"consumable": true,
"string_properties": {
"rarity": "uncommon"
},
"consume_reward": {
"max_rolls": 2,
"weighted": [
{
"items": {
"ruby_gem": {
"min": 1,
"max": 3
}
},
"weight": 40
},
{
"currencies": {
"coins": {
"min": 50,
"max": 200,
"multiple": 10
}
},
"weight": 60
}
]
}
},
"wooden_shield": {
"name": "Wooden Shield",
"description": "A basic shield made from reinforced wood.",
"category": "armor",
"item_sets": ["shield", "common_armor"],
"max_count": 99,
"stackable": false,
"consumable": false,
"string_properties": {
"equipment_slot": "left_hand",
"rarity": "common"
},
"numeric_properties": {
"defense": 15,
"block_chance": 10
},
"disabled": false
},
"mana_potion": {
"name": "Mana Potion",
"description": "A vial of blue liquid that restores magical energy.",
"category": "potions",
"item_sets": ["consumables"],
"max_count": 99,
"stackable": true,
"consumable": true,
"string_properties": {
"rarity": "uncommon"
},
"keep_zero": true,
"consume_reward": {
"guaranteed": {
"energies": {
"mana": {
"min": 30,
"max": 60
}
}
}
}
},
"iron_shield": {
"name": "Iron Shield",
"description": "A sturdy shield forged from iron. Provides solid protection.",
"category": "armor",
"item_sets": ["shield", "common_armor"],
"max_count": 99,
"stackable": false,
"consumable": false,
"string_properties": {
"rarity": "rare"
},
"numeric_properties": {
"defense": 25,
"rank": 1
},
"disabled": false
},
"magic_gem": {
"name": "Magic Gem",
"description": "A precious gemstone that radiates magical energy.",
"category": "crafting_materials",
"item_sets": ["materials", "gems"],
"max_count": 5,
"stackable": true,
"consumable": true,
"string_properties": {
"rarity": "epic"
}
},
"golden_key": {
"name": "Golden Key",
"description": "An ornate golden key that opens special treasure chests.",
"category": "keys",
"item_sets": ["special_items"],
"max_count": 9,
"stackable": false,
"consumable": true,
"string_properties": {
"rarity": "rare"
},
"keep_zero": true,
"consume_reward": {
"guaranteed": {
"currencies": {
"coins": {
"min": 500,
"max": 1000,
"multiple": 100
}
}
},
"max_rolls": 1,
"weighted": [
{
"items": {
"ruby_gem": {
"min": 1,
"max": 3
}
},
"weight": 50
},
{
"currencies": {
"gems": {
"min": 10,
"max": 25,
"multiple": 5
}
},
"weight": 50
}
]
}
},
"lucky_charm": {
"name": "Lucky Charm",
"description": "A four-leaf clover that brings good fortune when used.",
"category": "artifacts",
"item_sets": ["consumables", "buffs"],
"max_count": 5,
"stackable": true,
"consumable": true,
"string_properties": {
"rarity": "epic"
},
"keep_zero": false,
"consume_reward": {
"guaranteed": {
"currencies": {
"coins": {
"min": 50,
"max": 150
}
}
}
}
},
"evil_eye": {
"name": "Eye of Sauron",
"description": "It is said to have the power to control the minds of others.",
"category": "artifacts",
"item_sets": ["special_items"],
"max_count": 1,
"stackable": false,
"consumable": false,
"string_properties": {
"rarity": "legendary"
},
"keep_zero": false
}
},
"limits": {
"categories": {
"armor": 10
},
"item_sets": {
"shield": 5
}
}
}
3 changes: 2 additions & 1 deletion Nakama+Hiro/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@ func InitModule(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runti
hiro.WithLeaderboardsSystem(fmt.Sprintf("definitions/%s/base-leaderboards.json", env), true),
hiro.WithChallengesSystem(fmt.Sprintf("definitions/%s/base-challenges.json", env), true),
hiro.WithEconomySystem(fmt.Sprintf("definitions/%s/base-economy.json", env), true),
hiro.WithEventLeaderboardsSystem(fmt.Sprintf("definitions/%s/base-event-leaderboards.json", env), true))
hiro.WithEventLeaderboardsSystem(fmt.Sprintf("definitions/%s/base-event-leaderboards.json", env), true),
hiro.WithInventorySystem(fmt.Sprintf("definitions/%s/base-inventory.json", env), true))
if err != nil {
return err
}
Expand Down
56 changes: 56 additions & 0 deletions UnityHiroStore/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@

# Created by https://www.gitignore.io/api/unity
# Edit at https://www.gitignore.io/?templates=unity

# Jetbrain Rider Cache
.idea/
Assets/Plugins/Editor/JetBrains*

# Visual Studio Code
.vscode/


### Unity ###
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/[Ll]ogs/
/[Uu]ser[Ss]ettings/
Assets/AssetStoreTools*
# Unity local user project setting
UserSettings/

# Visual Studio cache directory
.vs/

# Autogenerated VS/MD/Consulo solution and project files
ExportedObj/
.consulo/
*.csproj
*.unityproj
*.sln
*.suo
*.tmp
*.user
*.userprefs
*.pidb
*.booproj
*.svd
*.pdb
*.opendb
*.VC.db

# Unity3D generated meta files
*.pidb.meta
*.pdb.meta

# Unity3D Generated File On Crash Reports
sysinfo.txt

# Builds
*.apk
*.unitypackage

# End of https://www.gitignore.io/api/unity
8 changes: 8 additions & 0 deletions UnityHiroStore/Assets/UnityHiroStore.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions UnityHiroStore/Assets/UnityHiroStore/Editor.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading