chore: initial commit
This commit is contained in:
0
Assets/Scripts/Dialogue/.gitkeep
Normal file
0
Assets/Scripts/Dialogue/.gitkeep
Normal file
16
Assets/Scripts/Dialogue/BaseGames.Dialogue.asmdef
Normal file
16
Assets/Scripts/Dialogue/BaseGames.Dialogue.asmdef
Normal file
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"excludePlatforms": [],
|
||||
"allowUnsafeCode": false,
|
||||
"precompiledReferences": [],
|
||||
"name": "BaseGames.Dialogue",
|
||||
"defineConstraints": [],
|
||||
"noEngineReferences": false,
|
||||
"versionDefines": [],
|
||||
"rootNamespace": "BaseGames.Dialogue",
|
||||
"references": [
|
||||
"BaseGames.Core.Events"
|
||||
],
|
||||
"autoReferenced": true,
|
||||
"overrideReferences": false,
|
||||
"includePlatforms": []
|
||||
}
|
||||
7
Assets/Scripts/Dialogue/BaseGames.Dialogue.asmdef.meta
Normal file
7
Assets/Scripts/Dialogue/BaseGames.Dialogue.asmdef.meta
Normal file
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: bd8344dc5b8343745a71a109668ac156
|
||||
AssemblyDefinitionImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
23
Assets/Scripts/Dialogue/DialogueDataSO.cs
Normal file
23
Assets/Scripts/Dialogue/DialogueDataSO.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace BaseGames.Dialogue
|
||||
{
|
||||
/// <summary>
|
||||
/// 对话数据 ScriptableObject(存根)。
|
||||
/// Phase 3 Dialogue 模块实现时填充完整字段(对话行、Speaker、选项分支等)。
|
||||
/// 此处仅声明类型,供 DialogueEventChannelSO 引用。
|
||||
/// </summary>
|
||||
[CreateAssetMenu(menuName = "Dialogue/DialogueData")]
|
||||
public class DialogueDataSO : ScriptableObject
|
||||
{
|
||||
[Tooltip("对话资产的唯一标识符,对应存档中 NPC 对话进度记录。")]
|
||||
public string dialogueId;
|
||||
|
||||
[Tooltip("对话参与者名称(用于 HUD 说话人名牌)。")]
|
||||
public string speakerName;
|
||||
|
||||
[TextArea(3, 8)]
|
||||
[Tooltip("Phase 3 前的占位文本;正式内容在 DialogueLineSO[] 中定义。")]
|
||||
public string placeholderText;
|
||||
}
|
||||
}
|
||||
11
Assets/Scripts/Dialogue/DialogueDataSO.cs.meta
Normal file
11
Assets/Scripts/Dialogue/DialogueDataSO.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: eaa9eb52b2d83984ebfb2f7189e4f3f8
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
14
Assets/Scripts/Dialogue/DialogueEventChannelSO.cs
Normal file
14
Assets/Scripts/Dialogue/DialogueEventChannelSO.cs
Normal file
@@ -0,0 +1,14 @@
|
||||
using BaseGames.Core.Events;
|
||||
using UnityEngine;
|
||||
|
||||
namespace BaseGames.Dialogue
|
||||
{
|
||||
/// <summary>
|
||||
/// 对话请求事件频道(EVT_DialogueStartRequest)。
|
||||
/// ⚠️ 负载为 DialogueDataSO(SO 引用),不是 struct,避免序列化开销。
|
||||
/// 发布:NpcInteractable(玩家触发互动)、CutsceneTrigger
|
||||
/// 订阅:DialogueController(弹出对话 UI 并开始播放)
|
||||
/// </summary>
|
||||
[CreateAssetMenu(menuName = "Events/Dialogue/DialogueStartRequest")]
|
||||
public class DialogueEventChannelSO : BaseEventChannelSO<DialogueDataSO> { }
|
||||
}
|
||||
11
Assets/Scripts/Dialogue/DialogueEventChannelSO.cs.meta
Normal file
11
Assets/Scripts/Dialogue/DialogueEventChannelSO.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4929240a254c7d9418b239971866e6af
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user