Developer API (Exports & Events)

Exports

This resource exposes a small set of exports intended for integration by other developers.

Names and signatures below are taken directly from the shipped code.


Client exports

exports['3M_Wargames']:IsInMatch() -> boolean

Returns whether the local player is currently in a Wargames match.

Example

if exports['3M_Wargames']:IsInMatch() then
  -- disable your job UI / prevent certain actions
end

exports['3M_Wargames']:WG_IsMeDead() -> boolean

From the ambulance bridge. Checks player death state using the configured provider (auto/wasabi/qb/esx/tk/none) and falls back to native checks when needed.

exports['3M_Wargames']:WG_ClientInstantRevive()

Forces an instant revive on the client (bridge fallback).


Server exports

exports['3M_Wargames']:WG_Revive(src)

Revives a player using the configured ambulance provider if available, otherwise falls back to Wargames instant revive.

Example

exports['3M_Wargames']:KillfeedAdd(killerId, killedId, cause, flags)

Pushes a killfeed entry (server-side helper).

  • killerId (number) server id

  • killedId (number) server id

  • cause (number) weapon hash / damage cause (0 allowed as fallback)

  • flags (table|nil) optional flags (e.g. { headshot = true })

Notes

  • Respects Config.KillFeed.mode:

    • lobby: requires both players in same routing bucket

    • global: ignores bucket mismatch

    • off: does nothing

Example

Last updated