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.camera.focusEntity
  • lib.camera.focusHead
  • lib.camera.focusPoint
  • lib.camera.exit
  • Data Structure
Export as PDF
  1. Resources
  2. Dirk Lib
  3. Modules

Camera

Helpful camera tools for controlling the GTA camera system

Client Module - This can only be used on the client

lib.camera.focusEntity

Quickly focus a camera towards an entity

lib.camera.focusEntity(entity, data)
Parameter
Type
Required
Description

entity

Number

Entity to focus

data

Object

lib.camera.focusHead

Focus onto a ped's head with the camera, great for menus

lib.callback.focusHead(entity, data)
Parameter
Type
Required
Description

event

String

Entity to focus

data

Object

lib.camera.focusPoint

Focus onto a specific position with the camera

lib.callback.focusPoint(data)
Parameter
Type
Required
Description

data

Object

lib.camera.exit

Leave active camera

lib.callback.exit()

Data Structure

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

TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC TBC

{
    -- 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,                  
}
PreviousCallbackNextFile

Last updated 10 months ago

Camera options, refer to

Camera options, refer to

Camera options, refer to

📚
Data Structure
Data Structure
Data Structure