Having a state check which actor it is affecting? Is my syntax wrong?

Using Yanfly's Buffs and States Core for this. I want a state, when applied to or removed from an actor, to change a particular variable based on which actor it is on. My current notetag:

Code:
<Custom Apply Effect>
if (user.actorId == 1) {
$gameVariables.setValue (302, $gameVariables.value (302)+10)
}else if (user.actorId == 2) {
$gameVariables.setValue (312, $gameVariables.value (312)+10)
}else if (user.actorId == 3) {
$gameVariables.setValue (322, $gameVariables.value (322)+10)
}else{
$gameVariables.setValue (332, $gameVariables.value (332)+10)
}
</Custom Apply Effect>
<Custom Remove Effect>
if (user.actorId == 1) {
$gameVariables.setValue (302, $gameVariables.value (302)-10)
}else if (user.actorId == 2) {
$gameVariables.setValue (312, $gameVariables.value (312)-10)
}else if (user.actorId == 3) {
$gameVariables.setValue (322, $gameVariables.value (322)-10)
}else{
$gameVariables.setValue (332, $gameVariables.value (332)-10)
}
</Custom Remove Effect>

This doesn't seem to be working, though. When the state is on actor 1 (confirmed that it is, the little state icon is present and the state's other effects are working), the variable 302 remains unchanged.

Is the term "user.actorId" not correct for states? That was my initial thought but it seems to me that if that were the case, it would run through the conditional branches and then edit variable 332 (since none of the If clauses would read as true), but variable 332 remains unchanged too. Which leads me to think that there might be a syntax problem....
Change user.actorId to user.actorId().
and you should not place a space between a function and its arguments

NOT
$gameVariables.value (302)

Better
$gameVariables.value(302)
Even having done that, it doesn't work, and I think I know why. It's a passive state applied by attaching a weapon augment, and passive states apparently don't work with "custom apply effect" tags. Sadly, because this would solve the final outstanding issue in my game design, I think... at least currently. Lol

Original thread: https://forums.rpgmakerweb.com/threads/having-a-state-check-which-actor-it-is-affecting-is-my-syntax-wrong.81754/