Skip to content

GTA V: Lester's Factory

Bob74 edited this page Nov 2, 2018 · 2 revisions

Getting the main object to interact with the interior:

LesterFactory = exports['bob74_ipl']:GetLesterFactoryObject()

Coordinates

This interior can be found at:

X Y Z
717.6641 -965.4236 30.395

Object structure

LesterFactory
  +-- interiorId
  +-- Details
  |   +-- bluePrint
  |   +-- bag
  |   +-- fireMan
  |   +-- armour
  |   +-- gasMask
  |   +-- janitorStuff
  |   +-- Enable(details, state, refresh)
  +-- LoadDefault()

Details

Enable or disable some interior related details:

LesterFactory.Details.Enable(details, state, refresh)
Parameter Description Valid values
details Blueprint on the office desk LesterFactory.Details.bluePrint
Bag under the office desk LesterFactory.Details.bag
Firemans helmets in the office LesterFactory.Details.fireMan
Body armor in storage LesterFactory.Details.armour
Gas mask and suit in storage LesterFactory.Details.gasMask
Janitor stuff in the storage LesterFactory.Details.janitorStuff
state Enabled or disabled true or false
refresh Refresh the whole interior true or false

Default values set by bob74_ipl

LoadDefault = function()
    LesterFactory.Details.Enable(LesterFactory.Details.bluePrint, false)
    LesterFactory.Details.Enable(LesterFactory.Details.bag, false)
    LesterFactory.Details.Enable(LesterFactory.Details.fireMan, false)
    LesterFactory.Details.Enable(LesterFactory.Details.armour, false)
    LesterFactory.Details.Enable(LesterFactory.Details.gasMask, false)
    LesterFactory.Details.Enable(LesterFactory.Details.janitorStuff, false)
    RefreshInterior(LesterFactory.interiorId)
end

Example: How to use in your own resources

You can handle and customize the interiors in your own resources using the exported functions:

Citizen.CreateThread(function()
    -- Getting the object to interact with
    LesterFactory = exports['bob74_ipl']:GetLesterFactoryObject()

    -- No blueprint
    LesterFactory.Details.Enable(LesterFactory.Details.bluePrint, false)

    -- No bag
    LesterFactory.Details.Enable(LesterFactory.Details.bag, false)

    -- Enable firemans helmets
    LesterFactory.Details.Enable(LesterFactory.Details.fireMan, true)

    -- Enable body armour
    LesterFactory.Details.Enable(LesterFactory.Details.armour, true)

    -- Enable gasmasks
    LesterFactory.Details.Enable(LesterFactory.Details.gasMask, true)

    -- No janitor stuff
    LesterFactory.Details.Enable(LesterFactory.Details.janitorStuff, false)

    RefreshInterior(LesterFactory.interiorId)
end)
Clone this wiki locally