GetGuestPlayers

From Multi Theft Auto: Wiki
Jump to navigation Jump to search

Syntax

table getGuestPlayers (  )

Returns

Returns All Players not Login or All Players Guest Account , And vice false

Code

Click to collapse [-]
Server
function getGuestPlayers (  )
 
    local Guest = { } ;
 
    for _ , players_ in ipairs ( getElementsByType ( "player" ) ) do
 
    local playerAcc = getPlayerAccount ( players_ )
 
    if isGuestAccount ( playerAcc ) then
 
    table.insert ( Guest , players_ )
 
                end
            end 
        return Guest
    end