The GetPlayerStats edit wouldn’t - it only prevents stats from going negative and causing an overflow.
Are badgepoints going to 1 because you’re subtracting more than you have? I dunno - maybe you only have few badgepoints.
Here’s a more efficient alternative to what I first posted. Wherever you see a stat requirement, replace it with this. I’m assuming you’ll never have 0 in a stat, and if you did you would never be able to equip anything with this code (a simple one-line fix to check, but what’s the point if it’s never needed). If the Add_Stat array is type long this should work.
' stat requirements
For i = 1 To Stats.Stat_Count - 1
If GetPlayerRawStat(index, i) < Item(itemnum).Stat_Req(i) Then
PlayerMsg index, "You do not meet the stat requirements to equip this item.", BrightRed
If GetPlayerRawStat(index, i) + Item(itemnum).Add_Stat(i) < 1 Then
PlayerMsg index, "That would drain all your stats!", BrightRed
If that doesn’t work, run a breakpoint to read the values of Item(itemnum).Add_Stat(i) and GetPlayerRawStat(index,i).