YesNoOk
avatar

Rainbow PalFX (Read 16029 times)

Started by Lyrica, July 28, 2023, 03:37:16 am
Share this topic:
Rainbow PalFX
#1  July 28, 2023, 03:37:16 am
  • ****
  • Formerly DeathScythe
    • Brazil
    • lyricasky.neocities.org
I created this for my custom power bars and thought it would be cool to share.
I know there is a much easier way to do this effect with the "sin" trigger, but the result wasn't very "smooth" from my testings.
This method uses a lot of variables, some of them are there just for easy customization. Since I made this for a helper I didn't care to use a lot of variables, but if you don't want to spend them like this, you can always use it in a helper and use redirects.

Code:
[State 0, VarSet] ; Rainbow Effect Control
type = Null
trigger1 = !Time
trigger1 = var(4) := 8 ;Flash Speed [recommended to use 2, 4, 8 or 16]
trigger1 = var(5) := 128 ;Range [0 ~ 256]
;----------------------
trigger1 = var(10) := 1
trigger2 = var(1) >= var(5)
trigger2 = var(10) := -1
trigger3 = var(1) <= -var(5)
trigger3 = var(10) := 1
trigger4 = Time = 85
trigger4 = var(20) := 1
trigger5 = var(2) >= var(5)
trigger5 = var(20) := -1
trigger6 = var(2) <= -var(5)
trigger6 = var(20) := 1
trigger7 = Time = 170
trigger7 = var(30) := 1
trigger8 = var(3) >= var(5)
trigger8 = var(30) := -1
trigger9 = var(3) <= -var(5)
trigger9 = var(30) := 1

[State 0, VarAdd]
type = VarAdd
trigger1 = var(1) < var(5)
trigger1 = var(10) = 1
var(1) = var(4)

[State 0, VarAdd]
type = VarAdd
trigger1 = var(1) > -var(5)
trigger1 = var(10) = -1
var(1) = -var(4)

[State 0, VarAdd]
type = VarAdd
trigger1 = var(2) < var(5)
trigger1 = var(20) = 1
var(2) = var(4)

[State 0, VarAdd]
type = VarAdd
trigger1 = var(2) > -var(5)
trigger1 = var(20) = -1
var(2) = -var(4)

[State 0, VarAdd]
type = VarAdd
trigger1 = var(3) < var(5)
trigger1 = var(30) = 1
var(3) = var(4)

[State 0, VarAdd]
type = VarAdd
trigger1 = var(3) > -var(5)
trigger1 = var(30) = -1
var(3) = -var(4)

[State 0, PalFX] ; Rainbow FX
type = PalFX
trigger1 = Root, Power >= 3000 ;Change the conditions here.
time = 1
add = var(1), var(2), var(3)
color = 0
ignorehitpause = 1

Note: the trigger for the PalFX must be true for every tick, or it won't work. You can use trigger1 = 1 in a normal state, or a specific condition in the negative states.

Edit: Decided to show how to use it in a helper and with redirects:
Copy and paste everything (except the PalFX) in an invisible helper, then on your character:

Code:
[State 0, PalFX] ; Rainbow FX
type = PalFX
trigger1 = NumHelper(123456)
time = 1
add = (Helper(123456), var(1)), (Helper(123456), var(2)), (Helper(123456), var(3))
color = 0
ignorehitpause = 1

Of course, replace the ID (123456) with your own.

Hopefully this was helpful. No credit needed if you use. :thumbsup:

Edit 2: felt like posting a preview:
Last Edit: July 28, 2023, 05:03:19 am by DeathScythe
Re: Rainbow PalFX
#2  November 16, 2023, 03:28:51 am
  • *****
  • "The Future is Now"
THIS IS AMAZING!!!

I've done a rainbow effect before but it was more of a seizure! This my man is AMAZING!