From bbb2dba1ed825c386ec109a2e294662c7d422292 Mon Sep 17 00:00:00 2001 From: Daniel Lovell Date: Tue, 24 Sep 2024 19:38:17 -0700 Subject: [PATCH] Continued Target -> Threat refactor --- Assets/Resources/Prefabs/DroneTarget.prefab | 5 ++++- Assets/Scripts/{Targets.meta => Threats.meta} | 0 Assets/Scripts/{Targets => Threats}/DroneTarget.cs | 0 Assets/Scripts/{Targets => Threats}/DroneTarget.cs.meta | 0 Assets/Scripts/{Targets => Threats}/MissileTarget.cs | 0 Assets/Scripts/{Targets => Threats}/MissileTarget.cs.meta | 0 Assets/Scripts/{Targets => Threats}/Threat.cs | 0 Assets/Scripts/{Targets => Threats}/Threat.cs.meta | 0 .../Configs/Models/{drone_target.json => drone.json} | 0 .../Models/{drone_target.json.meta => drone.json.meta} | 0 docs/Simulation_Config_Guide.md | 4 ++-- 11 files changed, 6 insertions(+), 3 deletions(-) rename Assets/Scripts/{Targets.meta => Threats.meta} (100%) rename Assets/Scripts/{Targets => Threats}/DroneTarget.cs (100%) rename Assets/Scripts/{Targets => Threats}/DroneTarget.cs.meta (100%) rename Assets/Scripts/{Targets => Threats}/MissileTarget.cs (100%) rename Assets/Scripts/{Targets => Threats}/MissileTarget.cs.meta (100%) rename Assets/Scripts/{Targets => Threats}/Threat.cs (100%) rename Assets/Scripts/{Targets => Threats}/Threat.cs.meta (100%) rename Assets/StreamingAssets/Configs/Models/{drone_target.json => drone.json} (100%) rename Assets/StreamingAssets/Configs/Models/{drone_target.json.meta => drone.json.meta} (100%) diff --git a/Assets/Resources/Prefabs/DroneTarget.prefab b/Assets/Resources/Prefabs/DroneTarget.prefab index 59b78d6..01bca3f 100644 --- a/Assets/Resources/Prefabs/DroneTarget.prefab +++ b/Assets/Resources/Prefabs/DroneTarget.prefab @@ -321,8 +321,11 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: _flightPhase: 0 + _velocity: {x: 0, y: 0, z: 0} + _acceleration: {x: 0, y: 0, z: 0} + _dragAcceleration: {x: 0, y: 0, z: 0} _target: {fileID: 0} - staticConfigFile: drone_target.json + staticConfigFile: drone.json --- !u!54 &4451965530778273955 Rigidbody: m_ObjectHideFlags: 0 diff --git a/Assets/Scripts/Targets.meta b/Assets/Scripts/Threats.meta similarity index 100% rename from Assets/Scripts/Targets.meta rename to Assets/Scripts/Threats.meta diff --git a/Assets/Scripts/Targets/DroneTarget.cs b/Assets/Scripts/Threats/DroneTarget.cs similarity index 100% rename from Assets/Scripts/Targets/DroneTarget.cs rename to Assets/Scripts/Threats/DroneTarget.cs diff --git a/Assets/Scripts/Targets/DroneTarget.cs.meta b/Assets/Scripts/Threats/DroneTarget.cs.meta similarity index 100% rename from Assets/Scripts/Targets/DroneTarget.cs.meta rename to Assets/Scripts/Threats/DroneTarget.cs.meta diff --git a/Assets/Scripts/Targets/MissileTarget.cs b/Assets/Scripts/Threats/MissileTarget.cs similarity index 100% rename from Assets/Scripts/Targets/MissileTarget.cs rename to Assets/Scripts/Threats/MissileTarget.cs diff --git a/Assets/Scripts/Targets/MissileTarget.cs.meta b/Assets/Scripts/Threats/MissileTarget.cs.meta similarity index 100% rename from Assets/Scripts/Targets/MissileTarget.cs.meta rename to Assets/Scripts/Threats/MissileTarget.cs.meta diff --git a/Assets/Scripts/Targets/Threat.cs b/Assets/Scripts/Threats/Threat.cs similarity index 100% rename from Assets/Scripts/Targets/Threat.cs rename to Assets/Scripts/Threats/Threat.cs diff --git a/Assets/Scripts/Targets/Threat.cs.meta b/Assets/Scripts/Threats/Threat.cs.meta similarity index 100% rename from Assets/Scripts/Targets/Threat.cs.meta rename to Assets/Scripts/Threats/Threat.cs.meta diff --git a/Assets/StreamingAssets/Configs/Models/drone_target.json b/Assets/StreamingAssets/Configs/Models/drone.json similarity index 100% rename from Assets/StreamingAssets/Configs/Models/drone_target.json rename to Assets/StreamingAssets/Configs/Models/drone.json diff --git a/Assets/StreamingAssets/Configs/Models/drone_target.json.meta b/Assets/StreamingAssets/Configs/Models/drone.json.meta similarity index 100% rename from Assets/StreamingAssets/Configs/Models/drone_target.json.meta rename to Assets/StreamingAssets/Configs/Models/drone.json.meta diff --git a/docs/Simulation_Config_Guide.md b/docs/Simulation_Config_Guide.md index 14b4e34..bd1448c 100644 --- a/docs/Simulation_Config_Guide.md +++ b/docs/Simulation_Config_Guide.md @@ -14,7 +14,7 @@ The main configuration files you will work with are located in the `Assets/Strea - **Model Configurations** (found in `Assets/StreamingAssets/Configs/Models/`): - **`micromissile.json`** - **`hydra70.json`** - - **`drone_target.json`** + - **`drone.json`** - **C# Script**: [`StaticConfig.cs`](Assets/Scripts/Config/StaticConfig.cs) ### File Locations @@ -202,7 +202,7 @@ The `Models` directory contains the following default model configurations: - **`micromissile.json`** - **`hydra70.json`** -- **`drone_target.json`** +- **`drone.json`** These JSON files serve as templates and can be tweaked to modify the behavior of the corresponding models.