20 lines
512 B
C#
20 lines
512 B
C#
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
// 定义装备类
|
|
[CreateAssetMenu(fileName = "New Equipment", menuName = "Inventory/Equipment")]
|
|
public class Equipment : ScriptableObject
|
|
{
|
|
public string equipmentName; // 装备名称
|
|
public EquipmentType equipmentType; // 装备类型(头部、身体、手部、腿部)
|
|
public List<GameObject> equipmentPrefab; // 装备对应的预制体
|
|
}
|
|
|
|
// 定义装备类型枚举
|
|
public enum EquipmentType
|
|
{
|
|
Head,
|
|
Body,
|
|
Hand,
|
|
Leg
|
|
} |