Jump to content

[Help] Random warp


3B00DG4MER

Recommended Posts

Hello,Today i made when Police hit a wanted player 3 times with nightstick will Jailed but

There is Problem if get him to jail,i don't want to all Players go to one Room

i have 3 Room Positions can you do players teleport to random room

1577.7109375, -1634.638671875, 548.15625

----------

1577.3759765625, -1640.029296875, 548.15625

----------

1577.7900390625, -1644.529296875, 548.15625

You use setElementPosition afiak

Link to comment
  
local jail_positions = { 
    {1577.7109375, -1634.638671875, 548.15625}, 
    {1577.3759765625, -1640.029296875, 548.15625}, 
    {1577.7900390625, -1644.529296875, 548.15625} 
} 
local random_room = math.random(1,#jail_positions) 
setElementPosition(player,jail_positions[random_room][1],jail_positions[random_room][2],jail_positions[random_room][3]) 
  

Link to comment
  
local jail_positions = { 
    {1577.7109375, -1634.638671875, 548.15625}, 
    {1577.3759765625, -1640.029296875, 548.15625}, 
    {1577.7900390625, -1644.529296875, 548.15625} 
} 
local random_room = math.random(1,#jail_positions) 
setElementPosition(player,jail_positions[random_room][1],jail_positions[random_room][2],jail_positions[random_room][3]) 
  

Thanks it's work

Link to comment

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