Mr. Game & Watch - .CNS Coding help - Code Library - Blaze mugen forums
Tuesday, 2009-11-24, 1:30 Pm
Welcome Guest

Blaze M.U.G.E.N

Blaze mugen forums

[New messages · Members · Forum rules · Search · RSS ]
Page 2 of 2«12
Blaze mugen forums » Code Library » .CNS Coding help » Mr. Game & Watch
Mr. Game & Watch
OmnifoxDate: Thursday, 2008-03-20, 7:38 Pm | Message # 21
MuGeN Mayhem
Group: Users
Messages: 174
Reputation: 3
Status: Offline
I like the idea but if it is too much trouble then do you think it will be easier to make the hammer's power vary according to his health?

less health = more power?


Current W.I.P. :

.... still have not added all the required sprites yet. <_<

 
Waluigi99Date: Tuesday, 2008-03-25, 6:42 Am | Message # 22
Training
Group: Users
Messages: 32
Reputation: 0
Status: Offline
Add it to the ChangeState, Hitdef, or the ChangeAnim.

Added (2008-03-25, 6:42 Am)
---------------------------------------------
The Code Dos not Work Properly, no mater ware i put that code. Is there Anything I'm Missing?

[StateDef 1001]
type = S
movetype= A
physics = S
juggle = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 20
sprpriority = 2

[State 1001, 1]
type = HitDef
trigger1 = anim = 1001
trigger1 = random < 111
trigger1 = 1001
attr = S, NA
damage = 23
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1001
trigger1 = random < 111
value = 1001

[State 1001, 1]
type = ChangeState
trigger1 = anim = 1001
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 2]
type = HitDef
trigger1 = anim = 1002
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1002
trigger1 = random > 111
value = 1002

[State 1001, 2]
type = ChangeState
trigger1 = anim = 1002
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 3]
type = HitDef
trigger1 = anim = 1003
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1003
trigger1 = random > 111
value = 1003

[State 1001, 3]
type = ChangeState
trigger1 = anim = 1003
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 4]
type = HitDef
trigger1 = anim = 1004
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1004
trigger1 = random > 111
value = 1004

[State 1001, 4]
type = ChangeState
trigger1 = anim = 1004
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 5]
type = HitDef
trigger1 = anim = 1005
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1005
trigger1 = random > 111
value = 1005

[State 1001, 5]
type = ChangeState
trigger1 = anim = 1005
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 6]
type = HitDef
trigger1 = anim = 1006
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1006
trigger1 = random > 111
value = 1006

[State 1001, 6]
type = ChangeState
trigger1 = anim = 1006
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 7]
type = HitDef
trigger1 = anim = 1007
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1007
trigger1 = random > 111
value = 1007

[State 1001, 7]
type = ChangeState
trigger1 = anim = 1007
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 8]
type = HitDef
rigger1 = anim = 1008
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1008
trigger1 = random > 111
value = 1008

[State 1001, 8]
type = ChangeState
trigger1 = anim = 1008
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 1001, 9]
type = HitDef
trigger1 = anim = 1009
trigger1 = random > 111
attr = S, NA
damage = 9999999
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeAnim
trigger1 = anim = 1009
trigger1 = random > 111
value = 1009

[State 1001, 9]
type = ChangeState
trigger1 = anim = 1009
trigger1 = AnimTime = 0
value = 0
ctrl = 1


Waluigi
 
Sir_KillzalotDate: Tuesday, 2008-03-25, 11:38 Am | Message # 23
MuGeN Expert
Group: Users
Messages: 349
Reputation: 12
Status: Offline
your random triggers have duplicates
for each group of a hitdef and changeanim should have a different random trigger than another. For with the current code multiple hitdefs and changeanim occur at the same time which should never happen.

