lordvalinar

Lord of the Damned
Veteran
Joined
Mar 31, 2013
Messages
340
Reaction score
206
First Language
English
Primarily Uses
RMMZ
Kill Quest Assistant (v1.0)
LordValinar

Introduction
This plugin was designed to assist "kill quests" in mind. Basically you get a quest to kill 10 bandits, and you want a variable to increase for each bandit you kill, but doing so with vanilla RPG Maker is difficult since "if enemyHP % <= 0" condition in the troop page doesn't account for the last enemy killed! With this plugin, that issue is resolved! Each enemy with the proper tag that dies in combat will run the appropriately assigned common event (where you can design to your heart's content the conditions and features that happen when it happens).

Features
Runs a common event when an enemy with the <kqs: eventId> tag dies.

Screenshots
<< see attachments >>

How to Use
Place this plugin in your plugins folder, add it to your plugin manager within the RPG Maker MZ engine. Then create an (or select an already made) enemy in the database. Place the <kqs: eventId> tag within the note field. "eventId" will be the numerical value of the Common Event ID you wish to run when this enemy type dies. For example (like in the screenshots) if you want a variable to increase when a zombie dies, you would set that up in the common event.

Download(Github) - Kill Quest Assistant

Terms and Credits
* Free to use and modify for commercial and noncommercial games, with credit.
* Do NOT remove my name from the Author of this plugin
* Do NOT reupload this plugin (modified or otherwise) anywhere other than on these forums (RPGMakerWeb).
 

Attachments

  • kqs_commEv.png
    kqs_commEv.png
    73.8 KB · Views: 88
  • kqs_enemy.png
    kqs_enemy.png
    62.1 KB · Views: 93
  • kqs_killed1.png
    kqs_killed1.png
    881.6 KB · Views: 89
  • kqs_killed2.png
    kqs_killed2.png
    336.6 KB · Views: 90
  • LvMZ_KillQuests.js
    2.2 KB · Views: 19
Last edited:

boutterson

Villager
Member
Joined
Sep 16, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMVX
So I tried this plugin, followed the instructions but it was not working. Not sure why.
 

Shaz

Keeper of the Nuts
Global Mod
Joined
Mar 2, 2012
Messages
46,035
Reaction score
16,847
First Language
English
Primarily Uses
RMMV
That isn't much to go on. Show us how you set up your enemy and your common event.
 

boutterson

Villager
Member
Joined
Sep 16, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMVX
So, after playinng around with it, i'm having the same issue I had prior to installing the plugin. If I have 1 enemy in my troop, it does not count the death; however, if I have 2 or more it counts all others except the last one to die. But the point of the plugin was to count all deaths, including last/only.
 

Attachments

  • Screenshot 2023-03-25 003522.png
    Screenshot 2023-03-25 003522.png
    342 KB · Views: 9
  • Screenshot 2023-03-25 003508.png
    Screenshot 2023-03-25 003508.png
    337.5 KB · Views: 9
  • Screenshot 2023-03-25 003444.png
    Screenshot 2023-03-25 003444.png
    177.3 KB · Views: 9
  • Screenshot 2023-03-25 003423.png
    Screenshot 2023-03-25 003423.png
    104.4 KB · Views: 9

ShadowDragon

Realist
Veteran
Joined
Oct 8, 2018
Messages
7,513
Reaction score
3,022
First Language
Dutch
Primarily Uses
RMMV
its <kqs: x> NOT LEADING 000000 (zeroes) as zeroes will cause trouble.
 

boutterson

Villager
Member
Joined
Sep 16, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMVX
I have the same issue without the leading zeros.
 

boutterson

Villager
Member
Joined
Sep 16, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMVX
I had thought maybe if I had set the variable to 0 initially in the quest, with the +1 for the kills, it would solve the issue. But no such luck.
 

Ayu_Raven

Warper
Member
Joined
Feb 26, 2023
Messages
4
Reaction score
11
First Language
german
Primarily Uses
N/A
The variable I see in the event is #7 and in the enemies note tag common event #4. what if you both set to the same number like in the exampel?
 
Last edited:

caethyril

^_^
Global Mod
Joined
Feb 21, 2018
Messages
4,646
Reaction score
3,777
First Language
EN
Primarily Uses
RMMZ
The core BattleManager:
  1. Does not update events during the victory phase;
  2. Checks for victory before events;
  3. Clears the common event reservation queue when the battle ends.
