mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-29 07:21:54 +08:00
ac7183e78b
- 在ItemStore.gd中添加SOUL物品类型及其映射 - 在EntityBase.gd中为物品栏添加SOUL类型及其上限 - 新增灵魂物品的SVG图标及导入配置 - 为角色(KukeMC, Bear, Chick)添加灵魂掉落配置 - 在武器卡片界面添加灵魂提炼和镶嵌按钮
27 lines
558 B
GDScript
27 lines
558 B
GDScript
@tool
|
|
class_name ItemStore
|
|
|
|
enum ItemType {
|
|
BASEBALL,
|
|
BASKETBALL,
|
|
APPLE,
|
|
BEACHBALL,
|
|
SOUL,
|
|
}
|
|
static var nameMap = {
|
|
ItemType.BASEBALL: "棒球",
|
|
ItemType.BASKETBALL: "篮球",
|
|
ItemType.APPLE: "苹果",
|
|
ItemType.BEACHBALL: "沙滩球",
|
|
ItemType.SOUL: "灵魂",
|
|
}
|
|
static var idMap = {
|
|
ItemType.BASEBALL: "baseball",
|
|
ItemType.BASKETBALL: "basketball",
|
|
ItemType.APPLE: "apple",
|
|
ItemType.BEACHBALL: "beachball",
|
|
ItemType.SOUL: "soul",
|
|
}
|
|
static func getTexture(type: ItemType) -> Texture2D:
|
|
return load("res://resources/items/%s.svg" % idMap[type])
|