Add compatibility for Dragonbones to Caethyril's Time Stop plugin

belatucadrus

Veteran
Veteran
Joined
Mar 6, 2017
Messages
78
Reaction score
13
First Language
french
Primarily Uses
RMMV
Hi,

Caethyril released a cool plugin which lets me add a "Time stop" skill. When an actor or a battler is affected by the "Timestopped" state, the battler stops being animated and stands still

This plugin works great with Yanfly's SVE plugin, but now I'm looking for a way to mak it compatible with Dragonbones. The plugin is easy to understand as all it does is refusing to update the battlers animation if they are affected by the "Timestopped" state.

So I guess all I have to find is the method which does the update of dragonbones graphics. I tried to do it myself, with no success.

Can someone give me a hand ?

Timestop plugin link :
YEP Dragonbone integration link : http://www.yanfly.moe/wiki/Dragonbones_Integration_(YEP)[/spoiler]
 

zaraku

Time Keeper
Veteran
Joined
Apr 19, 2018
Messages
36
Reaction score
34
First Language
English
Primarily Uses
RMMV
I'm not an avid programmer so I don't know the best way of implementing these into the plugin, but if you're using action sequences you can stop and play the animations for a battler using these script calls:

JavaScript:
// stop animation based on party index
dragonBonesIntegration.ArmatureDatabaseActor[x].armature.animation.stop();
// stop animation for enemy based on troop index
dragonBonesIntegration.ArmatureDatabaseEnemy[x].armature.animation.stop();

// resume animation
dragonBonesIntegration.ArmatureDatabaseActor[x].armature.animation.play();
dragonBonesIntegration.ArmatureDatabaseEnemy[x].armature.animation.play();
 
Last edited:

belatucadrus

Veteran
Veteran
Joined
Mar 6, 2017
Messages
78
Reaction score
13
First Language
french
Primarily Uses
RMMV
Just pasted it in the console, and it worked !

I have two questions tho.

1) How can I use this script call to stop the animation of all the enemies affected by the "Timestopped" state ?
2) How can I call the script call when the state wears off to restart animating the enemies ?
 

zaraku

Time Keeper
Veteran
Joined
Apr 19, 2018
Messages
36
Reaction score
34
First Language
English
Primarily Uses
RMMV
Just tested this and it's working for me so far. If you have Buff & States Core you can add these notetags to your timestopped state:

Code:
<Custom Apply Effect>
if (this.isEnemy()){
dragonBonesIntegration.ArmatureDatabaseEnemy[this.index()].armature.animation.stop();
} else {
dragonBonesIntegration.ArmatureDatabaseActor[this.index()].armature.animation.stop();
}
</Custom Apply Effect>

<Custom Remove Effect>
if (this.isEnemy()){
dragonBonesIntegration.ArmatureDatabaseEnemy[this.index()].armature.animation.play();
} else {
dragonBonesIntegration.ArmatureDatabaseActor[this.index()].armature.animation.play();
}
</Custom Remove Effect>
I added the actor check just in case your actors will ever get the state (and because I need it for my own time stop mechanic).
 

belatucadrus

Veteran
Veteran
Joined
Mar 6, 2017
Messages
78
Reaction score
13
First Language
french
Primarily Uses
RMMV
I do not use dragonbones for my actors, thus, pasting your code gives me an error, so I removed the actor part, and it doesn't work :( The enemies are still moving. Did I do something wrong ?

Code:
<Custom Apply Effect>

if (this.isEnemy()){

dragonBonesIntegration.ArmatureDatabaseEnemy[this.index()].armature.animation.stop();

}

</Custom Apply Effect>



<Custom Remove Effect>

if (this.isEnemy()){

dragonBonesIntegration.ArmatureDatabaseEnemy[this.index()].armature.animation.play();

}

</Custom Remove Effect>
 

zaraku

Time Keeper
Veteran
Joined
Apr 19, 2018
Messages
36
Reaction score
34
First Language
English
Primarily Uses
RMMV
Um, I'm not really sure why it wouldn't work for you. You are using Yanfly's Buff & States Core right? Can you also show me your state and plugin list?
 

belatucadrus

Veteran
Veteran
Joined
Mar 6, 2017
Messages
78
Reaction score
13
First Language
french
Primarily Uses
RMMV
It was a compatibility issue with another plugin (MrTS's States EX plugin)

Turning it off solved the problem :)

Now I can za warudo the game and do whatever I want ψ(`∇´)ψ

Thank you for the help !
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Profile Posts

so, ive been gone for too long when i log in and see that everything is where is shouldn't be. XD
Steam killing my eyes.. I forgot why I use it only when I have no other choice
Making a map, my brain went "Look, Mjölnir!" as I plotted out a sacrificial entrance.

Actually, it went, "Look, hammer. Wait, Thor's hammer!"
CG tile rendering, take 3: windows.
which section you guys think looks more accurate to the perspective? left or right?

for reference, this is what it looks like "at street level"
Okay, Animal Crossing is remarkably addictive and exceptionally calming. I've been playing it pretty exclusively... like... 6 hours a day. Been a while since I've been this engrossed.

Forum statistics

Threads
95,402
Messages
928,922
Members
125,622
Latest member
Komalis
Top