Streaming::streamvolIsValid

From RAGE Multiplayer Wiki
Revision as of 09:57, 23 April 2024 by Shr0x (talk | contribs) (Created page with "__NOTOC__ {{ClientsideJsFunction}} {{JSContainer| Returns true if the stream volume handle is valid and active, false if its not. === Required Arguments === *'''streamvol''' {{RageType|Handle}} === Return Value === *'''boolean''' {{RageType|Boolean}} ==Syntax== <pre> mp.game.streaming.streamvolIsValid(streamvol); </pre> ==Example== {{ClientsideCode| <syntaxhighlight lang="javascript"> const {x, y, z} = mp.players.local.position; const streamvol = mp.game.streaming.st...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Client-Side
Function

 JavaScript



JavaScript Syntax

Returns true if the stream volume handle is valid and active, false if its not.

Required Arguments

  • streamvol Handle

Return Value

  • boolean Boolean

Syntax

mp.game.streaming.streamvolIsValid(streamvol);

Example

Client-Side
const {x, y, z} = mp.players.local.position;
const streamvol = mp.game.streaming.streamvolCreateSphere(x, y, z, 1, 1);
if (mp.game.streaming.streamvolIsValid(streamvol)) {
    mp.gui.chat.push("stream vol is valid!");
}


See also