Table of Contents

General Information Packet (0xBF)

Moongate Packet Classes

  • GeneralInformationPacket (Incoming, Variable, length -1) from src/Moongate.Network.Packets/Incoming/GeneralInformation/GeneralInformationPacket.cs
  • MovementSpeedControlPacket (Outgoing, Fixed, length 6) from src/Moongate.Network.Packets/Outgoing/Movement/MovementSpeedControlPacket.cs

Current Moongate Behavior

Moongate currently has packet classes for this opcode.

Packet Build

Type Field
BYTE[1] Command
BYTE[2] Length
BYTE[2] Subcommand
BYTE[length-5] Subcommand details

Subcommand Build

Subcommand 1: Initialize Fast Walk Prevention

Type Field
BYTE[4] key1
BYTE[4] key2
BYTE[4] key3
BYTE[4] key4
BYTE[4] key5
BYTE[4] key6

Subcommand 2: Add key to Fast Walk Stack

Type Field
BYTE[4] newkey

Subcommand 4: "Close Generic Gump"

Type Field
BYTE[4] dialogID // which gump to destroy (second ID in 0xB0 packet)
BYTE[4] buttonId // response buttonID for packet 0xB1

Subcommand 5: Screen size

Type Field
BYTE[2] unknown1 , always 0 ?
BYTE[2] X
BYTE[2] Y
BYTE[2] unknown2

---- Start of Subcommand 0x6 ----

Subcommand 6: Party System

Subsubcommands for 6:

Name Value
Subsubcommand 1 Add a party member (4 bytes)
Type Field
BYTE[4] id (if 0, a targeting cursor appears)Client Message

Subsubcommand 1: Add party member(s) (1+ numMembers*4)

Type Field
BYTE[1] number of Members (total number of members in the party)

Then, for each member in numMembers:

Type Field
BYTE[4] id

Server Message

Subsubcommand 2: Remove a party member (4 bytes)

Type Field
BYTE[4] id (if 0, a targeting cursor appears)

Client message

Subsubcommand 2: Remove a party member (? Bytes)

Type Field
BYTE[1] number of Members (total number of members in the new party)
BYTE[4] idofPlayerRemoved

Then, for each member in numMembers:

Type Field
BYTE[4] id

Server message

