1416 |
} |
} |
1417 |
} |
} |
1418 |
nnextmaps[nmapstoch] = a; |
nnextmaps[nmapstoch] = a; |
1419 |
|
|
1420 |
|
new tagpath[64], sMenuOption[64]; |
1421 |
|
format(tagpath, 64, "%s/dmaptags.ini", custompath); |
1422 |
|
|
1423 |
if (iscustommap(nmaps[a]) && usestandard) { |
if (iscustommap(nmaps[a]) && usestandard) { |
1424 |
if (cstrike_running() == 1) { |
if (cstrike_running() == 1) { |
1425 |
pos += format(menu[pos], 511, "%L", LANG_PLAYER, "DMAP_CS_MENU_CUSTOM", nmapstoch + 1, nmaps[a]); |
formatex(sMenuOption, 64, "%L", LANG_PLAYER, "DMAP_CS_MENU_CUSTOM", nmapstoch + 1, nmaps[a]); |
1426 |
} else { |
} else { |
1427 |
pos += format(menu[pos], 511, "%L", LANG_PLAYER, "DMAP_MENU_CUSTOM", nmapstoch + 1, nmaps[a]); |
formatex(sMenuOption, 64, "%L", LANG_PLAYER, "DMAP_MENU_CUSTOM", nmapstoch + 1, nmaps[a]); |
1428 |
|
} |
1429 |
|
} else { // Don't show (Custom) |
1430 |
|
formatex(sMenuOption, 64, "%d. %s", nmapstoch + 1, nmaps[a]); |
1431 |
|
} |
1432 |
|
|
1433 |
|
if (file_exists(tagpath)) { // If the tag file is there, check for the extra tag |
1434 |
|
new iLine, sFullLine[64], sTagMap[32], sTagText[32], txtLen; |
1435 |
|
|
1436 |
|
while (read_file(tagpath, iLine, sFullLine, 64, txtLen)) { |
1437 |
|
if (sFullLine[0] == ';') { |
1438 |
|
iLine++; |
1439 |
|
continue; // Ignore comments |
1440 |
|
} |
1441 |
|
|
1442 |
|
strbreak(sFullLine, sTagMap, 32, sTagText, 32); // Split the map name and tag apart |
1443 |
|
|
1444 |
|
if (equali(nmaps[a], sTagMap)) { |
1445 |
|
format(sMenuOption, 64, "%s [%s]", sMenuOption, sTagText); |
1446 |
|
break; // Quit reading the file |
1447 |
|
} |
1448 |
|
iLine++; |
1449 |
} |
} |
|
} else { |
|
|
pos += format(menu[pos], 511, "%d. %s^n", nmapstoch + 1, nmaps[a]); |
|
1450 |
} |
} |
1451 |
|
|
1452 |
|
strcat(sMenuOption, "^n", 64); |
1453 |
|
pos += formatex(menu[pos], 511, sMenuOption); |
1454 |
|
|
1455 |
mkeys |= (1 << nmapstoch); |
mkeys |= (1 << nmapstoch); |
1456 |
nvotes[nmapstoch] = 0; |
nvotes[nmapstoch] = 0; |
1457 |
} |
} |