Quote:
Originally Posted by wrecked_
Specifically for your plugin, you'd want to do something like this:
PHP Code:
#include <amxmodx>
new sz_MapName[32]
public plugin_init() { register_plugin( "Map Finder Example", "9999.5", "wrecked_" ) register_clcmd( "say /shop", "cmd_ShopHandler" ) // Just because I know you're using this for the VIP thing }
public cmd_ShopHandler( id ) { get_mapname( sz_MapName, charsmax( sz_MapName ) ) if( containi( sz_MapName, "jb_" ) ) { // JB Shop Code Here } else { // Normal Shop Code Here } }
|
No you don't.
Code:
#include < amxmodx >
public plugin_init( )
{
register_plugin( "Map plugin example", "0.0.1", "Exolent" );
new szMapName[ 64 ];
get_mapname( szMapName, 63 );
if( containi( szMapName, "jb" ) == -1 )
{
pause( "a" );
return;
}
// rest of plugin_init( ) code here
}
__________________