YesNoOk
avatar

""Level Up"" Sound (Thank You Warusaki3) (Read 9474 times)

Started by 2OS, October 07, 2012, 03:28:18 am
Share this topic:

2OS

""Level Up"" Sound (Thank You Warusaki3)
#1  October 07, 2012, 03:28:18 am
  • ****
  • 608 Wannabe
  • Ich schicke dich zur HOELLE!! STIRB DU FEIGLING!!
    • Egypt
    • deuceovspadez.webs.com/
[Statedef -2]

[State 2OS]
type=helper
trigger1=!numhelper(20000)
id=20000
stateno=20000
name="Power Bar System"
ownpal=!ishelper
ignorehitpause=1
pausemovetime=2147483647
supermovetime=2147483647


[Statedef 20000]

[State Warusaki3]
type=playsnd
trigger1=ishelper(20000)
trigger1=root,power/1000-var(1)/1000>0
value=4000,0+(root,power>=root,powermax)*1  ;;  4000,0 for normal level up. 4000,1 if there is a maximum level sound.
abspan=1  ;;  panning is centered because this is systematic.
ignorehitpause=1

[State Warusaki3]
type=varset
trigger1=ishelper(20000)
var(1)=root,power
ignorehitpause=1
Re: ""Level Up"" Sound (Thank You Warusaki3)
#2  October 08, 2012, 07:52:01 pm
  • *****
  • Gaps? Where we're going, we don't need gaps...
    • USA
    • ricepigeon.neocities.org
Offtopic: 2147483647 ticks worth of pausemovetime is approximately 1.1341608397554524636432005813708 years (who keeps MUGEN running that long?)

Ontopic: I was about to say that the sounds might repeat themselves when not wanted, until I looked over the code again. Small and efficient, but I probably would have used a changestate for the helper with the playsound in the second state with persistent = 0, with an immediate changestate back, just to avoid any possibility of the sound repeating itself when not needed.

2OS

Re: ""Level Up"" Sound (Thank You Warusaki3)
#3  October 08, 2012, 08:09:44 pm
  • ****
  • 608 Wannabe
  • Ich schicke dich zur HOELLE!! STIRB DU FEIGLING!!
    • Egypt
    • deuceovspadez.webs.com/
2147483647 is supposed to be riddling, but not for ""how long"". everyone knows what -1 and 9999999 means.
Re: ""Level Up"" Sound (Thank You Warusaki3)
#4  October 08, 2012, 08:21:18 pm
  • *****
  • Gaps? Where we're going, we don't need gaps...
    • USA
    • ricepigeon.neocities.org
2147483647 is supposed to be riddling, but not for ""how long"". everyone knows what -1 and 9999999 means.

I'm aware of why 2147483647 is used, I was just posting some useless trivia for the hell of it at the same time as I was posting something that was on topic.