Raised This Month: $51 Target: $400
 12% 

ClientCommand in a DialogType_Menu


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
TheWho
AlliedModders Donor
Join Date: Jul 2012
Old 08-04-2014 , 18:12   ClientCommand in a DialogType_Menu
Reply With Quote #1

Hello,

There is the server redirictor plugin that is broken for CS:GO,
I found a snippet and tried it but it seems to not work,
maybe here is a fault:

PHP Code:
if (IsValidClient(client))
    {
        new 
Handle:gKV CreateKeyValues("data");
        
KvSetString(gKV"title""Test1");
        
KvSetNum(gKV"level"1);
        
KvSetColor(gKV"color"1502550255);
        
KvSetNum(gKV"time"20);
        
        
KvSetString(gKV"msg""Test2");
        
        
KvJumpToKey(gKV"1"true);
        
KvSetString(gKV"msg""A");
        
KvSetString(gKV"command""connect IP:PORT");
        
        
CreateDialog(clientgKVDialogType_Menu);
        
CloseHandle(gKV);
        return 
Plugin_Handled;
    } 
I saw servers where you immediately connect to the server you selected in the menu (nothing to press else then the menu button),
first you retry to the same server you are already on,
if you are on the server again then you connet to the selected one.

I'm sure they did it like in my snippet.

DisplayAskConnectBox doesn't worked in csgo for me.

Hoply you can help me, thats annoying that you can't redirect players.
TheWho is offline
JoB2C
AlliedModders Donor
Join Date: Jan 2014
Location: France
Old 08-05-2014 , 09:44   Re: ClientCommand in a DialogType_Menu
Reply With Quote #2

The only server I saw with this was using an extension in combination with the plugin.

Last edited by JoB2C; 08-05-2014 at 23:41.
JoB2C is offline
psychonic

BAFFLED
Join Date: May 2008
Old 08-05-2014 , 10:20   Re: ClientCommand in a DialogType_Menu
Reply With Quote #3

CS:GO does not support the VGUI panel used by CreateDialog (which DisplayAskConnectBox just wraps).
psychonic is offline
TheWho
AlliedModders Donor
Join Date: Jul 2012
Old 08-05-2014 , 15:32   Re: ClientCommand in a DialogType_Menu
Reply With Quote #4

Hm okay, then they hacked the menu thing with a extension :/

And I swear that I even saw the AskConnect if I started playing csgo, too.
(Never seen again since I'm searching for that)
Maybe they dispatched it.
TheWho is offline
JoB2C
AlliedModders Donor
Join Date: Jan 2014
Location: France
Old 08-05-2014 , 23:47   Re: ClientCommand in a DialogType_Menu
Reply With Quote #5

I don't think it works like that...

Because the retry/connect functions are not working as expected when you are connected to a server (it only disconnects you).
JoB2C is offline
Zephyrus
Cool Pig B)
Join Date: Jun 2010
Location: Hungary
Old 08-06-2014 , 06:35   Re: ClientCommand in a DialogType_Menu
Reply With Quote #6

i dont think it has anything to do with menus
__________________
Taking private C++/PHP/SourcePawn requests, PM me.
Zephyrus is offline
TheWho
AlliedModders Donor
Join Date: Jul 2012
Old 08-06-2014 , 09:39   Re: ClientCommand in a DialogType_Menu
Reply With Quote #7

JoB2C you mean you got it to work?
If you have it please show it to us.
First you have to retry..
Console Ex.:
Quote:
retry; connect ip:port
Zephyrus I'm sure you know the way, with a metamod plugin

edit:
Haha wow and I really thought they made it themself, sad that I never wrote an extension.
"Server Redirection" by Zephyrus: Redirect players to a different server
And I didn't watched there exts list before.

Do you think about to release the ext here?

Last edited by TheWho; 08-06-2014 at 10:40.
TheWho is offline
Zephyrus
Cool Pig B)
Join Date: Jun 2010
Location: Hungary
Old 08-06-2014 , 12:30   Re: ClientCommand in a DialogType_Menu
Reply With Quote #8

no way
__________________
Taking private C++/PHP/SourcePawn requests, PM me.
Zephyrus is offline
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 22:36.


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