enragedpixel / Carry-Stacker-Reloaded

Payday 2 BLT Mod
37 stars 15 forks source link

Lost bag when enabling/disabling the mod from the mod's menu #23

Open m-alorda opened 3 years ago

m-alorda commented 3 years ago

Issue: Disable the mod from the mod's menu Pick a bag Enable the mod from the mod's menu Pick a bag Drop a bag: Only one bag can be dropped. The first one is lost

Crash log: Not applicable

Mods running: CarryStackerReloaded WolfHUD Iter BeardLib

System information: Not applicable

m-alorda commented 3 years ago

Two ideas on how to solve it:

When enabling the mod, if the player check if the player is carrying a bag.

1 - If the player is already carrying a bag, the mod should remain in a new state "being activated", in which the player will not be able to pick any new bags. When the bag is dropped, the mod will be activated. In this case, a chat message should probably be shown to the user, explaining this situation.

2 - If the player is already carrying a bag, request the current bag being carried and add it to the mod's stack