Infinity MUGEN Team

IMT Main => M.U.G.E.N Help => Topic started by: 3rdstring on June 10, 2012, 03:05:01 AM

Title: Problem with coding text into my mugen char
Post by: 3rdstring on June 10, 2012, 03:05:01 AM
ive been watching darkcipherlucas videos of how to add text for char vs char for a while now but every time i do it im getting a problem of some being wrong with the way im doing my text i made animations for text and coded it exactly the way he showed us how and still have that problem. i seen your teams doctor doom and reed richards interacting and i was wondering could u help me maybe there's something i missed ty
Title: Re: Problem with coding text into my mugen char
Post by: Fallen_Angel on June 10, 2012, 11:06:03 AM
There are different ways of coding this, you can set a variable and in every move that you want your character to interact, you only need to trigger with the variable.

In statedef -2 add something like 

[state -2, var for specific character]
type = VarSet
trigger1 = P2Name = "Name" || P4Name = "Name"
var(50) = 1

Also if there are some characters with the same name, and you want it to activate in an specific character , you can add this:
Trigger1 = enemy, AuthorName = "Creator"

If you need more information about this, just let me know
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 15, 2012, 09:33:58 AM
 XD||Ty very much man ill let you know
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 21, 2012, 02:03:17 AM
Well i tried for days now fallen is there any way you can send a tutorial of the way you do it or the way you think is best. ty
Title: Re: Problem with coding text into my mugen char
Post by: Space (DCL) on June 21, 2012, 02:54:51 AM
If its an intro...

Add a changestate just below Statedef 190, make sure its above any other changestates.

Add the triggers for it to work on that specific character

Type=ChangeState
Triggerall=(TeamMode=Single)&&(Enemy,TeamMode=single) ;works if both players are in Single Mode
Trigger1 = enemy,Name="name"
trigger1 = enemy,authorname="author's name"
value= #### ;Special Intro No. here

Now just code whatever text (using the animation) in that specific state

btw i wrote this as fast as possible so I may have made a mistake =/
Title: Re: Problem with coding text into my mugen char
Post by: Fallen_Angel on June 22, 2012, 06:45:52 PM
Well i tried for days now fallen is there any way you can send a tutorial of the way you do it or the way you think is best. ty

I think its better that you explain to me what is exactly what you are doing, and what is the result. So It can  be easier to guide you
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 23, 2012, 05:14:05 AM
I have my sprites for my intro and stance and afterwards i go to state 190 and type this in:

[Statedef 190]
type = S
ctrl = 0
velset = 0,0



[State 190, 1]
type = ChangeAnim
trigger1 = SelfAnimExist(190)
value = 190

[State 190, 2] ;Go straight to intro.
type = ChangeState
trigger1 = Time = 0
value = 191

[State 190, 1]
type = ChangeAnim
trigger1 = SelfAnimExist(190)
value = 190

[State 190, 2] ;Go straight to intro.
type = ChangeState
trigger1 = Time = 0
value = 191

[State 190, vs Sailormoon]
type = ChangeState
trigger1 = p2name = "Sailor Moon" || p4name = "Sailor Moon"
value = 10040


;---------------------------------------------------------------------------
;vs sailormoon
 [Statedef 10040]
type = S
ctrl = 0
anim = 10030
velset = 0,0,0