I just quickly checked the plugin's code on Github and found no special handling for running events at the end of battle. So for the last enemy, the plugin will reserve its event, if any, but by default that event does not get a chance to run in battle (due to the victory phase) or on the map (due to getting cleared).

The usual, non-plugin workaround for this uses an "Immortal" state (Resist State: Death). You can use a troop event with condition Enemy HP <= 0%: that event does stuff (e.g. +1 to variable) and then removes the Immortal state.
 

boutterson

Villager
Member
Joined
Sep 16, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMVX
The variable I see in the event is #7 and in the enemies note tag common event #4. what if you both set to the same number like in the exampel?
7 is the varible number. 4 is the common event. The plugin references common events, the common event then effects the varible. However, the varible only if effected if I have two or more enemies; and only changes after the first dies. Not affected by the last battle.
 

boutterson

Villager
Member
Joined
Sep 16, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMVX
That
The core BattleManager:
  1. Does not update events during the victory phase;
  2. Checks for victory before events;
  3. Clears the common event reservation queue when the battle ends.
I just quickly checked the plugin's code on Github and found no special handling for running events at the end of battle. So for the last enemy, the plugin will reserve its event, if any, but by default that event does not get a chance to run in battle (due to the victory phase) or on the map (due to getting cleared).

The usual, non-plugin workaround for this uses an "Immortal" state (Resist State: Death). You can use a troop event with condition Enemy HP <= 0%: that event does stuff (e.g. +1 to variable) and then removes the Immortal state.
This defeats the purpose of the purposed plugin. As shown in the plugin setup, none of that was needed for the varible to change.
 

caethyril

^_^
Global Mod
Joined
Feb 21, 2018
Messages
4,646
Reaction score
3,777
First Language
EN
Primarily Uses
RMMZ
@boutterson - yes. I just checked the author's profile and it looks like they haven't logged in for a month, so you may want to find or request an alternative:
I have a couple of ideas, but I feel like it'd be impolite to post them in someone else's thread. :kaoswt2:
 

ShadowDragon

Realist
Veteran
Joined
Oct 8, 2018
Messages
7,513
Reaction score
3,022
First Language
Dutch
Primarily Uses
RMMV
can you target a clean common event without visustella plugin commands?
as I convert it to MV for a test and it does work on my end.
 

lordvalinar

Lord of the Damned
Veteran
Joined
Mar 31, 2013
Messages
340
Reaction score
206
First Language
English
Primarily Uses
RMMZ
That

This defeats the purpose of the purposed plugin. As shown in the plugin setup, none of that was needed for the varible to change.
Okay sorry for the long hiatus; Tested the code again with some regex and the number (even with leading zeroes) comes out to be "4" (without quotes), so in theory it should run common event 4. The only things I can think of that's stopping it is:
Game_BattlerBase.prototype.die

Meaning if you have my plugin before any VisuStella plugins that modify the battle system, it won't work properly. Try moving the plugin AFTER VisuStella plugins?
 

Latest Threads

Latest Posts

Latest Profile Posts

This could probably be an entire thread, but it’s really interesting how replaying a game several years later can change how you relate to a character. I think Tidus from FFX got such a bad rap. I getchu. Completely different reaction as an adult now.
As you see, I still enjoy writing tutorials. Is there anything specific you want to see? (I know mapping and editing/resource making is usually popular, but those are very broad topics)
Well, I wanted to expand player battlers visually and now have 3 sheets and counting for each of my players party.
1. Regular sheet
2. The character has turned stone sheet.
3. Using potions sheet.

Technically the main hero has 4 since he starts with a wooden sword, and I felt that the battler should reflect that until he gets a metal one.

Right back to the RM game dev grind in about 15 minutes. :LZSexcite:
Days ago I gave someone the sage advice not to steer away from your main project or take up another one to abandon the first. After figuring a way that would save me years of development, I am forced to redo a lot of stuff on my own turf, near to remake half of what I have already made.
Somewhere down the line I must have crossed paths with bad karma.
:kaomad2:

Forum statistics

Threads
131,733
Messages
1,222,765
Members
173,485
Latest member
taquing
Top