That's correct! If the changed recipe calls for a total of 2 1/2 cups of flour and sugar combined, and the original recipe uses 2 cups of sugar, then you can deduce that 1/2 cup is for the flour.
So, in the changed recipe, it's likely that the ingredients are adjusted to balance the sweetness and texture. If you need further help or adjustments with the recipe, feel free to ask!