Brahmos and 1_salvo_4_sfrj_10_brahmos config #12
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes significant changes to the
DirectAttackBehavior
class, enhancements to the interceptor's boost and mid-course update methods, and the addition of new configuration files and tests. The most important changes include refactoring theDirectAttackBehavior
class, improving the interceptor's acceleration logic, adding new configuration files for missile behaviors, and introducing new tests for behavior validation.Refactoring and Logic Improvements:
Assets/Scripts/Behavior/DirectAttackBehavior.cs
: Refactored theDirectAttackBehavior
class to improve readability and logic for waypoint selection. Waypoints are now sorted in descending order based on distance, and the logic for determining the next waypoint has been streamlined.Assets/Scripts/Interceptor.cs
: Enhanced the interceptor's boost and mid-course update methods by adding proportional navigation acceleration and improving the calculation of total acceleration. [1] [2]Configuration Files:
Assets/StreamingAssets/Configs/1_salvo_4_sfrj_10_brahmos.json
: Added a new configuration file defining the parameters for a salvo of interceptors and threats, including their initial states and dynamic configurations.Assets/StreamingAssets/Configs/Behaviors/Attack/brahmos_direct_attack.json
: Introduced a new attack behavior configuration for the Brahmos missile, specifying its flight plan and target parameters.Assets/StreamingAssets/Configs/Models/Threats/brahmos.json
: Added a new configuration file for the Brahmos cruise missile, detailing its physical and performance characteristics.Testing:
Assets/Tests/EditMode/BehaviorTests.cs
: Added new unit tests to validate theDirectAttackBehavior
class, ensuring correct waypoint selection and behavior under various conditions.These changes collectively enhance the functionality and maintainability of the codebase, improve the interceptor's performance, and ensure the correctness of new behaviors through comprehensive testing.