Weapon that scales with variable.

So in my game there are two variables named hatred and love which are added to or subtracted from depending on what the player chooses to do in different situations.
Now here is what I want to do: I want to make a weapon which "scales" with one of these variables, something like weapondamage 200 + (hatevalue).

Does anyone know how to make this work?
You can put variables in the damage formula as v[X]. So 200 + v[X].
That was simple! Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/weapon-that-scales-with-variable.160481/