Modificare plugin ( eliminare reclama )

Modificari necesare ale pluginurilor

Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com

Post Reply
Aneimar
Membru, skill 0
Membru, skill 0
Posts: 90
Joined: 07 Apr 2016, 00:16
Detinator Steam: Nu
CS Status: Citesc forumul eXtreamCS.com...!
Fond eXtream: 0
Has thanked: 1 time
Contact:

28 Jul 2018, 23:50

Salut ! Am si eu o problema pe mapa deathrun_latexx , am acest plugin "deathrun banner remover" si nu functioneaza cum trebuie .
Normal acest plugin trebuie sa elimine reclama de pe deathrun_latexx de la spawn ( reclama face referire la alt server de deathrun )

Code: Select all

#include <amxmodx>
#include <fakemeta>
#include <hamsandwich> 
 
/* Modificat de Florin * */
 
#define PLUGIN "deathrun banner remover"
#define VERSION "1"
#define AUTHOR "Jon"
 
new Trie:gTrieWallModels, gRegisterIndex;
 
public plugin_precache()
{
		new Map[ 32 ];
		get_mapname( Map, charsmax(Map) );
 
		if( equali( Map, "deathrun_mnx_beta" ) )
		{
			new const WallModels[ ][ ] =
			{
				"*14",
                "*15",
                "*114",
                "*135",
                "*136",
                "*137",
                "*138",
                "*139",
                "*140",
                "*141",
                "*142",
                "*143",
                "*144",
                "*146",
                "*147",
                "*148",
                "*149"
			}
			gTrieWallModels = TrieCreate( );
       
			for( new i; i < sizeof WallModels; i++ )
				TrieSetCell( gTrieWallModels, WallModels[ i ], i );    
       
			gRegisterIndex = register_forward( FM_Spawn, "Spawn" );
		}
		if( equali( Map, "deathrun_latexx" ) )
		{
 
			new const WallModels[ ][ ] =
			{
					"*167"
			}
 
			gTrieWallModels = TrieCreate( );
       
			for( new i; i < sizeof WallModels; i++ )
				TrieSetCell( gTrieWallModels, WallModels[ i ], i );   
       
			gRegisterIndex = register_forward( FM_Spawn, "Spawn" );
       }
}
 
public plugin_init()
{
        register_plugin( PLUGIN, VERSION, AUTHOR );
        register_cvar( PLUGIN, VERSION, FCVAR_SPONLY | FCVAR_SERVER );
        register_message(get_user_msgid("TextMsg"), "message_TextMsg")
	   
        unregister_forward( FM_Spawn, gRegisterIndex );
       
        TrieDestroy( gTrieWallModels );
}

public message_TextMsg(msg_id, msg_dest, msg_entity)
{
    static buffer[32];
    
    get_msg_arg_string(2, buffer, charsmax(buffer));
    
    if(equal(buffer, "#Game_Commencing") || equal(buffer, "#Game_will_restart_in"))
        return PLUGIN_HANDLED
    
    return PLUGIN_CONTINUE
}

public Spawn( Ent )
{
        if( !pev_valid( Ent ) )
                return FMRES_IGNORED;
       
        new Model[ 5 ];
        pev( Ent, pev_model, Model, charsmax(Model) );
               
        if( TrieKeyExists( gTrieWallModels, Model ) )
        {
                engfunc( EngFunc_RemoveEntity, Ent );
                       
                return FMRES_SUPERCEDE;
        }
       
        return FMRES_IGNORED;
}
 
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1044\\ f0\\ fs16 \n\\ par }
*/
RoyalServer 2
User avatar
Laurentiu P.
Fost moderator
Fost moderator
Posts: 2549
Joined: 10 Jul 2013, 21:26
Detinator Steam: Da
Reputatie: Fost super moderator
Fond eXtream: 100
Has thanked: 26 times
Been thanked: 62 times
Contact:

29 Jul 2018, 07:27

no...
Aneimar
Membru, skill 0
Membru, skill 0
Posts: 90
Joined: 07 Apr 2016, 00:16
Detinator Steam: Nu
CS Status: Citesc forumul eXtreamCS.com...!
Fond eXtream: 0
Has thanked: 1 time
Contact:

29 Jul 2018, 10:32

Acel banner cu reclama nu este o entitate ca sa fie eliminata cu plugin-ul dat de tine .
Post Reply

Return to “Modificari pluginuri”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 15 guests