Add buff to specific actor

Is there a way (plugin command or script) to add a buff to a specific actor?
What are you trying to achieve? Is this through a plugin or event?
In a battle event, I just want to add a buff to a character.
Buffs are only available as a skill effect, not as an event command.
That means you have to use force action command with a skill that gives the buff on the intended target.

Force action can only be targeted at party index, not at actor ID. So you need to determine which slot the actor is in first, and then use the force action for that slot.

depending on what exactly you want to do that troop event can be a bit tricky, but is doable
So what actually are you trying to set up? Because you could just use the Change State commend if it's through the battle event.
you can use YEP_Buff&StateCore to add it in battle, probably you need passive states as well
if its for battle.
Because you could just use the Change State commend
he wants to add a buff, not a state. That is a difference because in the default engine the buff can be stacked two times, but the state not. And as I wrote above there is no event command to add a buff.
you can use YEP_Buff&StateCore to add it in battle, probably you need passive states as well
if its for battle.

I looked into and I don't think it offers functions to just add a buff.
You can call this function:

Code:
Game_Battler.prototype.addBuff = function(paramId, turns) {
    if (this.isAlive()) {
        this.increaseBuff(paramId);
        if (this.isBuffAffected(paramId)) {
            this.overwriteBuffTurns(paramId, turns);
        }
        this._result.pushAddedBuff(paramId);
        this.refresh();
    }
};

The way to do it will depend on the context from which you call it. Assuming from an event script command:

Code:
$gameActors.actor(actorId).addBuff(paramId,turns) //actor by id
$gameParty.members()[memberIndex].addBuff(paramId,turns) //party mmeber by index
$gameTroop.members()[memberIndex].addBuff(paramId,turns) //enemy by index

No need for a specific plugin.

Use this one for debuffs:
Code:
Game_Battler.prototype.addDebuff = function(paramId, turns) {
    if (this.isAlive()) {
        this.decreaseBuff(paramId);
        if (this.isDebuffAffected(paramId)) {
            this.overwriteBuffTurns(paramId, turns);
        }
        this._result.pushAddedDebuff(paramId);
        this.refresh();
    }
};

These are all default functions of the engine.
That worked beautifully.

Original thread: https://forums.rpgmakerweb.com/threads/add-buff-to-specific-actor.119351/