Jump to content

Help me pls at Interiors


K4stic

Recommended Posts

Posted

There is no direct way to check it. You just have to make your own events for those.

If you're making your own interior system, I don't think it should be too hard ;)

I have suggested a couple events for detection but to be honest they're useless after all (http://bugs.multitheftauto.com/view.php?id=6977).

If I helped you, please click the like button on the right ;) Thanks!

Posted

Maybe this could help:

getElementInterior 

Try something like this to get the players interior:

local interior = getElementInterior(thePlayer)

outputChatBox("This player is in interior:"..interior, thePlayer, 255, 255, 0)

And now Aurora is back again, pm for more info.

Ex. Lead dev & L6 Staff at AUR, NGC, MTA RP & SAA.

Ex. Developer at Community of Social Gamers - CSG

Ex Founder of International Gaming Community - IGC and Union of Individual Players- UIP

9o6E8.png Ab-47

Posted
Maybe this could help:
getElementInterior 

Try something like this to get the players interior:

local interior = getElementInterior(thePlayer)

outputChatBox("This player is in interior:"..interior, thePlayer, 255, 255, 0)

That's not what he wanted. He wanted a script that would trigger only when a player has changed interior. For example, I change interior from 0 to 1, it would trigger something in his code. But there is no direct way to do this unless you had your own interior system, which would handle all interior changes itself.

If I helped you, please click the like button on the right ;) Thanks!

Posted

will i think you'll use dxDrawText then check of the player interior as @Ab-47 said

Ex:

function getHisInterior(thePlayer) 
local i = getElementInterior(thePlayer) 
  
local dxDrawText("he is in ".. i .." interior !",815,125,988,188, tocolor(0, 200, 0, 255), 1, "default-bold", "left", "top", false, false, false) 
end 
addEventHandler( "onClientResourceStart", resourceRoot, getHisInterior) 

To Visit Us

Press Here: mtasa://5.9.206.180:22002

b648040241b8f01.png

0d0a7bb38ca13e5.png

Posted
will i think you'll use dxDrawText then check of the player interior as @Ab-47 said

Ex:

function getHisInterior(thePlayer) 
local i = getElementInterior(thePlayer) 
  
local dxDrawText("he is in ".. i .." interior !",815,125,988,188, tocolor(0, 200, 0, 255), 1, "default-bold", "left", "top", false, false, false) 
end 
addEventHandler( "onClientResourceStart", resourceRoot, getHisInterior) 

Once again, he did not ask for that. Secondly, your code makes no sense and is absolutely irrelevant to the issue. Read replies before posting, honestly.

If I helped you, please click the like button on the right ;) Thanks!

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...