Jump to content

Where


Wei

Recommended Posts

function getServerMaps ( ) 
    local mapsTable = { } 
    for resourceKey, resourceValue in ipairs ( getResources ( ) ) do 
        local name = getResourceInfo ( resourceValue, "name" ) 
        local type = getResourceInfo ( resourceValue, "type" ) 
        local game = getResourceInfo ( resourceValue, "gamemodes" ) 
        local author = getResourceInfo ( resourceValue, "author" ) 
        if ( type == "map" and game == "race" ) then 
            table.insert ( mapsTable,  
                { 
                    resName = getResourceName ( resourceValue ),  
                    mapName = name,  
                    mapAuthor = author 
                } 
            ) 
        end 
    end 
  
    return mapsTable 
end 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...