# Interactive KOF Character Tutorial (Read 78879 times)

Started by Koop, February 07, 2013, 04:41:25 pm

#### Koop

##### Re: Interactive KOF Character Tutorial
#41  May 22, 2015, 08:13:15 pm
• ???
Okay. Let me see if I can answer those for you:

- Can anyone explain to me how do I use this formula to calculate the damage?:
Code:
`damage = floor(42*ifelse(var(56),1.25,1)) `
I tried to figure out for weeks and I still can't get it.

This one is pretty simple. If var(56) (counter hit check) is true, than the damaged will be multiplied by 1.25 (floor is used to round it down to an integer, since you can't use floats for damages). So 42*1.25 = 52.5 which is rounded down to 52
If var(56) = 0, than the damage will be multiplied by 1 giving the same value. 42*1 = 42

- for air.velocity, I am still not sure how this is calculated, can anyone explain more in depth about the calculation of the air.velocity?

The x vel is an approximation used because x vels in get hit states don't use friction when you are in the air. The actual value is 12 (I guess) and it should looks something like this in KOF

Code:
`[State -2, VelSet]type = VelSettrigger1 = time < 6x = (-12*exp((-0.20763936477824450161544104426739)*(time)))`

once 6 ticks have passed the friction stops and the vel remains the same until the character hits the ground. Implementing this for common get hit states would be a nightmare and a half, so I wouldn't bother with it. However if you are curious and want to make everything with customs states, you can take a look at some of the custom states that Vans and I made.

as for calculating the fall vels....artmoney has a tendency to show values one tick late, so you may need to add the yaccel to the y value you find and for x vels with friction, divide with the mul you find.
Like if you were making someone with a fast dashing kick move and you got x = 19.5 with a mul of .8125 and something doesn't feel right, try dividing the x vel with the mul. 19.5 / 0.8125 = 24.

Hope that helps you out. Well....you really shouldn't need to recalculate get hits since you can just use the values that I use.

#### tehdevil

##### Re: Interactive KOF Character Tutorial
#42  May 24, 2015, 10:36:16 am
Hope that helps you out. Well....you really shouldn't need to recalculate get hits since you can just use the values that I use.
Yeah, I notice all characters uses the same air.velocity and fall.yvelocity value

- Can anyone explain to me how do I use this formula to calculate the damage?:
Code:
`damage = floor(42*ifelse(var(56),1.25,1)) `
I tried to figure out for weeks and I still can't get it.

This one is pretty simple. If var(56) (counter hit check) is true, than the damaged will be multiplied by 1.25 (floor is used to round it down to an integer, since you can't use floats for damages). So 42*1.25 = 52.5 which is rounded down to 52
If var(56) = 0, than the damage will be multiplied by 1 giving the same value. 42*1 = 42

The calculation of damage value is weird, I am not sure did I use the damage calculation formula wrongly or something, this is how I calculated the damage by using weak close punch as an example:

Code:
`;CLOSE A[Statedef 200]type    = S                      movetype= A                    physics = S                    velset = 0,0                    ctrl = 0                       anim = 200  poweradd= 0                               sprpriority = 2  juggle =10   facep2 = 1[State 200, snd]type=playsndtrigger1= animelem=1 && random<500value=200,0channel=0  [State 200, Punch Attempt Sound]type = Playsndtrigger1 = time = 0value = 3+(var(32)*2),0[State 205, 1]type = HitDeftriggerall = var(40) < 1 || var(57) > 0 || var(16) > 0trigger1 = AnimElemtime(2) >= 0 && animelemtime(3) < 0[b]damage = floor(42*ifelse(var(56),1.25,1))[/b]sparkno = s17000+(var(31)*10000)sparkxy = -10, -80hitsound = s3+(var(32)*2+((random%3)*var(32))),1guardsound = s3+(var(32)*2), 12guard.sparkno = s17500+(var(31)*10000)attr = S, NAanimtype = Lightair.animtype = Background.type = Highguardflag = MAhitflag = MAFpriority = 6, Hitpausetime = 7,9guard.pausetime = 7,8ground.slidetime = 9ground.hittime = 8guard.hittime = 8guard.slidetime = 9guard.ctrltime = 16ground.velocity = -5.796875air.velocity = -4.5,-7air.juggle = 0getpower = 47,47givepower = 16,16air.fall = 0forcenofall = 1ground.cornerpush.veloff = 0guard.cornerpush.veloff = 0air.cornerpush.veloff = 0yaccel = .5persistent = 0[State 200, 7]type = ChangeStatetrigger1 = AnimTime = 0value = 0ctrl = 1`
So 42 is the damage value and when I check using kof98's Kyo from the art money table, it show that the damage value is 99

so when I use the formula:
Code:
`damagevalue / maxlife * 1000 = MUGEN damage value`
99/103 * 1000 = 961

or maybe if I take 103 - 99 (I assume 99 is the life gauge that is left) and the value which 103 subtract from 99 is 4 which is the damage value and this is how I calculate:
4/103 * 1000 = 39 and it is not 42? I am confuse

this same goes for the power gauge, I managed to calculate all the basic attack's hitdef for getpower using Kyo from kof98's close weak punch as example:
Total kof98's powergauge is 128 so
6/128 * 1000 = 47 which is correct, but when calculating command attack and special moves, the calculation feels confusing and wrong such as I use  Kyo from kof98's Weak 75 Shiki Kai (first hitdef) as example:
Your Kyo shows get.power is 16 but when I calculate, it shows
4/128*1000 = 31 and it is not 16. I am not sure did I calculate wrongly or using the formula wrongly?
<- I exercise like that regularly!

#### Koop

##### Re: Interactive KOF Character Tutorial
#43  May 24, 2015, 12:25:52 pm
• ???
Oh that. Well the damages in KOF have a tendency to differ by 1 randomly. Your formula is correct. However the main difference is that I use 120 as the maxlife value and not 102 or 103.

#### tehdevil

##### Re: Interactive KOF Character Tutorial
#44  May 24, 2015, 03:47:21 pm
Yup, it was stated in your previous post:
-The max life in 2002 is 102, 103 in 98 and 120 in 2002 UM. I don't know the rest.
120 is for 2002 Unlimited Match but still (using kyo from kof98's close weak punch as an example):
99/120*1000 = 825  even worst
21(120-99)/120*1000 = 175
kof98 doesn't differ by 1 randomly but 2002 does, if that is the reason of having differ by 1 randomly, which one would be recommended to use to calculate the damage value?
<- I exercise like that regularly!

#### Koop

##### Re: Interactive KOF Character Tutorial
#45  May 24, 2015, 05:33:16 pm
• ???
Whichever value you get first is the one you should use.

#### tehdevil

##### Re: Interactive KOF Character Tutorial
#46  June 25, 2015, 09:37:01 am
Forgive the lateness of this part. There are too many things on the mind. Most of which ARE mugen related and this tutorial is a good way to get everything covered.

Part 2: AIR Making

Now this can be the longest part of character creation. I recommend you have some music or a good podcast to listen to. It really helps. First things first, you need a program to make the .air file. Of course you could just use notepad, but I'm guessing that would take a longer time than most of the dedicated programs we have now. I personally use Fighter Factory Classic. I would suggest that newer creators get used to fighter factory 3. Here is some info that may interest you regarding Fighter Factory:

How clsns appear in FF isn't accurate to how they appear in mugen. Clsn made in FF will be drawn 1 pixel lower and one pixel to the right in mugen. I believe mcm and the latest FF3 show clsn correctly. However this isn't usually a problem if you add sprites with clsn in order to trace. A bit of a moot point when you can get perfect clsn, but it's always good to know. For those times when you don't have axis to the clsn viewer (nbc/kof xi and higher).

So as previously mentioned, the way to get clsn right is by adding frames with clsn visible to the sff, then tracing over them. Some of us have different....methods of getting clsn but this is the one that works for all. For get hits, I suggest using correct clsns (I know most of my characters don't) just because there are some things that won't work right with incorrect get hit clsns

In terms of animation timings, get them in game and not from the debug viewer as they tend to be different. To get the correct timings, pause kawaks and use l shift + spacebar to frameskip. If you are getting timings from a console game, you can make a 60fps video. pcsx2 can do this regardless of the speed the game runs on your pc (hold a direction during the end of a move, so you can see the correct last frame (in case the last frame is the same as the first frame of the character stance)).

For some moves, it's sometimes best to split the animation up into parts. For example, Kyo's oniyaki. You should make the landing part separate from when he jumps (this seems obvious) but you may also want to separate it into 3 parts (startup, jumping attack, landing). Because mugen is dumb, sometimes a move with an autoguard frame will cause problems regarding the combo counter, so I would split up the part with the autoguard from the rest of the move.

Because of how the bounce states work in mugen, I would suggest moving the bouce frames (5160 etc) up by 20 pixels. You can override the bounce states (in fact I will make sure that you do (for another reason)) but I think it's best just to do it the way it's done now. I feel like it's too late to change something like that now.

There are a few non required anims that are used in KOF, check out an existing character to see what numbers they use. This will be great for consistency.

This concludes the AIR making tutorial. If you have any information that can be added or questions regarding things I may have missed, feel free to post.

Hi, I am confuse about the gethit animation timing. I have check the gethit animation timing from the game itself and not from the debug sprites viewer, it is different from your Kyo and your other Kof characters. Let's take Kyo's 5007 which is the recovery from Strong attack animation as an example, your Kyo's first three frame (5000,20 5000,10 5000,0)'s animation timing is 4 as shown in your air file, but when I look at kof98, it is for first frame: 3, second frame: 4 and third frame: 5. I wonder how do you calculate that the three frames' timing is 4? This same goes to the other gethits' timing as well which is pretty different.

Some of the gethits sprites doesn't have CLSN boxes in the debug sprites viewer, for instance the tripped animation 5075,0: how do I accord to draw an accurate clsn box for this sprites?

and also:
What Jesuszilla said. 1.0 is the very best when it comes to pcsx2. If you would like, I could explain how I would synch a table for the ps2 games.
Is it possible to make a tutorial for this? I wanted to find datas for Geese Howard from Kof98um since he is not available in the original kof98.
<- I exercise like that regularly!

#### Jango

##### Re: Interactive KOF Character Tutorial
#47  June 25, 2015, 10:07:25 am
• Double-Crosser
• I'm not standing out. This isn't weird at all.
Then don't draw them? Don't think you're supposed to draw CLSN on trip animations.

#### Koop

##### Re: Interactive KOF Character Tutorial
#48  June 25, 2015, 01:03:06 pm
• ???
Do draw them! Use something generic for compatibilities sake.

#### Niitris

##### Re: Interactive KOF Character Tutorial
#49  June 25, 2015, 01:04:10 pm
Iirc they have to be present or P2 will be able to move through P1.

#### Websta

##### Re: Interactive KOF Character Tutorial
#50  June 25, 2015, 01:07:27 pm
• play more SNK games
• I FUCKING LOVE PLATINUM!
You should definitely draw them, some characters combo from trip states

#### tehdevil

##### Re: Interactive KOF Character Tutorial
#51  June 26, 2015, 12:16:56 pm
of course a collision box is needed for the trip sprites and all of the gethits sprites, otherwise I could have walk through the opponent after hitting him. It is just that some of the gethits doesn't have collision box in the debug viewer and I am not sure if it advisable to use other gethit's collision box on the gethit's sprites that doesn't have collision box? I normally trace the collision box from the debug sprite viewer's collision box to make hitbox.
<- I exercise like that regularly!

#### Mature4evr

##### Re: Interactive KOF Character Tutorial
#52  January 19, 2016, 08:13:14 pm
• Frozen in Time
• The seige continues...
@Koop:
Given that I fully grasp the steps of this tutorial, I don't suppose you'd have any recommendations in the instance that the emulator (version 1.64) doesn't allow me to control the debug object?
Latest Release: Here / Current Projects: Belated Halloween Stage Pack & Sprite Ripping for ???

#### Koop

##### Re: Interactive KOF Character Tutorial
#53  January 19, 2016, 08:33:17 pm
• ???
I've never come across that issue. If you are having issues with that version I suggest looking for a 1.55 version of Kawaks.

#### tehdevil

##### Re: Interactive KOF Character Tutorial
#54  June 26, 2016, 04:53:40 pm
<- I exercise like that regularly!

#### Niitris

##### Re: Interactive KOF Character Tutorial
#55  June 26, 2016, 04:58:48 pm
Oh nice, I was just looking at collision boxes for vanilla 2K2. Not sure how different they are from 02UM.

Doesn't seem to have special moves sadly but it's something.
Last Edit: June 26, 2016, 05:03:41 pm by Niitris

#### Zzyzzyxx

##### Re: Interactive KOF Character Tutorial
#56  July 16, 2016, 09:27:56 am
• I hate coding helpers.

#### Niitris

##### Re: Interactive KOF Character Tutorial
#57  July 16, 2016, 09:43:25 am
Last Edit: July 16, 2016, 09:49:56 am by Niitris

#### Koop

##### Re: Interactive KOF Character Tutorial
#58  July 16, 2016, 01:57:35 pm
• ???
A very nice development.

#### Slivern

##### Re: Interactive KOF Character Tutorial
#59  July 22, 2016, 09:20:19 am
• WE ARE NESTS: THE NEW WORLD ORDER
Hi. I'm looking into making a KoF character for M.U.G.E.N (it's actually my first character for the engine as well), but I get the impression that the tutorial you have assumes that the viewer is already an experienced M.U.G.E.N creator, so I'm kind of lost already. Do you think I should focus on making other types of characters for the game before I jump into your tutorial and continuing making a KoF character? I want to specifically make a version of NESTS Kyo (at least that's what it'll be). I currently use FF3.

#### Koop

##### Re: Interactive KOF Character Tutorial
#60  July 22, 2016, 02:14:47 pm
• ???
Oh! You are quite right. I always wondered if there was a need for a more layman like tutorial. The docs that come with mugen are very informative. I still look at them from time to time.

I think you should start wherever you want to start.