The Mugen Fighters Guild
Help => M.U.G.E.N Development Help => Code Library => Topic started by: 2OS on July 21, 2012, 09:50:40 pm

Anim
2000 = 0
2001 = 1
2002 = 2
2003 = 3
2004 = 4
2005 = 5
2006 = 6
2007 = 7
2008 = 8
2009 = 9
[State Numbers]
type=varset
trigger1=
var(20)=the numbers
ignorehitpause=1
[State Numbers]
type=varadd
trigger1=
var(20)=the numbers
ignorehitpause=1
[State Ones]
type=explod
trigger1=1
anim=2000+(var(20)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1
[State Tens]
type=explod
trigger1=var(20)>=10 ;; replace with ""1"" if you want them to appear even when their value is 0
anim=2000+((var(20)/10)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1
[State Hundreds]
type=explod
trigger1=var(20)>=100 ;; replace with ""1"" if you want them to appear even when their value is 0
anim=2000+((var(20)/100)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1
[State Thousands]
type=explod
trigger1=var(20)>=1000 ;; replace with ""1"" if you want them to appear even when their value is 0
anim=2000+((var(20)/1000)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1
[State Ten Thousands]
type=explod
trigger1=var(20)>=10000 ;; replace with ""1"" if you want them to appear even when their value is 0
anim=2000+((var(20)/10000)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1
[State Hundred Thousands]
type=explod
trigger1=var(20)>=100000 ;; replace with ""1"" if you want them to appear even when their value is 0
anim=2000+((var(20)/100000)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1
[State Millions]
type=explod
trigger1=var(20)>=1000000 ;; replace with ""1"" if you want them to appear even when their value is 0
anim=2000+((var(20)/1000000)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1
[State I hope you've caught on]
type=explod
trigger1=var(20)>=10000000 ;; replace with ""1"" if you want them to appear even when their value is 0
anim=2000+((var(20)/10000000)%10)
bindtime=1
removetime=1
facing=1(teamside=2)*2
ontop=1
ownpal=0
pos=
postype=back
sprpriority=9
ignorehitpause=1

Not sure if yours improves on it but
http://mugenguild.com/forumx/index.php?topic=43756.msg264665#msg264665
has been in the code library for a while.

this way is far more simple and efficient. it doesn't require extra math and it doesn't require ( any variables at all ) a variable for each number place.

[State Numbers]
type=varset
trigger1=
var(20)=the numbers
ignorehitpause=1
[State Numbers]
type=varadd
trigger1=
var(20)=the numbers
ignorehitpause=1
I assume the trigger should be when I hit the opponent. As for the bold....I honestly have no idea what to put there and I don't know why I don't know because, I should know.
Got it.