XCOM 2
350 ratings
Confirm Free Reload - WotC
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
110.104 KB
5 Feb, 2017 @ 8:51pm
4 Oct, 2017 @ 12:34pm
3 Change Notes ( view )
You need DLC to use this item.

Subscribe to download
Confirm Free Reload - WotC

In 1 collection by BlueRaja
Quality of Life / UI Improvements - WotC
37 items
Description
A simple mod which shows a dialog if you attempt to use a free reload when you still have ammo left.

UPDATED TO SUPPORT WAR OF THE CHOSEN!
For a version that doesn't require War of the Chosen, see here

The only time it makes strategic sense to do that is if you're expecting to shoot twice between turns (eg. Killzone). I've found that most of the time I do it, it's accidental.

Thanks to Robojumper for helping me figure out ability templates.

----------------------------------------------

Compatible with Long War 2!

Classes Overridden (why do I care?):
None!

The source code for all my mods can be found on GitHub[github.com][/i]
[www.paypal.com]
Popular Discussions View All (1)
0
10 Feb, 2019 @ 5:39pm
Simplified Chinese Translation
zxc2008
26 Comments
Dark 11 Jun, 2024 @ 9:34am 
Fix for Insider Knowledge resistance order which boost upgrades. Now mod will shows a dialog when use bonus reload from Insider Knowledge.


private function bool IsLimitedFreeReload()
{
local array<X2WeaponUpgradeTemplate> weaponUpgrades;
local UnitValue numFreeReloadsUsed;
local int numFreeReloadsRemaining, i, TotalFreeReloads;

UnitState.GetUnitValue('FreeReload', numFreeReloadsUsed);

weaponUpgrades = AbilityState.GetSourceWeapon().GetMyWeaponUpgradeTemplates();

for (i = 0; i < weaponUpgrades.Length; i++)
{
if(weaponUpgrades .NumFreeReloads > 0)
{
if (weaponUpgrades .GetBonusAmountFn != none)
{
TotalFreeReloads = weaponUpgrades .GetBonusAmountFn(weaponUpgrades );
numFreeReloadsRemaining = int(TotalFreeReloads - numFreeReloadsUsed.fValue);

if(numFreeReloadsRemaining > 0 && numFreeReloadsRemaining < 10)
{
return true;
}
}
}
}
return false;
}
zin 5 Apr, 2023 @ 11:10am 
Oh yeah, that’s actually a good point. For some reason, I didn’t think of that.
BlueRaja  [author] 3 Apr, 2023 @ 1:14pm 
@zin If you have "free reload anytime" you shouldn't need this mod.
zin 3 Apr, 2023 @ 3:27am 
This mod doesn’t work well with Free Reload Anytime, as it still warns you even if you use the regular reload action if you have free reloads available. A compatability fix would be sweet!
HaziTru 20 Nov, 2022 @ 1:03pm 
Okay
BlueRaja  [author] 20 Nov, 2022 @ 12:47pm 
@HaziTru I'm not certain, but I think so?
HaziTru 20 Nov, 2022 @ 12:42pm 
Controller support?
| grєч wínd | 15 Dec, 2021 @ 8:05pm 
Just a small tip for those who might be bothered by the double space after the first period in the popup message (there are two spaces after, "You have ammo remaining.")

Go to your Steam directory, steamapps\workshop\content\268500\858237491\Localization and open ConfirmFreeReload.int in any text editor like Notepad. Change the line

PopupBody=You have ammo remaining. Are you sure you want to use your free reload?

... or anything you want really. You can customize the popup message entirely to your liking.
Aks 13 Sep, 2021 @ 6:15am 
Russian Localization

UTF-16

ConfirmFreeReload.RUS

[X2TargetingMethod_ConfirmFreeReload]
PopupTitle=Трата свободной перезарядки
PopupBody=У вас остались боеприпасы. Вы уверены, что хотите использовать свободную перезарядку?
AcceptMessage=Перезарядить
CancelMessage=Отмена
Bardagh 23 Mar, 2021 @ 7:02pm 
It's also necessary in order to use abilities which use more than 1 ammo (Saturation Fire and Suppression come to mind).