Skip to content
samp-incognito edited this page Apr 14, 2019 · 17 revisions

HomeNativesUpdates

  • Parameters:
    • None.
  • Returns:
    • Always 1.

Updates any item that is currently active (that is, moving or attached), including:

  • Moving and attached objects.
  • Attached areas and 3D text labels.

  • Parameters:
    • playerid: The player ID.
    • toggle: 0 to turn off, 1 to turn on.
  • Returns:
    • 0 on failure, 1 on success.

Toggles whether updates are issued while the player is idle.

  • By default, this is turned off.

  • Parameters:
    • playerid: The player ID.
  • Returns:
    • 0 or 1.

Returns whether Streamer_ToggleIdleUpdate is enabled for the player.


  • Parameters:
    • playerid: The player ID.
    • toggle: 0 to turn off, 1 to turn on.
  • Returns:
    • 0 on failure, 1 on success.

Toggles whether updates are based on the player's current camera position rather than the player's current world position.

  • By default, this is turned off.

  • Parameters:
    • playerid: The player ID.
  • Returns:
    • 0 or 1.

Returns whether Streamer_ToggleCameraUpdate is enabled for the player.


  • Parameters:
    • playerid: The player ID.
    • type: The item type.
    • toggle: 0 to turn off, 1 to turn on.
  • Returns:
    • 0 on failure, 1 on success.

Toggles whether updates are issued for the specified player and item type.

  • By default, every item type is turned on, except for NPCs.

  • Parameters:
    • playerid: The player ID.
    • type: The item type.
  • Returns:
    • 0 or 1.

Returns whether Streamer_ToggleItemUpdate is enabled for the specified player and item type.


  • Parameters:
    • time: The last automatic update time.
  • Returns:
    • Always 1.

Stores the time taken by the last automatic update as a float in milliseconds.


  • Parameters:
    • playerid: The player ID.
    • type: The item type.
  • Returns:
    • 0 on failure, 1 on success.

Issues an update for the player.

  • Optionally, an item type may be specified.

  • Parameters:
    • playerid: The player ID.
    • x: The game world X coordinate.
    • y: The game world Y coordinate.
    • z: The game world Z coordinate.
    • worldid: The virtual world ID.
    • interiorid: The interior ID.
    • type: The item type.
    • compensatedtime: The compensated time in milliseconds (see below).
    • freezeplayer: 0 to turn off, 1 to turn on (see below).
  • Returns:
    • 0 on failure, 1 on success.

Issues an update for the player at a specific position.

  • This can be used to preload items before setting the player's position or to stream items under OnPlayerRequestClass.
  • Optionally, a virtual world, interior, and item type may be specified.
  • If compensatedtime is set to a positive number, it can be used to specify how long, in milliseconds, future automatic updates will be paused for the player. During this time, the player's controls will be disabled (assuming freezeplayer is set to 1), and the player's position will also be set to the new coordinates.
Clone this wiki locally