Timeleft + nextmap

Šiame forume rašomi vartotojų klausimai/problemos su kuriomis jie susidūrė kuriant pluginus.
Post Reply
User avatar
k1ck
Jau po truputį tampa savu
Posts: 112
Joined: 2010 Dec 01 19:20
Skype: manager.ax
Location: Kaunas

Timeleft + nextmap

Post by k1ck »

Code: Select all

#include <amxmodx> static const PLUGIN[]  = "Info"static const VERSION[] = "0.1"static const AUTHOR[]  = "k1ck" new g_teamScore[2]new g_enable_info public plugin_init(){    register_plugin(PLUGIN, VERSION, AUTHOR)    register_event("TeamScore", "teamScore", "ab")     g_enable_info = register_cvar("amx_info", "1")    register_clcmd("info", "info_", 0, "- Displays Info.")    register_clcmd("/info", "info_", 0, "- Displays Info.")    register_clcmd("say info", "info_", 0, "- Displays Info.")    register_clcmd("say /info", "info_", 0, "- Displays Info.")              register_clcmd("timeleft", "info_", 0, "- Displays Info.")              register_clcmd("/timeleft", "info_", 0, "- Displays Info.")              register_clcmd("nextmap", "info_", 0, "- Displays Info.")              register_clcmd("/nextmap", "info_", 0, "- Displays Info.")              register_clcmd("say timeleft", "info_", 0, "- Displays Info.")              register_clcmd("say /timeleft", "info_", 0, "- Displays Info.")              register_clcmd("say nextmap", "info_", 0, "- Displays Info.")    register_clcmd("say /nextmap", "info_", 0, "- Displays Info.")     return PLUGIN_CONTINUE} public info_(id){    if (!get_pcvar_num(g_enable_info))        return PLUGIN_HANDLED     new nextmap[32]    get_cvar_string("amx_nextmap", nextmap, 31)     new maxRounds = get_cvar_num("mp_maxrounds")    new roundsleft = maxRounds - (g_teamScore[0] + g_teamScore[1])     new rl[32]    format(rl, 31, "%d", roundsleft)     new message[192]    format(message, 191, "Map will change after %s more rounds. Next map will be %s.", (maxRounds == 0) ? "(NO_ROUNDS_SET)" : rl, nextmap)    client_print(id, print_chat, message)     return PLUGIN_CONTINUE} public teamScore(id){    new team[2]    read_data(1, team, 1)     g_teamScore[(team[0]== 'C') ? 0 : 1] = read_data(2)} 
Kodėl kai serve parašau info rašo:
Map will change after ę0 more rounds. Next map will be .
Nerašo koks bus mapas? Kas blogai plugine?

newb
Pluginų patvirtintojas
Posts: 1047
Joined: 2010 Sep 23 21:43
Location: Wonderland
Contact:

Re: Timeleft + nextmap

Post by newb »

Nes amx_nextmap nenustatytas.

User avatar
k1ck
Jau po truputį tampa savu
Posts: 112
Joined: 2010 Dec 01 19:20
Skype: manager.ax
Location: Kaunas

Re: Timeleft + nextmap

Post by k1ck »

Kaip jį nustatyti, aš išvis iššėmiau ta pluginą nextmap

newb
Pluginų patvirtintojas
Posts: 1047
Joined: 2010 Sep 23 21:43
Location: Wonderland
Contact:

Re: Timeleft + nextmap

Post by newb »

Tai kas cia tada keisto, kad nerodo koks kitas mapas ?

User avatar
k1ck
Jau po truputį tampa savu
Posts: 112
Joined: 2010 Dec 01 19:20
Skype: manager.ax
Location: Kaunas

Re: Timeleft + nextmap

Post by k1ck »

Nu bet čia gi yra kodas kad turėtų rodyti Next map will be %s

newb
Pluginų patvirtintojas
Posts: 1047
Joined: 2010 Sep 23 21:43
Location: Wonderland
Contact:

Re: Timeleft + nextmap

Post by newb »

Jis rodo ta kas bus irasyta i amx_nextmap, o jeigu tu atjungei nextmap plugina, tai nieko ir nerodys.

User avatar
k1ck
Jau po truputį tampa savu
Posts: 112
Joined: 2010 Dec 01 19:20
Skype: manager.ax
Location: Kaunas

Re: Timeleft + nextmap

Post by k1ck »

Įmečiau nextmap.amxx, ir dabar rašo:
awp_india
Map will change after 30 more rounds. Next map will be awp_india.

Kaip padaryti kad nerašytu viršuj to awp_india?

Aurimas
O taip. Jis jau surinko 50 žinučių!
Posts: 79
Joined: 2011 Jul 13 20:33

Re: Timeleft + nextmap

Post by Aurimas »

Pabandyk iš nextmap.sma failo išimti tavo naudojamą komandą.

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 2 guests