From DarkRP
Jump to navigation Jump to search
Function name DarkRP.findEmptyPos(Vector pos, table ignore, number distance, number step, Vector area)
Find an empty position as close as possible to the given position (Note: this algorithm is slow!).
Returns: Vector pos
Part of Library: DarkRP
Realm: NewerServer.png
BBCode Link: [b][url=]DarkRP.findEmptyPos[/url][/b]

Function parameters[edit]

  1. pos (Vector)
  2. The position to check for emptiness.

  3. ignore (table) (optional)
  4. Table of things the algorithm can ignore.

  5. distance (number)
  6. The maximum distance to look for empty positions.

  7. step (number)
  8. The size of the steps to check (it places it will look are STEP units removed from one another).

  9. area (Vector)
  10. The hull to check, this is Vector(16, 16, 64) for players.

Function return values[edit]

  1. pos (Vector)
  2. A found position. When no position was found, the parameter is returned