Skip to content

GTA V: Franklin's house

Bob74 edited this page Nov 5, 2018 · 3 revisions

Getting the main object to interact with the interior:

Franklin = exports['bob74_ipl']:GetFranklinObject()

Coordinates

This interior can be found at:

X Y Z
-4.69 522.28 174.63

Object structure

Franklin
  +-- interiorId
  +-- Style
  |   +-- empty
  |   +-- unpacking
  |   +-- settled
  |   +-- cardboxes
  |   +-- Set(style, refresh)
  |   +-- Clear(refresh)
  +-- GlassDoor
  |   +-- opened
  |   +-- closed
  |   +-- Set(door, refresh)
  |   +-- Clear(refresh)
  +-- Details
  |   +-- flyer
  |   +-- tux
  |   +-- tshirt
  |   +-- bong
  |   +-- Enable(details, state, refresh)
  +-- LoadDefault()

Style

Setting the interior's style:

Franklin.Style.Set(style, refresh)
Parameter Description Valid values
style Empty and clean house Franklin.Style.empty
A bit of franklin's stuff Franklin.Style.unpacking
Fully decorated house Franklin.Style.settled
Franklin is moving (cardboxes everywhere) Franklin.Style.cardboxes
refresh Refresh the whole interior true or false

Removing the interior's style:

Franklin.Style.Clear(refresh)

Bedroom glass door

Setting the glass door state:

Franklin.GlassDoor.Set(door, refresh)
Parameter Description Valid values
door Door is opened Franklin.GlassDoor.opened
Door is closed Franklin.GlassDoor.closed
refresh Refresh the whole interior true or false

Removing the glass door's state:

Franklin.GlassDoor.Clear(refresh)

Details

Enable or disable some interior related details:

Franklin.Details.Enable(details, state, refresh)
Parameter Description Valid values
details Mountain flyer on the kitchen counter Franklin.Details.flyer
Tuxedo suit in the wardrobe Franklin.Details.tux
"I <3 LS" tshirt on the bed Franklin.Details.tshirt
Bong on the table Franklin.Details.bong
state Enabled or disabled true or false
refresh Refresh the whole interior true or false

Default values set by bob74_ipl

LoadDefault = function()
    Franklin.Style.Set(Franklin.Style.empty)
    Franklin.GlassDoor.Set(Franklin.GlassDoor.opened)
    Franklin.Details.Enable(Franklin.Details.flyer, false)
    Franklin.Details.Enable(Franklin.Details.tux, false)
    Franklin.Details.Enable(Franklin.Details.tshirt, false)
    Franklin.Details.Enable(Franklin.Details.bong, false)
    RefreshInterior(Franklin.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
    Franklin = exports['bob74_ipl']:GetFranklinObject()

    -- Franklin's stuff
    Franklin.Style.Set(Franklin.Style.settled)

    -- Closed glass door in the bedroom
    Franklin.GlassDoor.Set(Franklin.GlassDoor.closed)

    -- Mountain flyer on the kitchen counter
    Franklin.Details.Enable(Franklin.Details.flyer, true)

    -- Tuxedo suit in the wardrobe
    Franklin.Details.Enable(Franklin.Details.tux, true)

    -- "I <3 LS" tshirt on the bed
    Franklin.Details.Enable(Franklin.Details.tshirt, true)

    -- Bong on the table
    Franklin.Details.Enable(Franklin.Details.bong, true)

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