-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSelectedSound.cs
More file actions
47 lines (42 loc) · 1.59 KB
/
SelectedSound.cs
File metadata and controls
47 lines (42 loc) · 1.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
namespace CustomSound;
/// <summary>
/// 随机选择的声音载体类,用于存储从SoundGroup中随机选择的一个声音及其相关信息
/// </summary>
/// <remarks>
/// 此类作为SoundGroup的随机载体,包含从声音组中随机选择的单个声音的属性:
/// <list type="number">
/// <item>声音组名称(用于标识和调试)</item>
/// <item>单个声音文件路径</item>
/// <item>单个气泡文本</item>
/// <item>声音传播半径</item>
/// </list>
/// 通常由SoundGroupRandomSelector类使用,用于表示随机选择的结果。
/// </remarks>
class SelectedSound
{
/// <summary>
/// 声音组的名称,用于标识和调试(可选)
/// </summary>
/// <value>默认值为空字符串</value>
public string? Name { get; set; }
/// <summary>
/// 随机选择的声音文件路径
/// </summary>
/// <value>默认值为空字符串</value>
public string? Sound { get; set; }
/// <summary>
/// 与声音关联的气泡文本
/// </summary>
/// <value>默认值为空字符串</value>
public string? Text { get; set; }
/// <summary>
/// 声音类型,定义该声音的行为和属性
/// </summary>
/// <value>默认值为SoundTypes.unknowNoise,表示未知噪声类型</value>
public SoundTypes SoundType { get; set; } = SoundTypes.unknowNoise;
/// <summary>
/// 声音传播半径,定义该声音能传播的距离
/// </summary>
/// <value>默认值为15f,表示声音传播半径为15个单位</value>
public float Radius { get; set; } = 15f;
}