Issue with an skill i'm trying to do

Hello, I'm trying to make an skill that when the player attacks he heals up their allies by 12% of he's maximum hp (not allies hp the one that attacks) have try different things but usually I end up healing up the enemies , I don't know how to script or any so if anyone can guide me or give me a tip for it I will appreciate it

PD: English not native language.
La forma más sencilla de hacer lo que estas buscando es mediante el uso de dos habilidades: la primera sería el ataque, la segunda la curación. Lo que debes hacer es elegir efectos en la primera habilidad, y hacerla que llame un evento comun. Este evento comun incluira el comando forzar acción para la habilidad de curacion a ejecutarse.

Decime si necesitas una explicación mas detallada.

The simplest way to do what you're looking for without scripts is using two skills: the first one would be the attack, the second one the healing. What you must do is choose effects on the first skill and make it call a common event. This common event would include the command force action for the healing skill to be used.

Let me know if you need a more detailed explanation.

 (los mods obligan a repetir en ingles cualquier cosa que escribas en otro idioma/ the mods want you to repeat anything written in another language in english)
This is an english speaking forum, please try to keep other language use at minimum

The other way to handle this is to use the damage formula, but because it's more than one healing target that will need a more complex formula command with a loop or an iteration or something similiar. I've seen such ruby sequences, but I don't have a link ready.
I do understand English perfectly is just that i'm not the best at typing was apologizing for my typos lol 

@Nirwanda: I did try doing 2 different skills but didn't work as i wanted xD, and don't know how to use very well the common event's

@Andar: If you manage to find it i will like to see it 😀
http://tinypic.com/r/noheur/8   Skill
http://tinypic.com/r/9jlqvn/8     State

Right now the skill attacks, and heals the enemie of course because cant cast the heal to me after attacking him (also trying it to make to heal whole party but atm will like to make it function for at least me )
This is an english speaking forum, please try to keep other language use at minimum

The other way to handle this is to use the damage formula, but because it's more than one healing target that will need a more complex formula command with a loop or an iteration or something similiar. I've seen such ruby sequences, but I don't have a link ready.
Sorry, I just wanted to be more clear to n7pankake.

If you want to learn about common events and other begginer things, follow the tutorial link in Andar's signature. But, a rough explanation would be that common events work just like regular events, except that they can be called up from anywhere in your project.

Let me try to explain how to do it. Like I said, first you call a common event from the effects option in your skill:

Hn5AMVv.png


Then, you go to the common events tab, click on the common event you chose previously and select force action.

uIKu3zv.png


That way you'll have an event that forces a specific character (the owner of the skill, obviously) to use the specified skill.

oKrlipE.png


So when you use the attack skill, the common event will force the user to use the healing skill immediately afterwards.

But seriously, check Andar's tutorial, it'll clear up any doubts you might have.

EDIT: Try no to double post. It's frowned upon here.

Anyway, for the skill to affect all allies what you have to do is choose this option:

BR9ZEot.png
Okay i think i did understand! (Im pretty sure is going to work now)

But i got a question... After i put all the allies I want to heal up, what will happen if an ally (that i set up at the common event) is not yet on the party? would the game crash cause trying to heal someone that is still on party or nothing bad should happen?
usually no, that part of the event would be ignored
Okay i just try it, it works as i want the only problem is that they dont heal up 12% of the max hp of the char that does the skill xD but is okay but if can find anything for that please tell me.

Edit: Just fixed it nows heals 12% MHP according to the character that uses the skill

This is what I did if anyone is interested (doubt it though)

2 skills: 

Attack: You set up the attack as you want
On status you add a common event (the one with the Forced action): 
Force action : [Char], [skill (recovery in this case)] , Random

Recovery: and for recover according to the Char MHP I did use this formula:

a.mhp*0.12     0.12 is the 12% (for what i want) of the max hp of the character that just deal the attack

@Andar & @Nirwanda
 
That is because the formula in the picture is wrong - it needs to be a.mhp instead of mhp and if you want 12%, you can't simply divide by 12...
@Andar yeah i did notice and fix it 😀 it works perfectly now
Sorry, I suck at math, so I wrote whatever in the formula box. 🙁
hahaha is okay I was not following your formula xD had something wrong on mine thx for the help! works wonders! hahaha it works perfectly now for test's and stuff but in the future i will make it only heals if you make a crit up meanwhile will just stick with that.

Original thread: https://forums.rpgmakerweb.com/threads/issue-with-an-skill-im-trying-to-do.45971/