[req] overrige FM_GetGameDescription

General discussion about Warcraft MODs for CS/CZ/DOD

Moderator: Forum Moderator

Post Reply
Greenberet
Peon
Posts: 1
Joined: Sat May 06, 2006 5:15 am
Contact:

[req] overrige FM_GetGameDescription

Post by Greenberet » Fri May 12, 2006 12:23 pm

I post this here, because it is an suggestion for each WC3mod and i dont want to suggest it everywhere :P

The idea is simple:
If you override this forward( example above ) you could see which server is running which WC3 mod in the server browser.
So you are able to filter them.

[small]public plugin_init()
{
register_plugin( "GetGameDescription", "1.0", "Greenberet" );
register_forward( FM_GetGameDescription , "HOOK_GetGameDescription" );
}

public HOOK_GetGameDescription()
{

//Warcraft 3 XP
forward_return( FMV_STRING, "Counter Stike: WC3 XP" );

//Warcraft 3 Frozen Throne
forward_return( FMV_STRING, "Counter Stike: WC3 FT" );

//Warcraft 3 Expansion
forward_return( FMV_STRING, "Counter Stike: WC3 EX" );

//Ultimate Warcraft 3
forward_return( FMV_STRING, "Counter Stike: UWC3" );

return FMRES_SUPERCEDE;
}[/small]

These are just examples how it could look like.

Regards
Greenberet

Post Reply