Skip to main content
Character events fire at key moments in the character lifecycle, allowing other resources to react to character creation, selection, updates, and deletion.

Server Events

All character events fire on the server-side.

Lifecycle Events

Created, Selected, Deleted

State Changes

Job changes, money changes, updates

Persistent

Save and load events

Hookable

Add custom logic to character operations

Lifecycle Events

mythic-characters:server:CharacterCreated

Fired when a new character is successfully created.
Parameters:
number
Player server ID who created the character
table
Newly created character object with all fields
Examples:

mythic-characters:server:CharacterSelected

Fired when a player selects and loads a character.
Parameters:
number
Player server ID
table
Selected character object
Examples:

mythic-characters:server:CharacterDeleted

Fired when a character is deleted.
Parameters:
number
Player server ID who deleted the character
number
SID of the deleted character
Examples:

State Change Events

mythic-characters:server:JobChanged

Fired when a character’s job or job grade changes.
Parameters:
number
Character SID
string
New job identifier
number
New job grade
string
Previous job identifier
number
Previous job grade
Examples:

mythic-characters:server:MoneyChanged

Fired when a character’s cash or bank balance changes.
Parameters:
number
Character SID
string
Account type: 'cash' or 'bank'
number
Change amount (positive = added, negative = removed)
number
New balance after change
string
Transaction reason
Examples:

Client Events

mythic-characters:client:Spawned

Fired on the client when the character spawns in the world.
Parameters:
table
Character data
table
Spawn location {x, y, z, heading}
Examples:

mythic-characters:client:CharacterUpdated

Fired on the client when character data is updated.
Examples:

Using Events for Custom Logic

Hook Into Character Creation

Track Playtime

Custom Job Logic


Best Practices

❌ Bad:
✅ Good:

Next Steps

Characters - Exports

Character management methods

Characters - Data Structure

Character data schema

Event System

Understanding the event system

Inventory Events

Inventory-related events
Event Timing: Character events fire in a specific order. Use this to your advantage - for example, CharacterCreated fires before CharacterSelected, so you can set up initial data in the creation handler.