I have setup an ability point system to level up my abilities. The Ability Points are an experience status value that is awarded every level. When enough points are earned, they can be spent to raise the rank of an ability (stealth, lockpick, etc).
I have also setup a menu screen to display these abilities, with "Level Up" as the default action. I can navigate this menu and, if I have enough points, I can level up the ability.
My problem here is that, so long as I have the minimum points, I can level up every ability - despite the level up being configured for 'Spend." If it costs 3 points to get a new level of Lockpick and Stealth, and I have 3 points, I can level up both of these abilities.
How do I make it so, when you level up one ability, it subtracts those points from the status value?