โœฆ JVDesignStudio ยท No Sign-Up Required

MUGEN Cheat Sheet

A one-page printable reference for MUGEN file structure, CMD command syntax, CNS state definitions, triggers, controllers and hit detection. Pin it next to your monitor!

๐Ÿ“ File Structure

.defMain definition links all other files
.cmdCommand inputs for special moves
.cnsState/logic constants for the character
.airAnimation frame & collision box data
.sffSprite file all character images
.sndSound file voice clips & SFX

Fighter Factory edits all of these together in one project.

๐Ÿ•น๏ธ Basic CMD Syntax

; Quarter-circle forward + punch
[Command]
name = "QCF_P"
command = ~D, DF, F, x
time = 15

; Charge back then forward
[Command]
name = "Charge_F"
command = /$B, F, x
time = 60

~ means release, /$ means hold for the charge duration.

๐Ÿง  State Definitions

[StateDef 200]
type    = S
movetype = A
physics  = S
anim    = 200
ctrl    = 0
velset  = 0,0
poweradd = 30
juggle  = 3

type: S=stand, C=crouch, A=air. movetype: I=idle, A=attack, H=hit.

๐ŸŽฏ Common Triggers

TimeTicks since state began
AnimElemCurrent animation element/frame
CommandChecks if a CMD input matched
StateNoCurrent state number
Vel X / Vel YCurrent velocity
MoveContactTrue the frame a hit lands

๐ŸŽ›๏ธ Controllers

[State 200, ChangeState]
type = ChangeState
trigger1 = Time = 10
value = 0

[State 200, VelSet]
type = VelSet
trigger1 = Time = 0
x = 3

[State 200, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = 1,0

Controllers run actions when their trigger lines evaluate true.

๐Ÿ’ฅ Hit Detection

[State 200, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = S, NA
damage = 80,0
guardflag = MA
animtype = Light
ground.type = High
air.type = High
sparkno = 0
hitsound = 5,0

HitDef parameters describe damage, what it hits, and how the opponent reacts.

๐Ÿ–ผ๏ธ Animation (AIR)

[Begin Action 200]
Clsn1: 1
 Clsn1[0] = -10,-60,10,0
Clsn2: 1
 Clsn2[0] = -8,-58,8,2
0,0, 0,0, 5
0,1, 0,0, 5
0,2, 0,0, 8

Clsn1 = attack box, Clsn2 = vulnerable box. Each animation line is group,image, x,y, time.

๐Ÿฅ‹ Common Patterns

; A simple special move: command + state

[Command]
name = "QCF_P"
command = ~D, DF, F, x
time = 15

[Statedef -1]
[State -1, Fireball]
type = ChangeState
value = 1000
triggerall = Command = "QCF_P"
triggerall = StateNo = [0,199]
trigger1 = ctrl

[Statedef 1000]
type = S
movetype = A
physics = S
anim = 1000
ctrl = 0

[State 1000, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = S, NA
damage = 60,0
guardflag = MA

[State 1000, Explod]
type = Explod
trigger1 = AnimElem = 3
anim = 1001
pos = 60,-60
vel = 6,0

A -1 state watches for the CMD input, switches to the move's own state, fires a HitDef on the active frame, and spawns an Explod for the projectile visual.

Want to build a whole game?

Follow one of our free step-by-step workshops in the Workshop hub.

๐Ÿ”ง Browse Workshops โ†’