diff --git a/Assets/Scriptables/HeroParty.asset b/Assets/Scriptables/HeroParty.asset new file mode 100644 index 0000000..c4217c1 --- /dev/null +++ b/Assets/Scriptables/HeroParty.asset @@ -0,0 +1,15 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f0603cf6e7f1d884e89c3eb6a478a96c, type: 3} + m_Name: HeroParty + m_EditorClassIdentifier: + unitList: [] diff --git a/Assets/Scriptables/HeroParty.asset.meta b/Assets/Scriptables/HeroParty.asset.meta new file mode 100644 index 0000000..e108458 --- /dev/null +++ b/Assets/Scriptables/HeroParty.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c9a46588e6ec04d4d91bb80fdffd7869 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/HeroPartySO.cs b/Assets/Scripts/HeroPartySO.cs new file mode 100644 index 0000000..4a47ae9 --- /dev/null +++ b/Assets/Scripts/HeroPartySO.cs @@ -0,0 +1,15 @@ +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using UnityEngine; + +[CreateAssetMenu(fileName = "HeroParty", menuName = "Hero Party")] +public class HeroPartySO : ScriptableObject +{ + [SerializeField] + private List unitList = new List(); + public ReadOnlyCollection UnitList => unitList.AsReadOnly(); + + public void Add(HeroUnit unit) { unitList.Add(unit); } + public void Remove(HeroUnit unit) { unitList.Remove(unit); } +} diff --git a/Assets/Scripts/HeroPartySO.cs.meta b/Assets/Scripts/HeroPartySO.cs.meta new file mode 100644 index 0000000..3898e62 --- /dev/null +++ b/Assets/Scripts/HeroPartySO.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: f0603cf6e7f1d884e89c3eb6a478a96c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: