EntityStreamIn: Difference between revisions

From RAGE Multiplayer Wiki
No edit summary
No edit summary
Line 1: Line 1:
This function does not work for vehicles, and possibly objects
==Example==  
==Example==  



Revision as of 07:24, 18 December 2017

This function does not work for vehicles, and possibly objects

Example

Client-Side
// Other player streams in
mp.events.add('entityStreamIn', (entity) => {

    // Init 
    let player = mp.players.local;

    if (entity.type == "player") {

        // Init
        let other_player = entity;

        // Actions

    }
});