Element Dependant Knockout Messages

MGGEDev

Veteran
Veteran
Joined
Mar 22, 2014
Messages
38
Reaction score
7
First Language
English
Primarily Uses
RMMZ
Apologies if this exists but I am looking for a way to change the knockout effect depending on the element that killed the actor/enemy.

For example, if they were killed by the "ice" element it would say "ActorA froze to death".
Fire "ActorA burnt to a crisp".

Is there a way to do this or would it require a plugin?
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
7,555
Reaction score
5,321
First Language
English
Primarily Uses
RMMV
You'd need a plugin, the engine doesn't support this by default. Specifically, as far as I know, you'd need to request/commission a new plugin.

Edit: I was insufficiently creative. You could do this without a plugin, I'd just recommend using one if you have any respect for your own time :wink:
 
Last edited:

MGGEDev

Veteran
Veteran
Joined
Mar 22, 2014
Messages
38
Reaction score
7
First Language
English
Primarily Uses
RMMZ
You'd need a plugin, the engine doesn't support this by default. Specifically, as far as I know, you'd need to request/commission a new plugin.
Thanks for your response, when I'm allowed to post a commission ad, I'll try to get one made in that case!
 

coyotecraft

Mythographer
Veteran
Joined
Mar 13, 2012
Messages
446
Reaction score
253
First Language
English
Primarily Uses
N/A
I believe it can be done with a Battle Event or maybe a Common Event.
State messages can use "\V[]" to display variable values, so it's just a matter of changing the value to a string "was burnt to a crisp!" whenever a fire skill is used.

MZ has "last used data" that could make this easier. If last skill Id is "fire" "fire2" "Nova Flare" blah blah...set the killed message variable to "burnt to a crisp!"
...else, set to the default message "has fallen!"
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
7,555
Reaction score
5,321
First Language
English
Primarily Uses
RMMV
State messages can use "\V[]" to display variable values, so it's just a matter of changing the value to a string "was burnt to a crisp!" whenever a fire skill is used.
This is kind of at odds with your next suggestion. If you're doing this every time a skill is used, you wouldn't need/want to be doing troop events that check the last skill ID.
MZ has "last used data" that could make this easier. If last skill Id is "fire" "fire2" "Nova Flare" blah blah...set the killed message variable to "burnt to a crisp!"
...else, set to the default message "has fallen!"
That...could work. You'd need to set up several troop events for every troop in your game (I don't know if someone has written a "common troop event" plugin for MZ to make this easier) that set all the enemies immortal, then check for any of them to die, do conditionals to see what the last skill ID was, and set the variable string that the Knockout state uses before removing the immortal.

The trick is that if you have any reasonable number of skills in your game, it can get to be extremely unwieldy. If you're going the first route (for example, making every skill set that variable to a string in the damage formula), that's obviously tedious to add to every skill in the game.

If you're going the second route, using the troop event, then you'll have this huge, unwieldy event filled with potentially hundreds of conditionals to check the last skill ID and set the string in the event. (I think the damage formula is the less obnoxious of the two)

In order to get around that, you'd start using at least some script calls, and then it becomes one of those things that becomes way simpler to implement via plugin (write one function with a switch statement that displays the appropriate message if your skill has the <FireDeath> notetag, for example).

But you could do it in-engine.
 
Last edited:

MGGEDev

Veteran
Veteran
Joined
Mar 22, 2014
Messages
38
Reaction score
7
First Language
English
Primarily Uses
RMMZ
Thanks for the tips! I'll have a try to see if I can make something work in-engine, otherwise if it is too much of a headache I'll try to get a plugin commissioned :)
 

Latest Threads

Latest Posts

Latest Profile Posts

9 days left for Harold Jam... hope it's not too late to start gam mak
i think this girl has to be my favorite though :)
62702017_JJKXazrs2LInoZh.png
Wouldn't you know it? Every woman that is interested in me on FB is a bot. Maybe I should respond with 000100100011. If u r willing to date women on FB something has definitely went wrong with your life.
Hello world !! I've created a logo design for my game, I'm calling it "Soup Quest" (It was honestly the best I could come up with <:]) !!
[IMG]https://media.discordapp.net/attachments/866542330286178344/1076307540528332830/Soup_Quest_Game_Logo.png?width=473&height=473[/IMG]
P.S. ty to the person who told me about the "purple text not mixing well with dark mode". I'll be careful on using colored text in the future !!

Forum statistics

Threads
129,747
Messages
1,204,803
Members
170,835
Latest member
KathleenL42
Top