Yanfly's action sequence plugin poses problem for scripting amatuer <RESOLVED>

Status
Not open for further replies.

marbeltoast

Your future fish emporer
Veteran
Joined
Nov 11, 2018
Messages
73
Reaction score
26
First Language
English
Primarily Uses
RMMV
Good day, all. I'll be brief and clear.

I'm using Yanfly's action sequence pack 1 and also his enhanced TP plugins. I'm trying to create an attack (Let's call it "Momentum Swing", for reference) that uses how much TP the attacker has when they start the attack to determine the damage, as well as their attack and the enemy defence. I also want using the attack to set the attacker's TP to zero afterwards.

Two issues emerged at first: I also want other attacks to generate TP based on which TP mode the player is in when they deal damage, take damage, kill enemies, etc. I want the removal effect of Momentum Swing to overwrite this TP mode based gain and loss, which would normally leave the player with +10 TP after sucessfully dealing damage, or a different amount depending on the mode they choose.

Issue two: I don't know how to write a line of javascript that can be slotted into the <finish action> section that reduces the specific party member's TP to 0. I can write a line outside of this context, something like "$gameParty.members()[x].gainTp(-n)" where x is the party member in question and n is the max TP possible, but I'm not sure how to re-phrase that into the <finish action> area without it just not working.

Any and all assistance that you could provide would be greatly appreciated. Thanks and have a good day and a lovely weekend!
 

TSR

The Northern Frog
Veteran
Joined
Nov 14, 2019
Messages
132
Reaction score
71
First Language
French
Primarily Uses
RMMV
Hi there!
If you want to use a Js line in <finish action> to set the user TP to zero, use:
Code:
eval: user.setTp(0);
*note that action sequence pack 1 has plugin commands lines to change the TP value, refer to the plugin instruction

I'm not too sure I understand your first issue.
 

marbeltoast

Your future fish emporer
Veteran
Joined
Nov 11, 2018
Messages
73
Reaction score
26
First Language
English
Primarily Uses
RMMV
It seems that the solution to the second problem has ALSO fixed the first issue! After gaining 10TP from sucessfully dealing damage, the TP reduction effect occured and reduced the TP to 0, which means it's already working as intended. I was worried that it would reduce to 0 and AFTERWARDS gain the 10 from dealing damage, but it seems my worries were unecessary! Cheers for that, mate!
 
  • Like
Reactions: TSR

Kes

Global Moderators
Global Mod
Joined
Aug 3, 2012
Messages
21,611
Reaction score
10,924
First Language
English
Primarily Uses
RMVXA

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

 
Status
Not open for further replies.

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

Latest Threads

Latest Posts

Latest Profile Posts

World Of Final Fantasy Livestream~!
(Ft. Kaliga)
So my office building has 8 individually rented offices in it; 3 of which are social workers and 2 are marriage therapists... Unsurprisingly it always sound very angry out there. Glad I have my own private entrance. :LZSexcite: :thumbsup-right:
I wonder if there's ever been an art challenge that involves drawing faces from the generator.
I'm sorry about earlier. I have the most hate and the most love for my art at the same time. Felt bad about my thread because I wasn't listening, and because I made it out of a bad mindset to begin with. S'another Thursday for me.

Forum statistics

Threads
94,369
Messages
920,363
Members
124,136
Latest member
prox
Top