first commit
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using OTGIntegrated.Items;
|
||||
using UnityEngine;
|
||||
|
||||
namespace OTGIntegrated.Quests
|
||||
{
|
||||
[Serializable]
|
||||
public sealed class QuestRewardItem
|
||||
{
|
||||
public ItemData item;
|
||||
[Min(1)] public int amount = 1;
|
||||
}
|
||||
|
||||
[CreateAssetMenu(fileName = "QuestData", menuName = "OTG Integrated/Quest Data")]
|
||||
public sealed class QuestData : ScriptableObject
|
||||
{
|
||||
public string questId;
|
||||
public string displayName;
|
||||
[TextArea(3, 7)] public string description;
|
||||
public string giverNpcId;
|
||||
public string turnInNpcId;
|
||||
public List<QuestGoal> goals = new List<QuestGoal>();
|
||||
[Min(0)] public int rewardExperience;
|
||||
[Min(0)] public int rewardTalentPoints;
|
||||
public List<QuestRewardItem> rewardItems = new List<QuestRewardItem>();
|
||||
|
||||
private void OnValidate()
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(questId))
|
||||
{
|
||||
questId = name;
|
||||
}
|
||||
|
||||
if (string.IsNullOrWhiteSpace(displayName))
|
||||
{
|
||||
displayName = questId;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user