All right, so this might get a bit confusing because the command is huge, and it's connected to other commands, but I'll try my best to explain it...
This here was the original command, it worked for a couple weeks before the latest patch:
@if@[>=||@calc@[+|@if@[@readfile@[@user@armor.txt]||||0||@readfile@[@user@armor.txt]]|@calc@[+|@if@[@readfile@[@user@weapon.txt]||||0||@readfile@[@user@weapon.txt]]|@calc@[+|@rand@[0|@target@[1]]|@calc@[+|@points@|@calc@[+|@calc@[/|@if@[@readfile@[@user@prof.txt]||||0||@readfile@[@user@prof.txt]]|5]|@calc@[*|@streamrank@|@streamrank@]]]]]]||@target@[2]||@user@ has defeated the @target@[6]! @if@[>=||@points@||@target@[3]||||@exec@[0,!battleRewards @target@[4] @target@[7]]]||The @target@[6] has slain @user@!@editpoints@[@user@|@target@[5]]]
So this is the 'combat' system of an RPG mini-game I've been working on. Basically it adds a bunch of things together to get your combat rating such as level, armor, weapon, battleproficiency, and rank. It compares this to Target[2] which is the number you need to beat to kill the enemy. Target[1] is a random number attached to make sure you don't always lose/win every fight against that enemy. Target[3] is the level at which you stop gaining rewards from fighting that enemy. Target[4] is how many levels you gain for winning. Target[5] is how many levels you lose when you're defeated by the enemy. Target[6] is the enemy's name, and Target[7] is how much gold you earn.
I started stripping the command down piece by piece to see what was causing the problem, and I eventually got it to work like this:
@if@[>||@points@||@target@[2]||@user@ has defeated the @target@[6]! @if@[>=||@points@||99999||||@exec@[0,!battleRewards @target@[4] @target@[7]]]||The @target@[6] has slain @user@!@editpoints@[@user@|@target@[5]]]
But it only works when the player's overall combat level is simply @points@, no adding weapon power, armor power, ranking, battleproficiency, etc to it. It only works if it's simply @points@ compared to Target[2].