Raised This Month: $ Target: $400
 0% 

Deagles' Map Management 3.23


Post New Thread Reply   
 
Thread Tools Display Modes
ScHrAnZ DiNgEnS
Senior Member
Join Date: Sep 2007
Old 02-01-2009 , 01:41   Re: Deagles' Map Management 3.22
Reply With Quote #661

The Vote comes up and i choose a map. My map did not count to the vote and no message was printet for the map that i choose. The votemenü closed after i choose a map. When the vote is finnish it change to currentmap.

That happened by all players.
I think DARKRAVER have the same problem...the different is that i have no mapcycle and so it change to currentmap.

EDIT
When i use the old Langfile and new version of deagles the vote counts. But then there is the old error.

Last edited by ScHrAnZ DiNgEnS; 02-01-2009 at 01:47.
ScHrAnZ DiNgEnS is offline
Send a message via ICQ to ScHrAnZ DiNgEnS Send a message via AIM to ScHrAnZ DiNgEnS
FiFiX
Senior Member
Join Date: May 2008
Location: Poland
Old 02-01-2009 , 10:47   Re: Deagles' Map Management 3.22
Reply With Quote #662

What was causing SVC_BAD??
FiFiX is offline
Send a message via Skype™ to FiFiX
bmann_420
AMX_Super Pooper
Join Date: Jan 2005
Location: [SuperCentral.co]
Old 02-01-2009 , 21:46   Re: Deagles' Map Management 3.22
Reply With Quote #663

Interesting, I think dynamic is going to have to check that lang file, I dont know exactly what was changed (or what lines). It very weird as to the fact that it works fine on my server, we'll figure something out.

@FiFiX,
Ironically it should be the lang file were talking about that had some bad lines in german i believe. Make sure you updated the lang file.
__________________
bmann_420 is offline
ScHrAnZ DiNgEnS
Senior Member
Join Date: Sep 2007
Old 02-02-2009 , 04:24   Re: Deagles' Map Management 3.22
Reply With Quote #664

Now i installed deagles completly new and start manual a vote.

Here my Console:
Quote:
] dmap_rockthevote
Vote has been rocked by ADMIN <paRanoiD | ScHrAnZ DiNgEnS>
"mp_timelimit" changed to "9"
Nominations for the vote: 0 out of 4 possible nominations
It's time to choose the nextmap...
Here i press key 1 for cs_italy

Quote:
* Choosing finished. The nextmap will be de_dust2
"sv_maxspeed" changed to "0"
The next map will be de_dust2
"mp_timelimit" changed to "6"
"mp_chattime" changed to "5"
"mp_chattime" changed to "3"
So i check out the code for count keys.
/// are my comments

PHP Code:
public vote_count(idkey) {
    if (
get_cvar_float("amx_vote_answers")) { ///is right to show answers
        
new name[32]; ///is right
        
get_user_name(idname31); ///is right
        
if (key == maps_to_select) { ///did not happened (i choose a map)
            
client_print(0print_chat"%L"LANG_PLAYER"DMAP_CHOSE_MAPEXTENDING"name);
        } else if (
key maps_to_select) { ///this happened
            
client_print(0print_chat"%L"LANG_PLAYER"DMAP_CHOSE_MAP"namenmaps[nnextmaps[key]]); ///is nerver printet...but why?
        
}
    }
    
nvotes[key] += 1///should work? but no effect
    
g_TotalVotes += 1///cant test it because im alone on the server
    
g_AlreadyVoted[id] = true///should work
    
show_vote_menu(false); ///works because the menu is closed after i press option 1

    
return PLUGIN_HANDLED;

So in the code is nothing to change. So we look for the langfile...

My lang is [en] and i choose a map. So i must look in block [en] for DMAP_CHOSE_MAP.

Quote:
DMAP_CHOSE_MAP = * %s chose %s
Now im confused, becoause everything is right but not worked.
Did i forget something?
ScHrAnZ DiNgEnS is offline
Send a message via ICQ to ScHrAnZ DiNgEnS Send a message via AIM to ScHrAnZ DiNgEnS
ScHrAnZ DiNgEnS
Senior Member
Join Date: Sep 2007
Old 02-02-2009 , 05:35   Re: Deagles' Map Management 3.22
Reply With Quote #665

So, now i check the vote_count funktion with a little debug prints that i have addet to see if it works.


PHP Code:
public vote_count(idkey) {
    
    
client_print(0print_chat"check1"); ///added to check funktion
    
if (get_cvar_float("amx_vote_answers")) {
        
client_print(0print_chat"check2"); ///added to check funktion
        
new name[32];
        
get_user_name(idname31);
        if (
key == maps_to_select) {
            
//client_print(0, print_chat, "%L", LANG_PLAYER, "DMAP_CHOSE_MAPEXTENDING", name); ///disabled to protect funktion from ML errors
        
} else if (key maps_to_select) {
            
client_print(0print_chat"Map is choosen"); ///added to check funktion
            //client_print(0, print_chat, "%L", LANG_PLAYER, "DMAP_CHOSE_MAP", name, nmaps[nnextmaps[key]]);///disabled to protect funktion from ML errors
        
}
    }
    
nvotes[key] += 1;
    
g_TotalVotes += 1;
    
g_AlreadyVoted[id] = true;
    
show_vote_menu(false);
    
client_print(0print_chat"checkend nvotes = %d and g_TotalVotes = %d"nvotes[key], g_TotalVotes); ///added to check funktion

    
return PLUGIN_HANDLED;

The result is that no text was printed, so the funktion is not called...right?

Last edited by ScHrAnZ DiNgEnS; 02-02-2009 at 05:41.
ScHrAnZ DiNgEnS is offline
Send a message via ICQ to ScHrAnZ DiNgEnS Send a message via AIM to ScHrAnZ DiNgEnS
FiFiX
Senior Member
Join Date: May 2008
Location: Poland
Old 02-02-2009 , 13:20   Re: Deagles' Map Management 3.22
Reply With Quote #666

I tell You, how to fix some things, that I already fixed


nextmap command is bugged...
You should change some ifs f.e it sould be like that:
Code:
if(inprogress=0 && mselected=0) then
elseif inprogress=1 then
blalba
elseif mselected =1 then
blabla
For now, command won't works properly.. If I say nextmap when woting is in progress nothings happens.
Also, you must fix lines inprogress=1(or 0) and mselected=true(or false) coz, they're bad too.. Also, when nextmap is choosen, You must add mselected=true to properly works of nextmap command.

O, and nearly forgotten, You have got register_menuid in english, so If someone's server language is different, vote won't works(that's solution for people problem with Why I can't see on chat %s chosen %s) ;). I suggest to get solution from galileo ;)

