mirror of
https://github.com/citizenfx/cfx-server-data.git
synced 2025-02-14 10:22:55 +08:00
ADD: mapmanager - getMaps function and export
This commit is contained in:
parent
051a33a116
commit
419782644a
@ -15,3 +15,4 @@ server_export "getCurrentMap"
|
|||||||
server_export "changeGameType"
|
server_export "changeGameType"
|
||||||
server_export "changeMap"
|
server_export "changeMap"
|
||||||
server_export "doesMapSupportGameType"
|
server_export "doesMapSupportGameType"
|
||||||
|
server_export "getMaps"
|
||||||
|
@ -267,6 +267,10 @@ function getCurrentMap()
|
|||||||
return currentMap
|
return currentMap
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function getMaps()
|
||||||
|
return maps
|
||||||
|
end
|
||||||
|
|
||||||
function changeGameType(gameType)
|
function changeGameType(gameType)
|
||||||
if currentMap and not doesMapSupportGameType(gameType, currentMap) then
|
if currentMap and not doesMapSupportGameType(gameType, currentMap) then
|
||||||
StopResource(currentMap)
|
StopResource(currentMap)
|
||||||
@ -301,4 +305,4 @@ function doesMapSupportGameType(gameType, map)
|
|||||||
end
|
end
|
||||||
|
|
||||||
return maps[map].gameTypes[gameType]
|
return maps[map].gameTypes[gameType]
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user