Need help with a pretty complicated boss fight (Solved!)

upload_2019-3-11_13-59-53.png
boss event

attack event (the one with the script)
upload_2019-3-11_14-0-23.png

(don't mind whats in random attack == 2 btw)
slash attack :
upload_2019-3-11_14-1-3.png
Your boss event is missing one page. It should have a 3rd page that triggers when switch 31 is ON. That page should have the slash attack animation sprite. That said waiting 2 frames each time might be a bit too fast. Average humans have a reaction time of 0.3 seconds, that means you can hardly react if the animation is faster than 20 frames. I used a 2 frames pause because it was like that in your event but I honestly think you should increase that time to at least 10 frames.

One more thing: I did not change boss direction because it was like that in your original event but if you want your boss to not turn invisible you have to change direction at some point (or you could reverse the way it turns). I am going to provide a two possible fixes for that in a different script call. I am also going to change the timing to what I think might be good for you. Of course if you want it to be faster or slower feel free to change it.

Spoiler: First script call with proper timing
Code:
p=$game_player; nx=p.x; ny=p.y
boss = $game_map.events[1]
s = $game_map.events[2]
3.times { boss.set_direction(boss.direction + 2); wait(10) }
$game_switches[31] = true
boss.moveto(nx, ny - 1); wait(2)
s.transparent = true; s.moveto(nx, ny)
s.set_direction(s.direction + 2); s.transparent = false
boss.set_direction(boss.direction - 2)
Spoiler: Second script call with proper timing
Code:
boss = $game_map.events[1]
s = $game_map.events[2]
p = $game_player
2.times do
  wait(6); boss.set_direction(boss.direction - 2)
  s.set_direction(s.direction + 2)
end
if ((p.x == s.x) && (p.y == s.y))
  $game_party.members.each do |m|
   m.change_hp(-60, true)
end; end

I changed the way your boss turns so that it does not disappear. If you want it to turn in the same way without disappearing you have to include checks in your event because apparently set_direction allows you to have a direction greater than 8 (up). Given the how easy it is to swap frames with any image editing software and how limited your script box is I would say it might be a better option to reverse the sequence in your sprite.

This one works in a fresh project so it should work in yours as well. One more thing: I did not do it because it was not present in your original event but moving event 2 above event 1 before the battle starts might be a good idea if you want to keep animations smooth.
Thanks, i'll try it. Btw, i don't have a limited script box anymore.

Okay so, here's the thing : I put 20 frames instead of 2 in the script box. As of right now, i can manage to dodge it really easily.
Also, my slash animation has 2 different graphics, called $Scavor_Slash1, And $Scavor_Slash2. I want it to play slash 1, which is the warning for the slash, and then slash 2 which is the actual attack (for instance, the boss only attacks when the 2nd slash animation is playing.)
I tried putting the slash animation as the 3rd event, however, it played the idle animation instead of the slash. So i tried changing it, and it played the 1st slash attack (that's a lot of slashes). It didn't disappear, so yay. (So basically, i kinda want the actual event that hits the player to appear in front of him when slash 2 is played if possible.)
It should have a 3rd page that triggers when switch 31 is ON.
As I said if you set the same switch you are using for the slash event as a condition for the 3rd page of your boss event real attach it changes to it after warning the player.
I'm sorry, i don't quite understand the last message you sent me.
To be honest though, at this point i only want the animation to work. Because everything else is perfectly fine. ^^
Which part did you not understand?
As I said if you set the same switch you are using for the slash event as a condition for the 3rd page of your boss event real attach it changes to it after warning the player.
Basically this, i don't really understand what it means and/or what it refers to other than just the 3rd page, slash event xd
It means that you need more pages for your boss event. Here is how I made it in the project I used to test the script call. It works perfectly fine in mine and animation is quite smooth too.
Spoiler: Slash Event
SlashEvent.png
Spoiler: Boss event first page (in your case it is page 2 since page 1 is used before battle)
BossEvent.png
Spoiler: Boss Event second page (in your case this has to be page 3)
BossEvent2.png
Keep in mind that in my test I used switch 7. You are using switch 31 in your case. Be sure to use that for both boss extra page AND slash event.
Okay, Whoa! It worked! The animation works!
Just something purely optional, how could i do a quick switch to this sprite
upload_2019-3-11_22-24-28.png
Whenever the boss is teleporting/done teleporting? I only need it to last 1 frame ? Either way, the whole thing works perfectly now. Thanks a bunch.

EDIT : Last question, This time, i think i know how to do it.
So, the goal of the boss is to survive at least 1 minute to it. The start is pretty easy, but then it gets progressively harder. I know how to make it so : "thing happen when timer hits X minutes X seconds". But, to make the actual attack faster, do i just copy/paste the script and put it to the conditional branch i'll make for this specifically? Like, it won't cause any problem, right?
In my case I used the slash event for that. Move your slash event on your boss event and set its direction to 2.
Increasing casting speed can be achieved with a proper timing at the end of your parallel process event. Just increase a variable each time an attack is performed and use
Code:
wait(normal_time - your_variable)
This way each time an attack is performed the next waiting time is reduced.
Alright, Thank you! I am happy to say that i'm finally done with this god-forsaken slash!
Who knew doing something that sounds so simple was so complicated ^^?
@INeedTherapy If this has fully resolved your query, please Report your post and ask for the thread to be closed.

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/need-help-with-a-pretty-complicated-boss-fight-solved.106584/