Skip to content

GTA Online: Middle end house

Bob74 edited this page Nov 2, 2018 · 2 revisions

Getting the main object to interact with the interior:

GTAOHouseMid1 = exports['bob74_ipl']:GetGTAOHouseMid1Object()

Coordinates

This interior can be found at:

X Y Z
347.2686 -999.2955 -99.19622

Object structure

GTAOHouseMid1
  +-- interiorId
  +-- Strip
  |   +-- A
  |   +-- B
  |   +-- C
  |   +-- Enable(details, state, refresh)
  +-- Booze
  |   +-- A
  |   +-- B
  |   +-- C
  |   +-- Enable(details, state, refresh)
  +-- Smoke
  |   +-- none
  |   +-- stage1
  |   +-- stage2
  |   +-- stage3
  |   +-- Set(smoke, refresh)
  |   +-- Clear(refresh)
  +-- LoadDefault()

Strip

Setting the interior's strip-tease clothes:

GTAOHouseMid1.Strip.Enable(details, state, refresh)
Parameter Description Valid values
details Clothes on the ground, furnitures... GTAOHouseMid1.Strip.A
Clothes on the ground, furnitures... GTAOHouseMid1.Strip.B
Clothes on the ground, furnitures... GTAOHouseMid1.Strip.C
state Enabled or disabled true or false
refresh Refresh the whole interior true or false

Booze

Setting the interior's bottles:

GTAOHouseMid1.Booze.Enable(details, state, refresh)
Parameter Description Valid values
details Bottles here and there GTAOHouseMid1.Booze.A
Bottles here and there GTAOHouseMid1.Booze.B
Bottles here and there GTAOHouseMid1.Booze.C
state Enabled or disabled true or false
refresh Refresh the whole interior true or false

Smoke

Setting the smoking state:

GTAOHouseMid1.Smoke.Set(smoke, refresh)
Parameter Description Valid values
smoke No cigarettes added GTAOHouseMid1.Smoke.none
A bit of cigarettes and empty ashtrays GTAOHouseMid1.Smoke.stage1
More cigarettes and used ashtrays GTAOHouseMid1.Smoke.stage2
Lot of cigarettes and full ashtrays GTAOHouseMid1.Smoke.stage3
refresh Refresh the whole interior true or false

Removing the smoking state:

GTAOHouseMid1.Smoke.Clear(refresh)

Default values set by bob74_ipl

LoadDefault = function()
    GTAOHouseMid1.Strip.Enable({GTAOHouseMid1.Strip.A, GTAOHouseMid1.Strip.B, GTAOHouseMid1.Strip.C}, false)
    GTAOHouseMid1.Booze.Enable({GTAOHouseMid1.Booze.A, GTAOHouseMid1.Booze.B, GTAOHouseMid1.Booze.C}, false)
    GTAOHouseMid1.Smoke.Set(GTAOHouseMid1.Smoke.none, false)
    RefreshInterior(GTAOHouseMid1.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
    GTAOHouseMid1 = exports['bob74_ipl']:GetGTAOHouseMid1Object()

    -- Enable all strip-tease clothes
    GTAOHouseMid1.Strip.Enable({GTAOHouseMid1.Strip.A, GTAOHouseMid1.Strip.B, GTAOHouseMid1.Strip.C}, true)

    -- Enable a bit of booze bottles
    GTAOHouseMid1.Booze.Enable(GTAOHouseMid1.Booze.A, false)

    -- Maximum amount of cigarettes
    GTAOHouseMid1.Smoke.Set(GTAOHouseMid1.Smoke.stage3, false)
    RefreshInterior(GTAOHouseMid1.interiorId)
end)
Clone this wiki locally