Different cast animation for simple attack and skills

Hi there,

I am using Victor Engines battle plugins (BasicModule, ActiveTimeBattle, BattleMotions, BattlerGraphicSetup). The reason therefor is the single big ATB bar where I can see all actors.

Now there is the possibility to add the following statement to skills:

<cast speed: 600, agi>

Doing so before executing the skill the actor hast to wait a certain time until he can execute the skill. The ATB bar shows this process (that's exactly what I like). Now I want this waiting process not only for skills like magic, but also for the simple 'attack' skill. However I want to see a different motion while the character is casting the 'attack'.
-> currently I see the characters 'Chant Motion' (name in the BattlerGraphicSetup) while he is doing skills and while he only deals a normal 'attack'. But I want to see for example the 'Idle Motion' (name in the BattlerGraphicSetup) while he is casting the normal 'attack'.

Hope I explained well and somebody can help me 🙂

Thanks,
Chris

I've moved this thread to Plugin Support. Thank you.

Solved by myself, I post my code here, maybe it helps somebody.. :

You need to replace the 'Sprite_Battler.prototype.startMotion' function in the VE_BattlerGraphicSetup like in the following:

Sprite_Battler.prototype.startMotion = function(motionType) {
var newMotion = this.getMotions(motionType, true);
var oldMotion = this._motion || {};
if (oldMotion !== newMotion || this._playMotion) {
//Do not change to chant when basic attack is used
if (this._battler._castName != 'Attack' || newMotion.name != 'chant') {
this._motion = newMotion;
this._motionCount = 0;
this._pattern = oldMotion.index !== newMotion.index ? 0 : this._pattern;
this._playMotion = !newMotion.loop || newMotion.loop === 'false';
//If you are not idle already then change to idle.
//If you get damage while waiting for your basic attack this way you switch back to idle
} else if (oldMotion.name != 'idle' && newMotion.name == 'chant') {
newMotion.index = 0; //Hardcoded as my idle motion is set up (adopt to your settings)
newMotion.loop = 'true'; //Hardcoded as my idle motion is set up (adopt to your settings)
newMotion.name = 'idle'; //Hardcoded as my idle motion is set up (adopt to your settings)
newMotion.speed = 12; //Hardcoded as my idle motion is set up (adopt to your settings)
this._motion = newMotion;
this._motionCount = 0;
this._pattern = oldMotion.index !== newMotion.index ? 0 : this._pattern;
this._playMotion = !newMotion.loop || newMotion.loop === 'false';
}
}
};

Original thread: https://forums.rpgmakerweb.com/threads/different-cast-animation-for-simple-attack-and-skills.132755/