Versions / 0.6.0-pre.9.1 / NPC / Roles / Intelligent / Neutral / Kweebec / Component_Kweebec_Instruction_Search.json
Component_Kweebec_Instruction_Search
Server/NPC/Roles/Intelligent/Neutral/Kweebec/Component_Kweebec_Instruction_Search.json, 3.5 KB
Fields
| Field | Type |
|---|---|
Class | string |
Parameters | object |
Content | object |
Type | string |
Source
{
"Class": "Instruction",
"Parameters": {
"_ImportStates": [ "Alerted", "Attack", "Search", "Idle" ],
"ViewRange": {
"Value": 15,
"Description": "View range"
},
"ViewSector": {
"Value": 180,
"Description": "View sector"
},
"HearingRange": {
"Value": 10,
"Description": "Hearing range"
},
"AlertedRange": {
"Value": 30,
"Description": "A range within which the player can be seen/sensed when the NPC is alerted to their presence"
}
},
"Content": {
"Instructions": [
{
"$Comment": "Animations",
"Continue": true,
"Sensor": {
"Type": "Any",
"Once": true
},
"Actions": [
{
"Type": "PlayAnimation",
"Slot": "Status"
},
{
"Type": "SpawnParticles",
"Offset": [ 0, 2.1, 0 ],
"ParticleSystem": "Question"
}
]
},
{
"Reference": "Component_Instruction_Damage_Check",
"Modify": {
"_ExportStates": [ "Attack", "Search" ],
"AlertedRange": { "Compute": "AlertedRange" }
}
},
{
"Sensor": {
"Type": "Beacon",
"Message": "Feran_All_Attack",
"TargetSlot": "LockedTarget"
},
"Actions": [
{
"Type": "ParentState",
"State": "Attack"
}
]
},
{
"Sensor": {
"Type": "Or",
"Sensors": [
{
"Reference": "Component_Sensor_Sight_By_Attitude",
"Modify": {
"ViewRange": { "Compute": "AlertedRange" },
"ViewSector": { "Compute": "ViewSector" },
"Attitudes": [ "Hostile", "Neutral" ]
}
},
{
"Reference": "Component_Sensor_Sound_By_Attitude",
"Modify": {
"HearingRange": { "Compute": "HearingRange" },
"Attitudes": [ "Hostile", "Neutral" ]
}
}
]
},
"Actions": [
{
"Type": "ParentState",
"State": "Alerted"
}
]
},
{
"ActionsAtomic": true,
"Actions": [
{
"Type": "Timeout",
"Delay": [ 7, 10 ]
},
{
"Type": "ParentState",
"State": "Idle"
}
],
"BodyMotion": {
"Type": "Sequence",
"Motions": [
{
"Type": "Timer",
"Time": [ 2, 3 ],
"Motion": {
"Type": "Wander",
"MaxHeadingChange": 1,
"RelativeSpeed": 0.6
}
},
{
"Type": "Sequence",
"Looped": true,
"Motions": [
{
"Type": "Timer",
"Time": [ 1, 2 ],
"Motion": {
"Type": "WanderInCircle",
"Radius": 5,
"MaxHeadingChange": 60,
"RelativeSpeed": 0.6
}
},
{
"Type": "Timer",
"Time": [ 1, 2 ],
"Motion": {
"Type": "Nothing"
}
}
]
}
]
}
}
]
},
"Type": "Component"
}