İçeriğe geç
Interiors

Interiors

Every interior placed in the RDR2 world, on the map and as a list: rooms, portals, entity sets, the imap it needs, and Lua to switch its entity sets.

Bu dokümanlar şimdilik İngilizce.

Open the tool Last updated

Interiors lists every interior (MLO) placed in the RDR2 world, 290 of them, as dots on the map and as a searchable list. Open one for its position, rooms, portals, entity sets and the imap that places it, set entity sets on or off, and copy the Lua that does it.

What it is for

Shops, saloons, cabins and farmhouses in RDR2 change their contents through entity sets: a clean or ransacked farmhouse, an open or closed trapdoor, stock on the shelves. The natives that switch them want the interior handle and the set’s exact name. This tool gives you both, plus the imap request for the interiors that do not exist until a script loads them.

Quick start

  1. Click a dot on the map, or search the list by interior, room or entity set name.
  2. Read the card: position, heading, which imap places it, its rooms and its entity sets.
  3. Set each entity set you want to change to on or off.
  4. Copy the Lua under the list of sets.

Finding an interior

Control What it does Default
Interior, room or entity set Search box. Matches part of an interior name, part of a room or entity set name, or the interior’s exact hash (8 hex digits, with or without 0x). empty
Only interiors that need an imap loaded Keeps the 38 interiors whose imap only loads when a script asks. off

The line under the box counts what is shown, for example 14 of 290 placed interiors for val_. Each row shows its room count and, when it has any, its entity set count.

On the map, orange dots are interiors that need their imap loaded and violet dots are always there. Zoom in and each interior also gets its outline: the footprint of its rooms, turned the way the interior stands. The open interior’s outline is drawn in white at any zoom. Names appear next to the dots once you zoom in.

The open interior is kept in the address bar as ?id=<name>, so a link opens straight on it.

The interior card

Field What it shows
Hash The interior’s hash, hex and signed
Position x, y, z, with a vector3 button that copies vector3(x, y, z)
Heading The placement heading
Placed by The imap that places it, by name or by hash, and whether that imap is loaded by script or always loaded
Portals How many portals the interior has
Rooms Every room name
Entity sets Every set with a menu (-, on, off), its name and how many entities it holds

Its doors in the Door Finder opens the Door Finder searching for this interior.

Entity sets and the code

Leave a set on - and the code does not touch it. on adds an activate call, off a deactivate call. With ransacked_abe on and clean_abe off at the Abe farmhouse:

client.lua
-- GET_INTERIOR_AT_COORDS (0xCDD36C9E5C469070): abe_farmhouse_int
local interior = Citizen.InvokeNative(0xCDD36C9E5C469070, 1786.83, -85.35, 55.94)
-- IS_VALID_INTERIOR (0x017C1B3159F79F6C)
if Citizen.InvokeNative(0x017C1B3159F79F6C, interior) then
    -- ACTIVATE_INTERIOR_ENTITY_SET (0x174D0AAB11CED739)
    Citizen.InvokeNative(0x174D0AAB11CED739, interior, "ransacked_abe", 0)
    -- DEACTIVATE_INTERIOR_ENTITY_SET (0x33B81A2C07A51FFF)
    Citizen.InvokeNative(0x33B81A2C07A51FFF, interior, "clean_abe", false)
end

When the interior’s imap only loads on request, the code requests it first. For adl_cabin01_int, whose imap is known only by hash, the code starts with:

client.lua
-- the imap that places this interior only loads when a script asks
-- REQUEST_IPL_HASH (0x59767C5A7A9AE6DA): 0x9E6F346F
Citizen.InvokeNative(0x59767C5A7A9AE6DA, -1636879249)

These are client natives: put the code in a client script.

Named and unnamed sets

The entity set natives take the set’s name, and the game stores only its hash. Of the 846 entity sets across the 290 placed interiors, 395 have a known name. The other 451 show as 0x... with no name in place of the menu, and they cannot be switched from a script until somebody finds their name.

Some interiors are almost fully covered (val_saloon_int, 7 of 7 named) and some not at all (val_gunsmith_int_main, 0 of 17). The biggest list is val_genstore with 66 sets, 18 of them named.

Tips

  • Set names often read as pairs: clean_abe and ransacked_abe, adl_winter01_trapdoorclosed and adl_winter01_trapdooropen. To swap one for the other, turn one on and the other off in the same snippet.
  • The count next to a set is how many entities it holds. A set with 1 entity is a single prop; one with a few hundred is the whole dressing of the room.
  • Search part of a room name such as room_workshop to find every interior that has one.
  • Paste the vector3 into your own script when you need the interior’s position for a distance check.

Common mistakes

  • Nothing switches. The code only switches sets when GET_INTERIOR_AT_COORDS hands back a valid interior. If it does not (for example because the interior’s imap was never requested), IS_VALID_INTERIOR fails and the code inside the if quietly does nothing. Keep the imap request at the top, and add a print in an else branch while testing.
  • Using a set from another interior. Set names are per interior. A name from one interior does nothing in another.

Limitations

  • 451 of the 846 entity sets have no known name and cannot be switched.
  • One interior is listed only by hash, and 32 are placed by an imap whose name is not known (it is shown and requested by hash).
  • Some interiors are placed in more than one spot: the 290 rows are 279 different interiors. Each placement is its own row with its own position, so check the position before you copy.
  • The site cannot check the result in game. The snippet switches the sets; whether the interior redraws straight away is not something the site has verified.