That's all for me :]

P.S And I suggest You to change +drop(in the end of map) for knife mod. That will elminate TKing in the end of map ;]

Last edited by FiFiX; 02-02-2009 at 13:22.
FiFiX is offline
Send a message via Skype™ to FiFiX
ScHrAnZ DiNgEnS
Senior Member
Join Date: Sep 2007
Old 02-02-2009 , 14:03   Re: Deagles' Map Management 3.22
Reply With Quote #667

Maybe it works when we add a printfunktion that check each playerlang and format it for each player befor client_print something

example like gungame (without colored messages):
PHP Code:

#define LANG_PLAYER_C        -76 // for dmap_print (arbitrary number)    



public dmap_print(id,custom,tag,msg[],any:...)
{
    new 
changeCountnumijargnum numargs(), player;
    static 
newMsg[191], message[191], changed[5], players[32];
    
    if(
id)
    {
        
players[0] = id;
        
num 1;
    }
    else 
get_players(players,num);
    
    for(
i=0;i<num;i++)
    {
        
player players[i];
        
changeCount 0;
        
        
// we have to change LANG_PLAYER_C into
        // a player-specific argument, because
        // ML doesn't work well with SayText
        
for(j=4;j<argnum;j++)
        {
            if(
getarg(j) == LANG_PLAYER_C)
            {
                
setarg(j,0,player);
                
changed[changeCount++] = j;
            }
        }
        
        
// do user formatting
        
vformat(newMsg,190,msg,5);
        
        
// and now we have to change what we changed
        // back into LANG_PLAYER_C, so that the next
        // player will be able to have it in his language
        
for(j=0;j<changeCount;j++)
        {
            
setarg(changed[j],0,LANG_PLAYER_C);
        }
        
        
formatex(message,190,"%s",newMsg);
        
        
message_begin(MSG_ONE,gmsgSayText,_,player);
        
write_byte((custom 0) ? custom player);
        
write_string(message);
        
message_end();
    }
    
    return 
1;

ScHrAnZ DiNgEnS is offline
Send a message via ICQ to ScHrAnZ DiNgEnS Send a message via AIM to ScHrAnZ DiNgEnS
-=hunter=-
Senior Member
Join Date: Jul 2008
Old 02-03-2009 , 00:57   Re: Deagles' Map Management 3.22
Reply With Quote #668

ScHrAnZ DiNgEnS, Rockon
The problem with choosing maps from Nextmap Choosing Menu is function show_menu. I wrote this problem and solving this problem 2 months ago but in version 3.22 this problem not solved.

bmann_420
Please add "title" in show_menu:
show_menu(0, mkeys, menu, --g_VoteTimeRemaining,"Choose the next map:"); line 1528
show_menu(players[iPlayer], mkeys, menu, g_VoteTimeRemaining,"Choose the next map:"); line 1545

Sorry for my bad english.

Last edited by -=hunter=-; 02-03-2009 at 01:04.
-=hunter=- is offline
Send a message via ICQ to -=hunter=- Send a message via Skype™ to -=hunter=-
ScHrAnZ DiNgEnS
Senior Member
Join Date: Sep 2007
Old 02-03-2009 , 04:18   Re: Deagles' Map Management 3.22
Reply With Quote #669

hmmm i never have this problem before...It works perfekt with dmap 3.21 and there is no menutitle.

But ure right...that solved it....but why?
ScHrAnZ DiNgEnS is offline
Send a message via ICQ to ScHrAnZ DiNgEnS Send a message via AIM to ScHrAnZ DiNgEnS
-=hunter=-
Senior Member
Join Date: Jul 2008
Old 02-03-2009 , 06:26   Re: Deagles' Map Management 3.22
Reply With Quote #670

Quote:
Originally Posted by ScHrAnZ DiNgEnS
But ure right...that solved it....but why?
I tested plugin and find out that reason of this problem is a function show_menu (parametr "title"). I took title from "register_menuid" and added this title to show_menu and problem is solved.

Last edited by -=hunter=-; 02-03-2009 at 06:29.
-=hunter=- is offline
Send a message via ICQ to -=hunter=- Send a message via Skype™ to -=hunter=-
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 19:16.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode