Jump to content

need help plz !


VanDal

Recommended Posts

Posted

guys can you help me in this i want to add interior to this pos :

local prisonCells = { 
{1572.83984375, -1637.4758300781, -83.001655578613}, 

and the jail map in interior "6" i need to add the interior because the cop when he arrest the crim and get him to jail the player find himself flying.

srry for the bad english.

Posted

Just add 6 inside the table:

like this

local prisonCells = { 
{1572.83984375, -1637.4758300781, -83.001655578613 , 6}, 
  
-- then use this  
  
for i , v in ipairs (prisonCells) do  
-- You code here  
end  

or

you can use

setElementInterior 

Posted
Just add 6 inside the table:

like this

local prisonCells = { 
{1572.83984375, -1637.4758300781, -83.001655578613 , 6}, 
  
-- then use this  
  
for i , v in ipairs (prisonCells) do  
-- You code here  
end  

or

you can use

setElementInterior 

ok thank you dude.

Posted

sorry my friend but can you help me more i make itl ike this :

{1572.83984375, -1637.4758300781, -83.001655578613 , 6} , 
setElementInterior(player, 6) 

}

and its give me this error :

jail_server.lua:21: '}' expected (to close '{' at line 18) near 'setElementInterior' 

Posted
It's missing: "}"
local prisonCells = { 
    {1572.83984375, -1637.4758300781, -83.001655578613 , 6}, 
} 

I already make it "}" but nothing.

but its ok i will make onther jail without interior :wink:

Posted

You can do it like this;

local prisonCells = { 
    {1572.83984375, -1637.4758300781, -83.001655578613, 6} 
} 
  
for i, v in ipairs(prisonCells) do 
    local posX, posY, posZ, theInterior = unpack(v) 
    setElementPosition(playerElement, posX, posY, posZ+1) -- Add 1 or 2 to Z Axis so the objects can load. 
    setElementInterior(playerElement, theInterior) 
end 

Posted
You can do it like this;
local prisonCells = { 
    {1572.83984375, -1637.4758300781, -83.001655578613, 6} 
} 
  
for i, v in ipairs(prisonCells) do 
    local posX, posY, posZ, theInterior = unpack(v) 
    setElementPosition(playerElement, posX, posY, posZ+1) -- Add 1 or 2 to Z Axis so the objects can load. 
    setElementInterior(playerElement, theInterior) 
end 

oh thank you realy helpful its work thnx again :wink:

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...