I didn't keep in mind that 'ShouldReaquire' handles both the initial check for acquiring of a file and also the re-acquiring of it, I've renamed the method here to be more accurate in this behavior so that hopefully it prevents this from happening again in the future.
Also fixes the issue of an exception being thrown when checking if the bundle exists or not.
Thanks to MadByte for finding this issue
Reviewed-on: SPT/Modules#160
Co-authored-by: Archangel <jesse@archangel.wtf>
Co-committed-by: Archangel <jesse@archangel.wtf>
* Bug fix for getting negative Lightkeeper rep and disabling your transmitter only when killing Zryachiy, not his followers
* Revised the class to support multiple players having access to the island, not only the main player
* Added support for having multiple Lightkeeper-friendly PMC's on the island (currently requires mod support). Killing one of them while on the island will also result in getting reduced Lightkeeper rep and disabling your transmitter.
* Separated location changes into discrete methods and made them public so mods can call them individually
* Added static property that determines if the main player's transmitter status should open the island for everyone on the map. Also added property indicating if the island has been opened for everyone. This allows mods to override SPT's behavior and not have the island opened to everyone if the main player has access.
* Rewrote the class so that the cyclic `Update()` method is no longer needed
Co-authored-by: chomp <chomp@noreply.dev.sp-tarkov.com>
Reviewed-on: SPT/Modules#159
Co-authored-by: dwesterwick <dwesterwick@yahoo.com>
Co-committed-by: dwesterwick <dwesterwick@yahoo.com>
Made the following changes to !156:
* Replaced `IsNullOrEmpty()` EFT checks with basic null checks
* Replaced `Any()` with new helper method to check if bots exist in collections
Reviewed-on: SPT/Modules#157
Co-authored-by: dwesterwick <dwesterwick@yahoo.com>
Co-committed-by: dwesterwick <dwesterwick@yahoo.com>
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>
Currently, the system knows which bundles are incorrect and attempts to re-download the correct ones.. However, upon next re-launch those bundles will again be invalid probably due to it not actually writing to them forcing the system to keep re-downloading.
This fixes it by removing the invalid bundle, then re-downloading the proper one.
Reviewed-on: SPT/Modules#155
Co-authored-by: Archangel <jesse@archangel.wtf>
Co-committed-by: Archangel <jesse@archangel.wtf>
Added null check for `damageInfo.Weapon.Name` in `DogtagPatch::UpdateDogtagItemWithDeathDetails` because it can be null in rare cases. I see this happen when Zryachiy or his followers kill a bot, and I'm not sure why. This will prevent an exception from being thrown and the bot becoming "broken".
Reviewed-on: SPT/Modules#154
Co-authored-by: dwesterwick <dwesterwick@yahoo.com>
Co-committed-by: dwesterwick <dwesterwick@yahoo.com>
Was missing checks that now exist in the client, works as intended now from my testing. Please test and confirm as well.
**Note**: I strongly believe that this patch is now redundant and can be removed, I am still testing to see if this is the case.
Co-authored-by: Lacyway <20912169+Lacyway@users.noreply.github.com>
Reviewed-on: SPT/Modules#153
Co-authored-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
Co-committed-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
Some patches are `internal` that should be `public` so that mods can disable them when altering AI.
Co-authored-by: Lacyway <20912169+Lacyway@users.noreply.github.com>
Reviewed-on: SPT/Modules#152
Co-authored-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
Co-committed-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
Fixes a duplicate set of logging requests sent to the server for no reason.
Co-authored-by: Cj <161484149+CJ-SPT@users.noreply.github.com>
Reviewed-on: SPT/Modules#151
Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com>
Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>
- Fixes problems with `GUI.skin`
- More efficient code
No longer breaks other IMGUI elements from my testing as the `GUIStyle` is isolated. Please test with SAIN and other possible mods.
Co-authored-by: Lacyway <20912169+Lacyway@users.noreply.github.com>
Reviewed-on: SPT/Modules#148
Co-authored-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
Co-committed-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
Renamed a few things to make it easier to read. Use role instead of side to know if they are pmcs. Cant test since one of patches fail due to remapping should be ok
Reviewed-on: SPT/Modules#145
Co-authored-by: Kaeno <kaeno@noreply.dev.sp-tarkov.com>
Co-committed-by: Kaeno <kaeno@noreply.dev.sp-tarkov.com>
In the end, Kaeno's fix by changing the main client collider's layer to `HighPolyCollider` is the only way I could fix it.
Also made changes to avoid unnecessary physics collisions between other BTR colliders; these physics collisions can cause FPS drops especially for lower end PCs so this should provide a slight performance gain for them.
I left in the commented-out collision debugger script I made to log collisions in case it's useful for future debugging purposes.
Reviewed-on: SPT/Modules#142
Co-authored-by: Nympfonic <arys.steam@gmail.com>
Co-committed-by: Nympfonic <arys.steam@gmail.com>
This gives users feedback that the game is currently loading bundles, which prevents confusion when a large amount of them are being loaded and the game is "seemingly" infinitely loading.
The implementation is very bare bones, feel free to modify it to your liking if you want it to use a more fancy user interface. I went for clarity (black background, white text). With the standard `OnGUI` skin it's very hard to discern the text.
Tested on 1440p and 1080p.
![image](/attachments/31a818d6-d101-4e5d-a2c5-541c8b48ba71)
Co-authored-by: Lacyway <20912169+Lacyway@users.noreply.github.com>
Reviewed-on: SPT/Modules#140
Co-authored-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
Co-committed-by: Lacyway <lacyway@noreply.dev.sp-tarkov.com>
I've done testing to ensure the player can't phase through the BTR as well.
Have not tested anything else besides that.
Reviewed-on: SPT/Modules#139
Co-authored-by: Nympfonic <arys.steam@gmail.com>
Co-committed-by: Nympfonic <arys.steam@gmail.com>
No more having to update the method name
Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: SPT/Modules#138
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>