Advertisement
Guest User

Untitled

a guest
Aug 13th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.56 KB | None | 0 0
  1. function ChairFunc()
  2.  
  3.     test = 0
  4.  
  5.     local x = math.random(1,256) //Generates the X variable
  6.     local y = math.random(1,256) //Generates the Y variable
  7.     local z = math.random(1.256) //Generates the Z variable
  8.  
  9.         local chairposition = Vector( x, y, z ) //Should generate a vector based on the random variables
  10.        
  11.     Msg(chairposition)
  12.        
  13.         //Chair Entity Spawning can go here
  14.    
  15.     test = test+1
  16.    
  17.     repeat //This repeat function is just for a test to repeat this function to make sure it selects random numbers every time.
  18.         ChairFunc()
  19.     until test = 5
  20.    
  21.     end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement