DirkScripts Documentation
  • 👋Welcome
  • The Basics
    • ⬇️Installing Resources
  • Resources
    • 📚Dirk Lib
      • Getting Started
      • Cache
      • Modules
        • Await
        • Blip
        • Callback
        • Camera
        • File
        • Interact
        • Objects
        • Player
          • Client
          • Server
        • Groups
          • Client
          • Server
        • Print
        • Request
        • Table
        • Target
        • Zones
        • UI
          • Context
          • Untitled
    • 🔧Project Cars
      • Installation
      • Tools
      • Parts
      • Commands
    • 🤼Multicharacter
      • Installation
      • Configuration
      • Exports
      • F.A.Q
      • Commands
    • 💊Drug Labs v2
      • Installation
      • Tebex Integration
      • Creating Labs
  • 🛒Store
  • 🗣️Discord
  • 🖥️GitHub
Powered by GitBook
On this page
  • lib.blip.register
  • lib.blip.get
  • lib.blip.delete
  • Data Structure
Export as PDF
  1. Resources
  2. Dirk Lib
  3. Modules

Blip

Used for GTA map location blips, for example a fuel station location

Client Module - This can only be used on the client

lib.blip.register

Register a new blip to be shown on the map

lib.blip.register(id, data)
Parameter
Type
Required
Description

id

String

Unique reference for the blip

data

Object

lib.blip.get

Get a blip's data via it's id

local blip = lib.blip.get(id)
Parameter
Type
Required
Description

id

String

Unique reference for the blip

lib.blip.delete

Remove a blip from the map and cache

lib.blip.delete(id)
Parameter
Type
Required
Description

id

String

Unique reference for the blip

Data Structure

This is the data structure of a blip and the valid options

{
    -- Required
    pos = vector2(150.0, 100.0),    -- Used as the location on the map
    name = "Example Blip",          -- Label displayed on the map key
    sprite = 1,                     -- Sprite to be displayed
    display = 4,                    -- Display options
    scale = 1.0,                    -- Size of the blip
    color = 1,                      -- Color of the blip
    -- Not Required
    shortRange = false,             -- Is the blip short range
    category = 1,                   -- Category of the blip
    alpha = 255,                    -- Alpha (opacity) of the blip
    rotation = 0,                   -- Rotation
    route = false,                  -- Should the blip be routed to
    canSee = function()             -- Should the blip render
        return true
    end,                  
}

Useful Links

PreviousAwaitNextCallback

Last updated 10 months ago

Options for the blip, see

FiveM Blip Sprites Reference:

FiveM Native SetBlipDisplay Reference:

Fivem Blip Colour Reference:

FiveM Native SetBlipCategory Reference:

📚
https://docs.fivem.net/docs/game-references/blips/#blips
https://docs.fivem.net/natives/?_0x9029B2F3DA924928
https://docs.fivem.net/docs/game-references/blips/#blip-colors
https://docs.fivem.net/natives/?_0x234CDD44D996FD9A
Data Structure