Jump to content
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. Los Santos Drug Wars
      2. Updates
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Red Dead Online

      1. Blood Money
      2. Frontier Pursuits
      3. Find Lobbies & Outlaws
      4. Help & Support
    3. Crews

    1. Grand Theft Auto Series

      1. Bugs*
      2. St. Andrews Cathedral
    2. GTA VI

    3. GTA V

      1. Guides & Strategies
      2. Help & Support
    4. GTA IV

      1. The Lost and Damned
      2. The Ballad of Gay Tony
      3. Guides & Strategies
      4. Help & Support
    5. GTA San Andreas

      1. Classic GTA SA
      2. Guides & Strategies
      3. Help & Support
    6. GTA Vice City

      1. Classic GTA VC
      2. Guides & Strategies
      3. Help & Support
    7. GTA III

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    8. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    9. Top-Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    1. Red Dead Redemption 2

      1. PC
      2. Help & Support
    2. Red Dead Redemption

    1. GTA Mods

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Red Dead Mods

      1. Documentation
    3. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    4. Featured Mods

      1. Design Your Own Mission
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Rockstar Games

    2. Rockstar Collectors

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Movies & TV
      5. Music
      6. Sports
      7. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. Announcements

    2. Support

    3. Suggestions

Examples on the usage of interiors?


mockba.the.borg
 Share

Recommended Posts

mockba.the.borg

Hi there,

 

I have always been wondering how can multiple people be using the same garages simultaneously while not seeing, colliding or interfering with each other.

I suspect this is related to the INTERIOR natives, but not sure how to make it happen.

Does anyone have an usage example?

I believe an interior has to be allocated based on its coordinates, but what then? Should I teleport into it? Would I get teleported automatically into it when it is allocated?

What about cars and other props inside the garage? How can I spawn then associated to that interior?

 

Any insight on this matter would be much appreciated.

 

Thanks all,

Mockba.

 

Link to comment
Share on other sites

mockba.the.borg

Hi All,

 

I did this sequence:

 

if not natives.INTERIOR.IS_VALID_INTERIOR(_GarageInterior) then
_GarageInterior = natives.INTERIOR.GET_INTERIOR_AT_COORDS_WITH_TYPE(405.45, -955.75, -99, "v_winningroom")
end
if natives.INTERIOR.IS_INTERIOR_DISABLED(_GarageInterior) then
natives.INTERIOR.DISABLE_INTERIOR(_GarageInterior, false)
end
natives.INTERIOR._0x2CA429C029CCF247(_GarageInterior)
As seen on the race winning garage controller (and other garages as well) but it didn't seem to have an effect.
I am able to obtain an interior ID, but then I am not sure how to use it.
If anyone knows how to use interiors (or how to obtain the effect of multiple people using the same garage simultaneously without interfering with each other), please share.
Thanks a lot,
Mockba.
Link to comment
Share on other sites

mockba.the.borg

I am starting to think that the "multiple players on the same physical space" solution has to do instead with the SET_PLAYER_INVISIBLE_LOCALLY and SET_ENTITY_LOCALLY_VISIBLE natives (and its peers).

However I was not able to make it work.

Theoretically one should be able to make himself invisible (and no collision, among other things) to others, while still being visible locally. Same thing with the vehicles inside the garage, all would be invisible (and no collision) to others while visible locally.

I have tried making a vehicle invisible, then visible locally, but it doesn't seem to have effect.

 

Does anyone has any experience with these natives?

 

The code I used was:

natives.ENTITY.SET_ENTITY_VISIBLE(ent.ID, false, true)
natives.VEHICLE.SET_VEHICLE_CAN_BE_TARGETTED(ent.ID, false)
natives.ENTITY.SET_ENTITY_COLLISION(ent.ID, false, true)
natives.ENTITY.SET_ENTITY_INVINCIBLE(ent.ID, true)
natives.NETWORK.SET_ENTITY_LOCALLY_VISIBLE(ent.ID)

I was expecting that the last line would make the car visible to me again, but it doesn't.

 

Thanks,

Marcelo.

Edited by mockba.the.borg
Link to comment
Share on other sites

mockba.the.borg

After some more research I am now more convinced that the garage behavior (and the apartments as well) is more related to things and people being selectively invisible to each other.

 

Now I am not sure if it is related to the INTERIOR natives or not. (not sure yet about the usage of those)

 

Maybe someone has experience with it and could share some hints?

 

I think I will open a different thread about the usage of the locally visible natives, as is seems not to be related to Interiors.

 

Thanks in advance for any help.

 

Cheers,

Mockba.

Link to comment
Share on other sites

It looks to me the stuff you found is how Rockstar allows multiple players to own the same apartment. So if two players own Eclipse 40 and their each in that apartment, they won't see each other.

 

I can't think of any application of this. You may be able to find something in the decompiled scripts. It should be in something like mpapartment. However, it is possible that these natives are used to make other players and their vehicles transparent and non solid for things like passive mode and non contact races.

 

I don't think anyone has used these before as most of the mods on here are for single player, so they wouldn't have any application. Maybe that GTA V Multiplayer mod can use them, but I don't know.

 

Regarding the hiding of players and vehicles natives though. Rockstar should have considered having natives that will keep props spawned by the player invisible. In GTA Online, if you eat a snack in your garage, when your character drops the wrapper on the ground, it shows up in everyone's garage. lol Not sure if they have fixed this though.

  • Like 2
Link to comment
Share on other sites

mockba.the.borg

Yes ... it seems to be indeed what R* uses to make things selectively invisible.

I was able to make everything work, and I don't see any useful functionality other than online.

But as I said on another message, it is there, so I need to know it.

 

It is very sensitive information though, because it could create mayhem online if explored by hackers, so I will leave it alone and won't post any examples on it.

 

Cheers,

Mockba.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.