0
0
mirror of https://github.com/sp-tarkov/modules.git synced 2025-02-12 22:30:44 -05:00
DanW af96c37815 IsEnemyPatch Improvements (!156)
Revised `IsEnemyPatch` with the following changes:
* Added a check to see if the player is in the group's `Allies` collection (needed for mod support)
* Added a check to see if the player is in the group (possibly needed for future mod support)
* Fixed Zryachiy check (and added his followers) by allowing the EFT method to run for them
* Refactoring for clarity and to reorder the checks based on priority:
    1) Null check(s)
    2) Check if the player is in the group or in its `Allies` or `Enemies` collections
    3) Allow the EFT method to run for certain bot roles
    4) Finally, add the player to the group's `Enemies` collection if needed

**This is a big change, so please double-check my work!** I tested this in multiple raids, in several maps, with and without SAIN, and I didn't find any issues.

Reviewed-on: SPT/Modules#156
Co-authored-by: DanW <danw@noreply.dev.sp-tarkov.com>
Co-committed-by: DanW <danw@noreply.dev.sp-tarkov.com>
2024-08-15 08:45:47 +00:00
..
2024-05-21 19:10:17 +01:00
2024-05-21 19:10:17 +01:00
2024-07-25 21:58:35 +00:00
2024-05-21 19:10:17 +01:00
2024-05-21 19:10:17 +01:00
2024-05-21 19:10:17 +01:00
2023-03-03 18:52:31 +00:00