Add new public var with mapname and new constant (#687)

* Add new public var with current map name

* Add a constant to define max map's name length

* Reducing the maximum buffer size to store a map's name

* The PLATFORM_MAX_PATH constant replaced to MAX_MAPNAME_LENGTH
This commit is contained in:
KAWAI
2019-04-27 04:01:54 +05:00
committed by Vincent Herbet
parent 6bed09db57
commit 1cc7786a4c
4 changed files with 18 additions and 1 deletions

View File

@ -29,6 +29,11 @@
*/
#define MAX_STRING_LENGTH 16384
/**
* The maximum buffer size required to store a map's name.
*/
#define MAX_MAPNAME_LENGTH 64
/**
* Defines and constants related to the maximum number of clients.
*
@ -44,6 +49,11 @@
*/
public stock const MaxClients;
/**
* Current map name
*/
public stock const MapName[MAX_MAPNAME_LENGTH];
/**
* Pass this into certain functions to act as a C++ NULL
*/