Jump to content
News ticker
  • Bienvenue sur le nouveau forum VeryGames
  • Welcome to the new VeryGames forum
  • VeryNews

    plugin : ne pas pouvoir poser la bomb


    Guest miew627
     Share

    Recommended Posts

    Sa supprime la zone de bombe :

     

    public Plugin:myinfo = 
    {
       name = "No Bomb Zone",
       author = "iNex",
       description = "Desactivation de la buyzone",
       version = "0.0154B",
       url = "www.daily-studio.com"
    }
    public OnPluginStart()
    {
       HookEvent("round_start", Event_RoundStart, EventHookMode_PostNoCopy);
    }
    //supprime l'entity buyzone
    public OnMapStart()
    {
       decl String:szClass[65];
       for (new i = MaxClients; i <= GetMaxEntities(); i++)
       {
           if(IsValidEdict(i) && IsValidEntity(i))
           {
               GetEdictClassname(i, szClass, sizeof(szClass));
               if(StrEqual("func_bomb_target", szClass))
               {
                   RemoveEdict(i);
               }
           }
       } 
    }
    //desactive l'entity buyzone
    public Event_RoundStart(Handle:event, const String:name[], bool:dontBroadcast)
    {
       decl String:szClass[65];
       for (new i = MaxClients; i <= GetMaxEntities(); i++)
       {
           if(IsValidEdict(i) && IsValidEntity(i))
           {
               GetEdictClassname(i, szClass, sizeof(szClass));
               if(StrEqual("func_bomb_target", szClass))
               {
                   RemoveEdict(i);
               }
           }
       } 
    }
    

    Link to comment
    Share on other sites

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Reply to this topic...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

     Share

    ×
    ×
    • Create New...