Aller au contenu
News ticker
  • Bienvenue sur le nouveau forum VeryGames
  • Welcome to the new VeryGames forum
  • VeryNews

    Un plugin amxx en amx svp


    ZH3F

    Messages recommandés

    Bonjour, je voudrais savoir si quelqu'un etait assez competent pour me modifier un plugin amxx en amx je vous poste le .sma ci dessous

     

     

     

    #include <amxmodx>

    #include <amxmisc>

    #include <fun>

    #include <hamsandwich>

    new const PLUGIN[] = "Colored Spawn"

    new const VERSION[] = "2.0"

    new const AUTHOR[] = "fezh & Reymon"

    new g_enabled, g_spawn_color[2], g_amount, g_time

    public plugin_init()

    {

    register_plugin(PLUGIN,VERSION,AUTHOR)

    RegisterHam(Ham_Spawn,"player","event_player_spawn",1)

    g_enabled = register_cvar("amx_colored_spawn","1")

    g_spawn_color[0] = register_cvar("amx_spawn_color","255 180 0")

    g_spawn_color[1] = register_cvar("amx_spawn_admin_color","255 255 255")

    g_amount = register_cvar("amx_color_amount","25")

    g_time = register_cvar("amx_color_time","4.0")

    register_cvar("colored_spawn",VERSION,FCVAR_SERVER|FCVAR_SPONLY)

    }

    public event_player_spawn(id)

    {

    if( get_pcvar_num(g_enabled) && is_user_alive(id) )

    {

    static colors[3], lastring[4], string[12], i

    get_pcvar_string(g_spawn_color[is_user_admin(id)], string,11)

    strbreak(string, lastring, 3, string, 8)

    colors[0] = clamp(str_to_num(lastring), 0, 255)

    strbreak(string, lastring, 3, string, 4)

    colors[1] = clamp(str_to_num(lastring), 0, 255); colors[2] = clamp(str_to_num(string), 0, 255)

     

    if( colors[0] == 0 && colors[1] == 0 && colors[2] == 0 )

    {

    for(i = 0; i < 3; i++)

    colors = random(256)

    }

     

    set_user_rendering(id, kRenderFxGlowShell, colors[0], colors[1], colors[2], kRenderNormal,get_pcvar_num(g_amount))

    set_task(get_pcvar_float(g_time),"event_remove_color",id)

    }

    }

    public event_remove_color(id)

    {

    if(is_user_alive(id))

    {

    set_user_rendering(id,kRenderFxNone,0,0,0,kRenderNormal,0)

    }

    }

    Lien vers le commentaire
    Partager sur d’autres sites

    Rejoindre la conversation

    Vous pouvez publier maintenant et vous inscrire plus tard. Si vous avez un compte, connectez-vous maintenant pour publier avec votre compte.

    Invité
    Répondre à ce sujet…

    ×   Collé en tant que texte enrichi.   Coller en tant que texte brut à la place

      Seulement 75 émoticônes maximum sont autorisées.

    ×   Votre lien a été automatiquement intégré.   Afficher plutôt comme un lien

    ×   Votre contenu précédent a été rétabli.   Vider l’éditeur

    ×   Vous ne pouvez pas directement coller des images. Envoyez-les depuis votre ordinateur ou insérez-les depuis une URL.

    ×
    ×
    • Créer...