Subsubcommand 3: Tell party member a message (Variable # of bytes)

Type Field
BYTE[4] id (of target, from client, of source, from server)

BYTE[n][2] Null terminated Unicode message.

Client & Server Message

Subsubcommand 4: Tell full party a message (Variable # of bytes)

BYTE[n][2] Null terminated Unicode message.

Client Message.

Subsubcommand 4: Tell full party a message (Variable # of bytes)

Type Field
BYTE[4] id (of source)

BYTE[n][2] Null terminated Unicode message.

Server Message

Subsubcommand 6: Party Can Loot Me? (1 byte)

Type Field
BYTE[1] canloot (0=no, 1=yes)

Client message

Subsubcommand 7: party invitation?

Type Field
BYTE[4] serial (party leader)

Subsubcommand 8: Accept join party invitation (4 bytes)

Type Field
BYTE[4] serial (party leader)

Client message

Subsubcommand 9: Decline join party invitation (4 bytes)

Type Field
BYTE[4] serial (party leader)

Client message

---- End of Subcommand 0x6 ----

Subcommand 8: Set cursor hue / Set MAP

Type Field
BYTE[1] hue (0 = Felucca, unhued / BRITANNIA map. 1 = Trammel, hued gold / BRITANNIA map, 2 = (switch to) ILSHENAR map)

Subcommand 0x0a: wrestling stun

Sent by using the client Wrestle Stun Macro key in Options. This is no longer used since AoS was introduced. The Macro selection that used it was removed.

Subcommand 0x0b: Client Language

Type Field
BYTE[3] language (ENU, for English)

Subcommand 0x0c: Closed Status Gump

Type Field
BYTE[4] id (character id)

Subcommand 0x0e: 3D Client Action

Type Field
BYTE[4] Animation ID. See Notes for list.

Subcommand 0x0f: ClientType , send once at login

Type Field
BYTE[1] unk1 0x0a
BYTE[4] clienttype flag (like char create/login)

Subcommand 0x10: unknown, related to 0xD6 Mega Cliloc somehow

Type Field
BYTE[4] Item ID
BYTE[4] Unknown

Subcommand 0x13: Request popup menu

Type Field
BYTE[4] id (character id)

Subcommand 0x14: Display Popup/context menu (2D and KR)

Type Field
BYTE[1] unknown (0x00)
BYTE[1] subsubcommand (0x01 for 2D, 0x02 for KR)
BYTE[4] Serial
BYTE[1] Number of entries in the popup/context

2D-client:

  • loop Entries
Type Field
BYTE[2] Unique ID (returned by client)
BYTE[2] Cliloc ID (ID is Cliloc - 3000000)
BYTE[2] Flags 0x00=enabled, 0x01=disabled, 0x02=arrow, 0x20 = color

If (Flags = 0x20)

Type Field
BYTE[2] color/hue; // rgb 1555 color (ex, 0 = transparent, 0x8000 = solid black, 0x1F = blue, 0x3E0 = green, 0x7C00 = red)

Endif

endloop(entries)

KR-client:

  • loop Entries
Type Field
BYTE[4] Text ID Number?
BYTE[2] Index of entry (entry tag)?
BYTE[2] Flags 0x00=enabled, 0x01=disabled, 0x04 = highlighted

endloop(entries)

Subcommand 0x15: Popup Entry Selection

Type Field
BYTE[4] Character ID
BYTE[2] Entry Tag for line selected provided in subcommand 0x14

Subcommand 0x16: Close User Interface Windows

Type Field
BYTE[4] Window ID

Window ID: s

0x01: Paperdoll

0x02: Status

0x08: Character Profile

0x0C: Container

Type Field
BYTE[4] if ( Window ID == 0x0C ) Container Serial, Else character serial

Subcommand 0x17: Codex of wisdom

Type Field
BYTE[1] unknown, always 1. if not 1, packet seems to have no effect
BYTE[4] msg number
BYTE[1] presentation (0: flashing, 1: directly opening)

Subcommand 0x18: Enable map-diff (files)

Type Field
BYTE[4] Number of maps

For each map

Type Field
BYTE[4] Number of map patches in this map
BYTE[4] Number of static patches in this map

Subcommand: 0x19: Extended stats

Type Field
BYTE[1] subsubcommand (0x2 for 2D client, 0x5 for KR client)
BYTE[4] serial
BYTE[1] unknown (always 0)
BYTE[1] Lock flags (0 = up, 1 = down, 2 = locked, FF = update mobile status animation ( KR only )

Lock flags = 00SSDDII ( in binary )

00 = up

01 = down

10 = locked

If(subsubcommand = 0x05 (KR))

If(Lock flags = 0xFF) //Update mobile status animation

Type Field
BYTE[1] Status // Unveryfied if lock flags == FF the locks will be handled here
BYTE[1] unknown (0x00)
BYTE[1] Animation
BYTE[1] unknown (0x00)
BYTE[1] Frame

else

Type Field
BYTE[1] unknown (0x00)
BYTE[4] unknown (0x00000000)

endif

endif

Subcommand: 0x1a: Extended stats

Type Field
BYTE[1] stat // 0: str, 1: dex, 2:int
BYTE[1] status // 0: up, 1:down, 2: locked

Subcommand 0x1b: New Spellbook

Type Field
BYTE[2] unknown, always 1
BYTE[4] Spellbook serial
BYTE[2] Item Id
BYTE[2] scroll offset // 1==regular, 101=necro, 201=paladin, 401=bushido, 501=ninjitsu, 601=spellweaving
BYTE[8] spellbook content // first bit of first byte = spell #1, second bit of first byte = spell #2, first bit of second byte = spell #8, etc

Subcommand 0x1c: Spell selected, client side

Type Field
BYTE[2] unknown, always 2
BYTE[2] selected spell(0-indexed)+scroll offset from sub 0x1b

Subcommand 0x1D: Send House Revision State

byte[4] houseserial

byte[4] revision state

Subcommand 0x1E:

  • byte[4] houseserial
  • Subcommand 0x20: Custom Housing.
Type Field
BYTE[4] houseserial
BYTE[1] type ( 0x01=Update, 0x04=Begin, 0x05=End )

if ( type == Update )

Type Field
BYTE[2] Tile graphic
BYTE[2] X
BYTE[2] Y
BYTE[1] Z

else

Type Field
BYTE[2] 0x00
BYTE[4] 0xFFFFFFFF
BYTE[1] 0xFF

Subcommand 0x21: (AOS) Ability icon confirm.

Note: no data, just (bf 00 05 21)

Subcommand 0x22: Damage

Type Field
BYTE[2] unknown, always 1
BYTE[4] Serial
BYTE[1] Damage // how much damage was done ?

Subcommand 0x24: UnKnown

Type Field
BYTE[1] unknown. UOSE Introduced

Subcommand 0x25: SE Ability Change

Type Field
BYTE[1] Ability ID
BYTE[1] 0/1 On/Off

Subcommand 0x26: Mount Speed

Type Field
BYTE[1] 0=normal,1=fast,2=slow, >2=Hybrid movement?

Subcommand 0x2A: Change Race Request (only 2D, Server packet)

Type Field
BYTE[1] Female (1=true, 0=false)
BYTE[1] Race (1=human, 2=elf, 3=gargoyle, 255=error)

Subcommand 0x2A: Change Race Response (only 2D, Client packet)

Type Field
BYTE[2] Skin color
BYTE[2] Hair style
BYTE[2] Hair color
BYTE[2] Beard style
BYTE[2] Beard color

Subcommand 0x2C: Use targeted item (client side packet)

Byte[4] Item Serial

Byte[4] Target Serial

Subcommand 0x2D: Cast targeted spell (client side packet)

Byte[2] Spell ID

Byte[4] Target Serial

Subcommand 0x2E: Use targeted skill (client side packet)

Byte[2] Skill ID (1 to 55, if Skill Id = 0 -> last skill)

Byte[4] Target Serial

Subcommand 0x2F: KR House Menu Gump

todo: there are a lot of subsub commands...

Subcommand 0x32: Toggle gargoyle flying

Byte[4] unk1 (always 0x0100)

Byte[2] unk2 (always 0x0)

Notes

Subcommand 1: Server Sent. This sets up stack on the client and whenever it moves, it takes the top value from this stack and uses it. (key1 starts at the top, key6 at the bottom)

Subcommand 2: Server Sent. This key is added to the top of the stack. In other words, it's the one that will be used next. Basically, the other 5 only get used when the client is sending moves faster than the server is responding.

Subcommand 4: Server Sent.

Subcommand 5: Client Sent.

Subcommand 6: Sent by both. Contains subcommands for 0x6 for the party system. Be sure you check the packet listing good before attempting these.

Subcommand 8: Server Sent.

Subcommand a: Read above. Client Sent.

Subcommand b: Client Sent once at login of character.

Subcommand c: Client Sent when they close their status bar.

Subcommand e: Client Sent. Server responds with Play Animation packets.

List of animation IDs:

  • 00 00 00 06 - Yawn 00 00 00 15 - Faint

00 00 00 20 - Bow

00 00 00 21 - Salute

00 00 00 64 - Applaud

00 00 00 66 - Argue

00 00 00 68 - Blow Kiss

00 00 00 69 - Formal Bow

00 00 00 6B - Cover Ears

00 00 00 6C - Curtsey

00 00 00 6D - Jig

00 00 00 6E - Folk Dance

00 00 00 6F - Dance

00 00 00 70 - Tribal Dance

00 00 00 71 - Fold Arms

00 00 00 72 - Impatient

00 00 00 73 - Lecture

00 00 00 74 - Nod

00 00 00 75 - Point

00 00 00 77 - Greet Salute

00 00 00 79 - Shake Head

00 00 00 7B - Victory

00 00 00 7C - Celebrate

00 00 00 7D - Wave

00 00 00 7E - Two Handed Wave

00 00 00 7F - Long Distance Wave

00 00 00 80 - What?

Subcommand f: Client Sent.

Subcommand 13: Client Sent.

Subcommand 14: Server Sent. TextID is broken into two decimal parts:

stringID / 1000: intloc fileID

stringID % 1000: text index

So, say you want the 123rd text entry of intloc06, the stringID would be 6123. Newer clients without the intloc files, that use single Cliloc files, use the math ID - 3000000 for the ID to send.

Subcommand 15: Client Sent.

Subcommand 16: Server Sent.

Subcommand 17: Server Sent. Shows codex of wisdom's text #msg. (msg is linearised (including sub indices) index number starting with 1).

Subcommand 18: Server Sent. Number of maps: currently 3 (0 = Fellucca, 1 = Trammel, and 2 = Ilshenar). This packet is sent by the server to the client, telling the client to use the mapdif* and stadif* files for patching map and statics.

Subcommand 19: Server Sent. Is sent after the 0x11 packet to enable the stat locks and show their states on 4.x+ clients.

Subcommand 1a: Client Sent. Stat Lock change packet. Sent when client changes the lock state for a stat on the status bar.

Subcommand 1b: Server Sent. Related to new spell packet 0xBF Subcommand 0x1C.

Subcommand 1c: Client Sent. Related to new spellbook packet 0xBF Subcommand 0x1b.

Subcommand 1d: Server Sent. Part of AoS Custom Housing. Sends a house Revision number for handling client multi cache. If revision is newer than what client has it asks for the new multi packets to cache it.

Subcommand 1e: Client Sent. Part of AoS Custom Housing. Sends a houses ID number back after recieving the 0x1D subcommand

Subcommand 0x20: Server Sent.

Subcommand 21: Server Sent. This is sent to reset the color of the icons, and also sent when the server denies the ability attempt (not enough skill or mana).

Subcommand 22: Server Sent. Packet for displaying damage dealt above the mobs head.

Subcommand 24: Client Sent. Unknown.

Subcommand 0x25: Server Sent. Toggles SE Abilities.

Subcommand 0x26: Server Sent. Toggles Running at mount speed, even when not mounted.

Subcommand 0x2C: Client Sent. For use with the new Bandage Self client macro. Introduced in 5.0.4x

Subcommand 0x2D: Spell Ids

0x01 - 0x40 - Mage Spells

0x65 - 0x75 - Necromancer Spells

0xC9 - 0xD2 - Paladin Spells

0x91 - 0x96 - Samurai Spells

0xF5 - 0xFC - Ninja Spells

0x59 - 0x68 - Spellweaving Spells