API Reference

  • Extra Natives
  • CreateSpoofedVehicle: Spawns a vehicle entity at coordinates with spoofed creation semantics.
  • CreateSpoofedPed: Creates a ped with spoofed creation semantics at the given position.
  • RequestRagdoll: Requests ragdoll on a target ped/entity.
  • GetAllVehiclesModel: Returns all known vehicle models as an array of { hash, name } tables.
  • IsPlayerInvisible: Checks if a player is currently invisible.
  • SpoofPed: Enable or disable server-side ped spoofing. When enabled, queues a one-time ped change; spoof stays active until disabled.
  • LockCameraPos: Lock the gameplay camera position. Useful to make features such as Freecam, spectate, ...
  • SetCameraPos: Change the gameplay camera position when camera is locked (Susano.LockCameraPos)
  • GetCameraAngles: Get the gameplay cameras angles.
  • SendNetworkDamage: Send a synthetic network damage event from a source entity to a target entity at a world position.
  • Drawing Functions
  • SetAutoFrame: Enable or disable auto-frame mode for the current coroutine.
  • WithFrame: Execute a callback between BeginFrame and SubmitFrame automatically.
  • PushClipRect: Push a clipping rectangle onto the draw clip stack.
  • PopClipRect: Pop the last clipping rectangle from the draw clip stack.
  • WithClipRect: Execute a callback with a temporary clipping rectangle.
  • DrawTextCentered: Draw text horizontally centered at a given X position.
  • DrawTextOutlined: Draw text with a 1px outline for readability on any background.
  • DrawRoundedRect: Draw a rounded rectangle outline with rounding as a required parameter.
  • DrawRoundedRectFilled: Draw a filled rounded rectangle with rounding as a required parameter.
  • DrawShadowRect: Draw a filled rectangle with an automatic drop shadow.
  • DrawBorderRect: Draw a filled rectangle with a colored border in a single call.
  • DrawBlurRect: Draw a rectangular blur (frosted-glass) region with an optional tint.
  • BeginFrame: Start a new Lua render frame. Clears the build buffer for this tick.
  • SubmitFrame: Publish the current build buffer as the active frame to render on the Overlay.
  • ResetFrame: Clear all queued and displayed draw commands for the current Lua coroutine. Empties both build and render buffers and cancels any pending swap.
  • ResetAllFrames: Clear every coroutine’s build and render buffers. Removes all layers.
  • DrawLine: Enqueue a line in the current build buffer.
  • DrawRect: Draw a rectangle outline with optional rounding.
  • DrawRectFilled: Draw a filled rectangle with optional rounding.
  • DrawRectGradient: Enqueue a filled rectangle with gradient in the current build buffer.
  • DrawCircle: Enqueue a circle (filled or outline) in the current build buffer.
  • DrawText: Draw text at a given position with optional font.
  • GetTextWidth: Measure the pixel width of a text string at a given font size.
  • WorldToScreen: Project a 3D world position to 2D screen space.
  • LoadFont: Load a TTF/OTF font into ImGui and return its handle.
  • LoadFontFromBuffer: Load a TTF/OTF font into ImGui and return its handle.
  • PushFont: Make a previously loaded font the current font for this coroutine.
  • PopFont: Restore the previous font for this coroutine.
  • LoadTexture: Load an image file into a DX11 texture.
  • LoadTextureFromBuffer: Load a texture from raw image bytes.
  • ReleaseTexture: Free a previously loaded texture.
  • DrawImage: Draw a texture on screen with optional tint, rounding, and UVs.
  • Input Functions
  • GetAsyncKeyState: Gets the raw key state using the Windows GetAsyncKeyState function.
  • Events
  • GetAllEvent: Return all discovered events with their source resource.
  • FindEvent: Search events by name with exact or substring matching.
  • OnTriggerServerEvent: Register a Lua callback to inspect and modify outbound server events.
  • ClearOnTriggerServerEvent: Unregister the server-event callback.
  • BlockServerEvent: Block or unblock an inbound server event by name.
  • Http Request
  • HttpGet: Perform a synchronous HTTP GET.
  • HttpPost: Perform a synchronous HTTP POST with a raw payload.
  • Native Hook
  • HookNative: Allows you to hook into FiveM's native function system, giving you complete control over whether native functions execute and what values they return.
  • UnhookNative: Removes a previously registered Lua hook for a native identified by its hash. Frees the associated Lua reference.
  • UnhookAllNatives: Removes all registered Lua hooks, regardless of their hash.
  • HasNativeHookInitializationFailed: Query the status of the native hook system initialization.
  • Resource Injection
  • InjectResource: Queue Lua code for injection into a target resource's VM.
  • StopResource: Stop the requested resource with the susano resource stopper mechanism.
  • StartResource: Start the requested resource with the susano resource stopper mechanism.
  • GetInjectableResources: Returns all resource names currently available for code injection.
  • GetResourceFiles: List all Lua files within a resource by name.
  • File I/O
  • WriteFile: Write a string of data to a sandboxed .ssn file.
  • ReadFile: Read the full contents of a sandboxed .ssn file as a string.
  • Memory
  • Scan: IDA-style pattern scan with optional module and RIP-relative resolve.
  • Valid: Check whether an address points to mapped memory.
  • Module: Get the base address of a loaded module.
  • Add: Add two integers: utility for 64-bit pointer arithmetic.
  • GetProc: Get the address of an exported function via manual PE export walk.
  • Read (primitives): Read U8/U16/U32/U64, I8/I16/I32, F32/F64, and Ptr values from memory.
  • ReadStr: Read a null-terminated string.
  • ReadBytes: Read raw bytes into a Lua table.
  • Write (primitives): Write U8/U16/U32/U64, I32, F32/F64 values with automatic page-protection handling.
  • WriteBytes: Write a table of raw bytes.
  • Patch: Write raw hex bytes with automatic page-protection handling.
  • Nop: Fill bytes with 0x90 (NOP).
  • Call: Call any function at an address using the x64 calling convention.
  • Hook: Install a MinHook detour with typed argument access.
  • Unhook: Remove a hook by slot ID.
  • Alloc: Allocate a block of memory in the game process.
  • Free: Free a previously allocated block.
  • Misc
  • CopyToClipboard: Copy a string to the Windows clipboard as CF_TEXT (ANSI).
  • GetClipboardText: Get the windows clipboard content.
  • EnableOverlay: Temporarily blocks in-game input while allowing Susano’s own overlay to handle mouse interactions.
  • GetCursorPos: Returns the actual cursor position used internally by Susano’s overlay system
  • GetUUID: Return the Susano account ID of the currently logged-in user.