MV script line to "manually" add a buff to a character?

As the title says. Thanks in advance for any suggestion!
battler.addBuff(buffId, turns);
character.addBuff(STAT_ID, TURN_DURATION)
STAT_ID = 0: max hp
STAT_ID = 1: max mp
STAT_ID = 2: attack
STAT_ID = 3: defence
STAT_ID = 4: magic
STAT_ID = 5: magic defence
STAT_ID = 6: agility
STAT_ID = 7: luck

Depending on who that character is, you can access it with $gameActors.actor(ACTOR_ID), $gameParty.members()[INDEX_IN_THE_PARTY] or $gameTroop.members()[INDEX_IN_THE_TROOP].
Note that those index start at 0.

Original thread: https://forums.rpgmakerweb.com/threads/script-line-to-manually-add-a-buff-to-a-character.164783/