you need to have your random triggers vary between each group. (make sure that two groups can't activate at the same time)

you only need one changestate with the following code:

[State 1001, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

and I do not think the damage of a hitdef can reach 99999999

 
Waluigi99Date: Friday, 2008-03-28, 8:49 Am | Message # 24
Training
Group: Users
Messages: 32
Reputation: 0
Status: Offline
So change the number 111 to something else
and were do i out this code
[State 1001, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

Waluigi
 
Sir_KillzalotDate: Friday, 2008-03-28, 1:08 Pm | Message # 25
MuGeN Expert
Group: Users
Messages: 349
Reputation: 12
Status: Offline
doesn't really matter. Ussually people put it at the end before the next statedef
 
Waluigi99Date: Friday, 2008-03-28, 3:02 Pm | Message # 26
Training
Group: Users
Messages: 32
Reputation: 0
Status: Offline
Could Correct my mistakes in the my previous Post and then re-post it because I Don't Really understand what your saying.

Waluigi
 
Sir_KillzalotDate: Saturday, 2008-03-29, 9:39 Am | Message # 27
MuGeN Expert
Group: Users
Messages: 349
Reputation: 12
Status: Offline
Here is an example of how the code would look like. (note I didn't check to see if this is 100% correct, but I see no errors with the code).

Code

[StateDef 1001]  
type = S  
movetype= A  
physics = S  
juggle = 1  
velset = 0,0  
ctrl = 0  
anim = 1001  
poweradd = 20  
sprpriority = 2  

[State 1001, 1]  
type = HitDef  
trigger1 = random < 111  
attr = S, NA  
damage = 23  
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1001  
trigger1 = random < 111  
value = 1001  

[State 1001, 2]  
type = HitDef  
trigger1 = random >= 111  
trigger1 = random < 222
attr = S, NA  
damage = 33
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1002  
trigger1 = random >= 111  
trigger1 = random < 222
value = 1002  

[State 1001, 3]  
type = HitDef  
trigger1 = random >= 222
trigger1 = random < 333
attr = S, NA  
damage = 43
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1003  
trigger1 = random >= 222  
trigger1 = random < 333
value = 1003  

[State 1001, 4]  
type = HitDef  
trigger1 = random >= 333
trigger1 = ranom < 444
attr = S, NA  
damage = 53
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1004  
trigger1 = random >= 333
trigger1 = ranom < 444
value = 1004  

[State 1001, 5]  
type = HitDef  
trigger1 = random >= 444
trigger1 = random < 555
attr = S, NA  
damage = 63
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1005  
trigger1 = random >= 444
trigger1 = random < 555
value = 1005  

[State 1001, 6]  
type = HitDef  
trigger1 = random >= 555
trigger1 = random < 666
attr = S, NA  
damage = 73
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1006  
trigger1 = random >= 555
trigger1 = random < 666
value = 1006  

[State 1001, 7]  
type = HitDef  
trigger1 = random >= 666
trigger1 = random < 777
attr = S, NA  
damage = 83
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1007  
trigger1 = random >= 666
trigger1 = random < 777
value = 1007  

[State 1001, 8]  
type = HitDef  
trigger1 = random >= 777
trigger1 = random < 888
attr = S, NA  
damage = 93
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1008  
trigger1 = random >= 777
trigger1 = random < 888
value = 1008  

[State 1001, 9]  
type = HitDef  
trigger1 = random >= 888
attr = S, NA  
damage = 93
animtype = Light  
guardflag = MA  
hitflag = MAF  
priority = 3, Hit  
pausetime = 10, 10  
sparkno = 0  
sparkxy = -10, -76  
hitsound = 5, 0  
guardsound = 6, 0  
ground.type = High  
ground.slidetime = 5  
ground.hittime = 12  
ground.velocity = -4  
airguard.velocity = -1.9,-.8  
air.type = High  
air.velocity = -1.4,-3  
air.hittime = 12  

[State 1001]  
type = ChangeAnim  
trigger1 = anim != 1009  
trigger1 = random >= 888
value = 1009  

[State 1001]  
type = ChangeState  
trigger1 = AnimTime = 0  
value = 0  
ctrl = 1  

 
Waluigi99Date: Sunday, 2008-03-30, 8:30 Pm | Message # 28
Training
Group: Users
Messages: 32
Reputation: 0
Status: Offline
It dos not work Properly he still sits on the first frame
is it possible to change the animation according to health left?
so 1000 HP = The 1
900 HP = The 2
800 HP = The 3
700 HP = The 4
600 HP = The 5
500 HP = The 6
400 HP = The 7
300 HP = The 8
200 HP = The 9

Like that?
Because I don't think the other one CAN work.


Waluigi
 
FarlancerDate: Monday, 2008-03-31, 10:07 Pm | Message # 29
Begginer
Group: Users
Messages: 1
Reputation: 0
Status: Offline
I know I'm new here, but I think I spotted the problem...The animation was constantly being changed, because there is no persisent = 0 on the animation changes...

Anyway, might I suggest a different way to change the animations?

Code

[StateDef 1001]
type = S
movetype= A
physics = S
juggle = 1
velset = 0,0
ctrl = 0
poweradd = 20
sprpriority = 2

[State 1001, ChangeAnim]
type = ChangeAnim
trigger1 = 1
value = 1001 + floor(random/112)  ;randomly changes the anim between 1001 and 1009
persistent = 0 ;Only changes the anim once

[State 1001, 1]
type = HitDef
trigger1 = anim = 1001
attr = S, NA
damage = 23
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 2]
type = HitDef
trigger1 = anim = 1002
attr = S, NA
damage = 33
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 3]
type = HitDef
trigger1 = anim = 1003
attr = S, NA
damage = 43
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 4]
type = HitDef
trigger1 = anim = 1004
attr = S, NA
damage = 53
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 5]
type = HitDef
trigger1 = anim = 1005
attr = S, NA
damage = 63
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 6]
type = HitDef
trigger1 = anim = 1006
attr = S, NA
damage = 73
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 7]
type = HitDef
trigger1 = anim = 1007
attr = S, NA
damage = 83
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 8]
type = HitDef
trigger1 = anim = 1008
attr = S, NA
damage = 93
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001, 9]
type = HitDef
trigger1 = anim = 1009;the strongest hit anim
attr = S, NA
damage = 93
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 10, 10
sparkno = 0
sparkxy = -10, -76
hitsound = 5, 0
guardsound = 6, 0
ground.type = High
ground.slidetime = 5
ground.hittime = 12
ground.velocity = -4
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 12

[State 1001]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1


No! I should've been able to absorb that!
 
Waluigi99Date: Tuesday, 2008-04-01, 8:33 Am | Message # 30
Training
Group: Users
Messages: 32
Reputation: 0
Status: Offline
Thanks Man, It Works Perfectly!
God Bless You!

Added (2008-04-01, 8:33 Am)
---------------------------------------------
Also For A Charged Projectile How do you Make It so If you Stop Charging in the middle you Continue charging from ware you left off when you start Charging Again?

And How do you make a move go through someone shielding?


Waluigi
 
Blaze mugen forums » Code Library » .CNS Coding help » Mr. Game & Watch
Page 2 of 2«12
Search:

Login form
E-mail:
Password:
Site friends
Site Admins
Blazeinc (A.K.A UrOz)
Our poll
which character series are the best for mugen
Total of answers: 1007
Created By UrOz | Blazeinc