Enums and Identifiers¶
Every numeric constant the JSON files use, in one place, plus the identifier tables you need to reference Classic content.
Animation slots¶
animations.json animations and logic.json animationsLogic are indexed by animation id. For entities built on Classic behaviour, animation id i corresponds to the original AnimationId value i * 2.
Everything that names an animation — JumpToAnimationEvent.animationId, OffsetData.opponentAnimation, SpawnItemEvent.animationId, ReferenceBehaviourData.animationId — uses the id in the first column.
| Id | AnimationId |
Meaning |
|---|---|---|
| 0 | 0x00 | Standing |
| 1 | 0x02 | Walk |
| 2 | 0x04 | Jump |
| 3 | 0x06 | Grab jump |
| 4 | 0x08 | Grab front |
| 5 | 0x0A | Grab back |
| 6 | 0x0C | Being front grabbed |
| 7 | 0x0E | Being back grabbed |
| 8 | 0x10 | Being grab hit |
| 9 | 0x12 | Being hit |
| 10 | 0x14 | Knocked down |
| 11 | 0x16 | Lying down |
| 12 | 0x18 | Stand up |
| 13 | 0x1A | Electrocuted |
| 14 | 0x1C | Pick |
| 15 | 0x1E | Land from jump |
| 16 | 0x20 | Land from jump kick |
| 17 | 0x22 | Fall |
| 18 | 0x24 | Front slammed by Max |
| 19 | 0x26 | Back slammed by Axel |
| 20 | 0x28 | Back slammed by Max |
| 21 | 0x2A | Front slammed by Blaze |
| 22 | 0x2C | Thrown by Max |
| 23 | 0x2E | Being atomic dropped |
| 24 | 0x30 | Front grab throw |
| 25 | 0x32 | Back grab throw |
| 26 | 0x34 | Static jump attack |
| 27 | 0x36 | Jump forward attack |
| 28 | 0x38 | Jump down attack |
| 29 | 0x3A | Normal punch |
| 30 | 0x3C | Third punch |
| 31 | 0x3E | Combo end A |
| 32 | 0x40 | Combo end B |
| 33 | 0x42 | Grab attack |
| 34 | 0x44 | Grab combo end |
| 35 | 0x46 | Defensive special |
| 36 | 0x48 | Blitz |
| 37 | 0x4A | Offensive special |
| 38 | 0x4C | Back attack |
| 39 | 0x4E | Static grab attack |
| 40 | 0x50 | Throw |
| 41 | 0x52 | Atomic drop |
| 42 | 0x54 | Use knife |
| 43 | 0x56 | Use pipe |
| 44 | 0x58 | Weapon throw |
| 45 | 0x5A | Use sword |
| 46 | 0x5C | Use kunai |
| 47 | 0x5E | unused |
| 48 | 0x60 | unused |
| 49 | 0x62 | Hold-B attack |
| 50 | 0x64 | Use knife extra |
Ids 47 and 48 have no Classic meaning and are free for custom animations, as is anything from 51 upwards. Custom entities are not limited to this table: an entity that drives itself entirely with events and scripts can use any index it likes, as long as animations.json and animationsLogic agree.
Entity types¶
logic.json entityType:
| Value | Name | Meaning |
|---|---|---|
| 0 | Player | Playable character. |
| 1 | BasicEnemy | Common street enemy. The difficulty system may multiply these. |
| 2 | Enemy | Boss-class enemy. |
| 3 | PickUpItem | Weapon, food, or score pickup. |
| 4 | Container | Breakable object holding something. |
| 5 | Scenery | Non-interactive object. |
| 6 | Other | Anything else, such as effects. |
The Character Editor only offers 0-3. Values 4-6 are authored by hand or produced by the ROM importer.
Audio channels¶
channel on SoundEvent, HitboxData, and projectileHitSoundChannel:
| Value | Name |
|---|---|
| 0 | sfx |
| 1 | sfxBgm |
| 2 | voice |
| 3 | prioritary |
Sounds sharing a slot cut each other off. The runtime treats the value as a plain index and allocates as many slots as it encounters, so any non-negative number is a valid private channel — useful when a sound must not be interrupted by anything else. Existing mods use values well above 3 for exactly this.
Input buttons¶
JumpToAnimationOnInputButton.input is a flag value from InputButtons:
| Value | Button | Value | Button |
|---|---|---|---|
| 1 | Up | 256 | Hold Up |
| 2 | Down | 512 | Hold Down |
| 4 | Left | 1024 | Hold Left |
| 8 | Right | 2048 | Hold Right |
| 16 | B | 4096 | Hold B |
| 32 | C | 8192 | Hold C |
| 64 | A | 16384 | Hold A |
| 128 | Start | 32768 | Hold Start |
| 65536 | X | 262144 | Hold X |
| 131072 | Y | 524288 | Hold Y |
| 1048576 | Z | 4194304 | Hold Z |
0 is Empty.
Input combos¶
JumpToAnimationOnInputCombo.input is a string, one character per step, matched in order:
| Character | Step |
|---|---|
^ |
Up |
v |
Down |
< |
Left |
> |
Right |
a b c x y z |
Face buttons |
Parsed case-insensitively. Left and right mirror with facing, so a combo authored facing right also works facing left. Any other character is ignored as an Empty step, which will never match.
Examples: "vv" is down, down. "v>a" is down, forward, A.
Weapon angles¶
AnimationFrameWeaponData.direction:
| Value | Angle | Value | Angle |
|---|---|---|---|
| 0 | Up | 4 | Down |
| 1 | Up-left | 5 | Down-right |
| 2 | Left | 6 | Right |
| 3 | Down-left | 7 | Up-right |
Scene enums¶
| Enum | Field | Values |
|---|---|---|
| Scene enter | sceneEnterCodeId |
0 JumpInFromTop, 1 Standing, 2 WalkFromLeft, 3 StartAhead |
| Scene exit | sceneExitCodeId |
0 None, 1 SimpleFadeOut, 2 LeaveToTheRight, 3 BreakTruckDoor, 4 EnterBaseballElevator, 5 LeaveBaseballElevator, 6 Level8ElevatorHealth, 7 LevelEnding, 8 EndGame |
| Screen shake | screenShakeType |
0 Default, 1 Truck, 2 Boat |
| Start offset | startOffsetType |
0 Default, 1 ClosedRoom, 2 Stage1Poster, 3 Stage3SwingingBoat, 4 Stage5TopBoat, 5 Stage7Elevator, 6 Stage8Elevator |
| Wall shape | shapeType |
0 Wall, 1 Treadmill, 2 Pit, 3 Custom1, 4 Custom2 |
| Layer update | updateType |
0 Normal, 1 BackyardRain, 2 TruckBrokenDoor, 3 Stage4Elevator, 4 ArenaSpectators, 5 Stage7Elevator, 6 Stage7ElevatorExtra, 7 Stage8Elevator, 8 AntiCameraY, 9 WaveEffect, 10 SmallWaveEffect, 11 SwingingBoat |
Wall flag bits on wallFlags: 1 left wall, 2 right wall, 4 left wall is vertical.
Session enums¶
config.json settings.bufferGlitchFixMode:
| Value | Name | Meaning |
|---|---|---|
| 0 | NoFix | Reproduce the original sprite buffer glitch. |
| 1 | AllButGroundUpper | Fix everything except the upper ground layer. |
| 2 | All | Fix the glitch everywhere. |
Classic entity names¶
The Classic pack is extracted from the original ROM. Use these exact names in entityName, in Entity Replacements/Classic/<name>/ folders, and in Palettes/Classic/<name>/ folders.
Players: Max, Axel, Blaze, Skate.
Enemies: Galsia, Donovan, Jack, Barbon, Electra, Signal, Biker, Ninja, Bongo, Hakuyo, Kickboxer, Jet, Zamza, R.Bear, Abadede, Particle, Mr.X, Shiva, Ninja (Kunai), Ninja (Sword), Blast, Vehelits, Vehelits (2).
Enemy variants: Galsia (2), Galsia (3), Barbon Jacket.
Weapons and pickups: Knife, Pipe, Sword, Kunai, Grenade, Cash Bag, Gold Bars, 1UP, Apple, Chicken.
Containers and scenery: Bin, Manhole, Lamp, Menu, Table, Table (2), Table (3), Table (4), Chair, Trash Can, Oil Barrel, Truck door debris, Truck door debris (2), Electric box, Electric box (2), Barrier, Light, Arcade, Ship Pole, Obj 2, Obj 3, Obj 4, Obj 5, Sandbag, Sandbag (2), Sandbag (3), Sandbag (4), Crate, Metal Crate, Vase, Alien Egg.
Interface and effects: Arrow, 1P, 2P, Go, Sunset Alphabet, Shadow, BlueHit, SmallHit, BigHit, GroundDust.
Names are matched exactly, including spaces, capitalisation, and punctuation. R.Bear has no space; Ninja (Kunai) has one before the bracket.
The name hash¶
Pack names and entity names are reduced internally to a 32-bit signed hash. You never need to compute this yourself except for allowedCharacters in config.json, which stores hashes rather than names.
hash = 23
for each character c in the name:
hash = (hash * 31 + codepoint(c)) wrapped to signed 32-bit
An empty or null name hashes to 0.
A pack with an id is identified by the hash of its id instead of its name: the same function over the id in its canonical form, lowercase and hyphenated (3f6c2a9e-8b1d-4c57-9e2f-7a0d5b4c1e88).
In Python:
def name_hash(name: str) -> int:
if not name:
return 0
h = 23
for ch in name:
h = (h * 31 + ord(ch)) & 0xFFFFFFFF
return h - 0x100000000 if h >= 0x80000000 else h
Related pages¶
- Behaviour Modes for the per-character move controller tables.
- Animation Naming Conventions
- Logic Events