Throw Weapon (Final Fantasy Style)

killerfer

Veteran
Veteran
Joined
Nov 4, 2015
Messages
198
Reaction score
50
First Language
Portuguese
I'm in need of a plugin that makes a skill into something like Final Fantasy "Throw". It's a skill where choose a weapon from your inventory and throw it at the enemy to deal damage based on the weapon attack stat. When you throw a weapon, you lose it forever. It would be nice if it's compatible with Yanfly plugins.

Another nice feature to have would be to show the weapon icon flying to the enemy when you throw it. But I think that would be optional.
 

Victor Sant

Veteran
Veteran
Joined
Mar 17, 2012
Messages
1,694
Reaction score
1,452
First Language
Portuguese
Primarily Uses
What a coincidence, I was thinking about this today and how this can be done with the Mix Actions.

If you don't mind putting some hard work, you can do it.

First setup your Mix action with something like this:

<mix command: 'Throw'>selection 1: wt1, wt2, wt3failure: s1</mix command>- On the selection 1, place all weapon types you want to be throwable (use wt*, where * is the weapon type ID)

- Set the "failure" to be the action that will be used when throwing the weapons.

- Then here comes the hard part: you will need to add tag <mix consumable> to each weapon, so if you have many weapons, this can be a huge pain...

- Now add this code to the pluing (it will be added to original plugin at the next update):

Game_Action.prototype.mixItem = function(index) { var obj = this.mixAction()[index - 1] return obj ? this.subject().getMixItem(obj) : null;};This code allows you to retrieve the items used on the mix. So you can use 'this.mixItem(1)' on the damage formula to get the first mix item, wich is in your case the weapon.

For example, to get the weapon atk, use 'this.mixItem(1).params[2]' inside the formula.

(a.atk + this.mixItem(1).params[2]) * 4 - b.def * 2 will add the weapon atk to the user atk (the rest of the formula is the same as the defaul atk damage).

You can make things harder if you want each weapon throw to have it's own display name and own animation, since you will need a different skill for each weapon, and will need to add each of them to the mix setup. something like this:

<mix command: 'Throw'>selection 1: wt1, wt2, wt3failure: s1w1 = s10w2 = s11w3 = s12w4 = s14</mix command>This works, but require a lot of effort, so you might want to wait for a dedicated plugin to come out.
 
Last edited by a moderator:

killerfer

Veteran
Veteran
Joined
Nov 4, 2015
Messages
198
Reaction score
50
First Language
Portuguese
Thank you Victor. This goes pretty close to the real thing. I thought about doing it with the mix actions but I didn't know I could select only one category (I thought I needed to mix 2 things for it to work). It is a pain to configure everything, but I will keep to your method until someone makes something more specific. Thanks a lot.
 

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

Latest Threads

Latest Profile Posts

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD

Forum statistics

Threads
105,868
Messages
1,017,070
Members
137,577
Latest member
SadaSoda
Top