captainproton

Dangerously Nifty
Veteran
Joined
Dec 20, 2013
Messages
1,276
Reaction score
570
First Language
english
Primarily Uses
Sadly, i get very confused when altering code beyond a couple of numbers....

One of my characters, Enoch, is a necromancer with a summon skill using an item called Necroplasm as a skill cost.
I was wanting to equip him with a passive "Harvest" state that allows him to automatically add Necroplasm to the inventory when he kills an enemy.

I am using most of Yanfly's RMMV plugins, specifically including Auto Passive States and Buffs and States Core.
I *have* used these plugins to add a "Pokemon Sun/Moon" style Beast Boost passive state to my gladiator character as indicated here.
Sadly, I don't know how to alter the notetages--or if it's possible--to create a passive state allowing Enoch to add Necroplasm to the inventory upon delivering the killing blow.

Is there anyone with the coding knowledge who can help with this?
 

rainyday

Veteran
Veteran
Joined
Nov 5, 2019
Messages
78
Reaction score
55
First Language
English
Primarily Uses
RMMV
Put this in your passive state's notebox
Code:
<Custom Conclude Effect>
if(target.hp <= 0){
//Change x to the item ID you want to give, and y to the amount to give.
$gameParty.gainItem($dataItems[x],y,false);
var text = '<CENTER>' + user.name() + ' has generated a ' + $dataItems[x].name + ' from ' + target.name() + '!';
var wait = 90;
BattleManager.addText(text, wait);
}
</Custom Conclude Effect>

That's probably the least complex way to implement this, if you want something more fancy just let me know.
 
Last edited:

captainproton

Dangerously Nifty
Veteran
Joined
Dec 20, 2013
Messages
1,276
Reaction score
570
First Language
english
Primarily Uses
Thanks! I'll try this out!
Edit:
This worked wonderfully! Thanks for your help!
 
Last edited:

Latest Threads

Latest Posts

Latest Profile Posts

I tried a new thing.

fg.png
Another night, another game dev stream in about 20 minutes or so.

I've been busy. Warming up so I don't forget how to draw.
Fr4yy7TaEAUB57Z
I'd make a joke about the post office, but I'm afraid you won't get it.
I've been on a really good streak lately of working on my game for at least a little bit each day. Even if I only complete one small task, it is still a much better pace than what I was maintaining previously!

Forum statistics

Threads
129,784
Messages
1,205,122
Members
170,893
Latest member
LeeYoung
Top