[State 10040, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = intro
flag2 = nomusic
flag3 = nobardisplay

[State 10040, Text]
type = Explod
trigger1 = time = 0
anim = 10031
ID =
pos = 0,0
postype = left  ;p2,front,back,left,right
bindtime = 1

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = AnimTime = 0
value = 0



[State 10040, 2]
type = ChangeState
trigger1 = Time >= 600
value = 0

this is for the first character then i get something like this that pops up.....
Error message:
Error parsing{State 10040, Text}
Error in statedef 10040
Error in CLCNS.CNS
Character needs to be updated
Title: Re: Problem with coding text into my mugen char
Post by: Cyanide on June 23, 2012, 07:41:59 AM
You have 2 problems, one is that your changestate is listed second, so even vs those characters you won't see that intro.

The other is if you're going to use a parameter, you shouldn't leave it blank. There is ONE parameter in mugen it's safe to leave blank and that's guardflag. ID needs a number attached.

Also, 10 second intro is a bit excessive yes?
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 26, 2012, 10:55:57 AM
Cyanide i really hate to bother you man but im lost i think i got down what i need to do,but like you said im not putting it in the right places if you get time could you send me a email of where things are suppose to go cause usually i put everything in statedef 190 or 191. and im guessing its wrong.  my email is Toliver2468@yahoo.com.

Thank you all for the help
Title: Re: Problem with coding text into my mugen char
Post by: Infinite Power on June 26, 2012, 11:59:39 AM
Cyanide i really hate to bother you man but im lost i think i got down what i need to do,but like you said im not putting it in the right places if you get time could you send me a email of where things are suppose to go cause usually i put everything in statedef 190 or 191. and im guessing its wrong.  my email is Toliver2468@yahoo.com.

Thank you all for the help

It has to do with your placement of the changestates and priority.  Placement is key.
You said you had it coded like this, let me show you how to fix this.
Quote
[Statedef 190]
type = S
ctrl = 0
velset = 0,0

[State 190, vs Sailormoon]<--------this should be moved above the 1st changestate
type = ChangeState
triggerall=time=0
trigger1 = p2name = "Sailor Moon" || p4name = "Sailor Moon"
;trigger2 = p2name = "Sailor Whatever" || p4name = "Sailor Whatever";<just n case
;trigger3 = p2name = "Sailor Whatever" || p4name = "Sailor Whatever";<just n case
value = 10040

[State 190, 1];<---if anim exist in the state 190 but want play anyways because your changestates are set to time=0
type = ChangeAnim
trigger1 = SelfAnimExist(190)
value = 190

[State 190, 2] ;<---this is a changestate that goes to state 191
type = ChangeState
trigger1 = Time = 0
value = 191

[State 190, 1];<--------this is not needed seeing as it is in here already
type = ChangeAnim
trigger1 = SelfAnimExist(190)
value = 190


[State 190, 2] ;<--------this is not needed seeing as it is in here already
type = ChangeState
trigger1 = Time = 0
value = 191


[State 190, vs Sailormoon]<--------this should be moved above the 1st changestate like I showed
type = ChangeState
trigger1 = p2name = "Sailor Moon" || p4name = "Sailor Moon"
value = 10040
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 26, 2012, 04:01:01 PM
thank you very much i have my intro working, but the only problem is my text wont show. any suggestions
Title: Re: Problem with coding text into my mugen char
Post by: Cyanide on June 27, 2012, 12:33:47 AM
Assuming you have it set up so the text has the axis in the bottom left?

Postype = left
That's X axis based on the left of the screen and Y based on the top of it
pos = 0,0
That positions it at the beginning point.

Read the docs (please) to see which postype you should make use of

Mugen\Docs\Sctrls.html and look up explod, read it from start to finish and learn about the available postypes.
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 27, 2012, 02:05:49 AM
OOOOOoooooohhhhh Yeeeeeeaaaaahh !!!!! Ty very much mugen infinity team. i have it working now
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 27, 2012, 02:17:45 AM
1 problem my intro works perfectly now, but i must have missed something somewhere cause when sailormoon goes against characters that she doesnt interact with she have lost all her original intros and is just at a weird pose at the beginning

This what i have:

; PREINTRO
[Statedef 190]
type = S
ctrl = 0
velset = 0,0

 [State 190, vs Itachi]
type = ChangeState
trigger1 = p2name = "Akatsuki Itachi by MG" || p4name = "Akatsuki Itachi by MG"
value = 10040

[State 190, 1]
type = ChangeAnim
triggerall = var(30) != 1
trigger1 = SelfAnimExist(190)
value = 190

[State 0, 1]
type = ChangeAnim
triggerall = var(30) = 1
trigger1 = SelfAnimExist(10190)
value = 10190




;---------------------------------------------------------------------------
; INTRO (override this state to give character an intro)
[Statedef 191]
type = S
ctrl = 0

[State 191, 1] ;Go straight to intro.
type = ChangeState
trigger1 = Time >= 600
value = 0



;---------------------------------------------------------------------------
;vs itachi
[Statedef 10040]
type = S
ctrl = 0
anim = 10030
velset = 0,0,0

[State 10040, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = intro
flag2 = nomusic
flag3 = nobardisplay

[State 10040, Text]
type = Explod
trigger1 = time = 0
anim = 10031
ID = 10031
pos = 165,50
postype = left  ;p2,front,back,left,right
bindtime = 1

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = AnimTime = 0
value = 0


[State 10040, 2]
type = ChangeState
trigger1 = Time >= 600
value = 0
Title: Re: Problem with coding text into my mugen char
Post by: 3rdstring on June 27, 2012, 03:03:27 AM
 :-j Nevermind i figured it out sorry ty again
SimplePortal 2.3.5 © 2008-2012, SimplePortal