+ Reply to Thread
Results 1 to 1 of 1
  1. Plugin Advanced Fog New + Menu

    #1
    Membru - Silver II qp ^BalonaSh's Avatar
    Member since
    Aug 2018
    Posts
    44
    Mentioned
    0 Post(s)
    Achievements Total Posts 1 Days Since Last Visited 2 Days Since Last Visited 1 Days Registered 2 Days Registered 1 Threads 1
    Doneaza
    Sustine Comunitatea WarGods!
    Fii unul de-al nostru! Doneaza
    Doneaza in Cont Bancar
    Click aici pentru a face o Donatie

    Plugin Advanced Fog New + Menu (Merita vazut, interesant)

    Descrierelugin prin care apare si se seteaza densitatea si culoarea cetei din joc (folosit, in general, pentru serverele de furien) DESCRIERE_PLUGIN

    Plugin: de ceata pe server NUME_PLUGIN
    Versiune 3.0: VERSIUNE_PLUGIN
    Autor: Legendary. AUTOR_PLUGIN
    Link oficial: - LINK_OFICIAL_PLUGIN
    Download link: mai jos DOWNLOAD_LINK

    Instalare:
    Compilati codul dupa care puneti fisierul compilat .amxx in folderul plugins apoi il treceti in plugins.ini din folderul configs:
    #include amxmodx
    #include amxmisc
    #include amxconst
    #include colorchat

    new const FogDensity[] = { 0, 0, 0, 0, 111, 18, 3, 58, 111, 18, 125, 58, 66, 96, 27, 59, 90, 101, 60, 59, 90,
    101, 68, 59, 10, 41, 95, 59, 111, 18, 125, 59, 111, 18, 3, 60, 68, 116, 19, 60 }

    new const TASK_FOG = 5942

    new RGB[3];
    new CVAR[2];

    public plugin_init() {

    register_plugin("Fog System", "1.2", "Legendary")

    register_menu("Fog System", (1<<0|1<<1|1<<2|1<<3|1<<9), "Settings");

    register_clcmd("say /fog", "FogSystem", _, "- Setari Ceata");
    register_clcmd("say_team /fog", "FogSystem", _, "- Setari Ceata");

    CVAR[0] = register_cvar("F", "1")
    CVAR[1] = register_cvar("D", "1")

    RGB[0] = 155
    RGB[1] = 155
    RGB[2] = 155

    if(get_pcvar_num(CVAR[0]) == 1)
    {
    remove_task(TASK_FOG)
    set_task(0.1, "TaskFog", TASK_FOG, _, _, "b")
    }
    }

    public FogSystem(id) {

    if(!(get_user_flags(id) & ADMIN_CHAT))
    return PLUGIN_HANDLED;

    new menu[512], len;


    len += formatex(menu[len], 511-len, "\y-= \w[ \rFog Settings \w] \y=-^n^n")
    len += formatex(menu[len], 511-len, "\r1. \wFog Status \r[%s]^n", get_pcvar_num(CVAR[0]) == 1 ? "ON" : "OFF");

    if(get_pcvar_num(CVAR[0]) == 1)
    {
    len += formatex(menu[len], 511-len, "\r2. \wFog Density \r[%s]^n", get_pcvar_num(CVAR[1]) == 1 ? "Normal" : "High");
    len += formatex(menu[len], 511-len, "\r3. \wFog Color \r[RANDOM]^n");
    }
    else
    {
    len += formatex(menu[len], 511-len, "\r2. \dFog Density \r[%s]^n", get_pcvar_num(CVAR[1]) == 1 ? "Normal" : "High");
    len += formatex(menu[len], 511-len, "\r3. \dFog Color \r[RANDOM]^n");
    }

    len += formatex(menu[len], 511 - len, "\r4. Reset Settings")

    len += formatex(menu[len], 511 - len, "^n^n\r0. \yAnulare")

    show_menu(id, (1<<0|1<<1|1<<2|1<<3|1<<9), menu, -1, "Fog System")
    }

    public Settings(id, key)
    {
    new name[32];
    get_user_name(id, name, 31)

    switch (key)
    {
    case 0:
    {
    if(get_pcvar_num(CVAR[0]) == 1)
    {
    ColorChat(0, RED, "^4[Fog System] ^3Adminul^4 %s ^3a ^4dezactivat^3 ceata.", name)

    set_pcvar_num(CVAR[0], 0)
    FogSystem()(id)
    TaskFog()
    }
    else
    {
    ColorChat(0, RED, "^4[Fog System] ^3Adminul^4 %s ^3a ^4activat^3 ceata.", name)

    set_pcvar_num(CVAR[0], 1)
    FogSystem()(id)
    TaskFog()
    }
    }
    case 1:
    {
    if(get_pcvar_num(CVAR[0]) == 1)
    {
    if(get_pcvar_num(CVAR[1]) == 1)
    {
    ColorChat(0, RED, "^4[Fog System] ^3Adminul^4 %s ^3a marit ^4densitatea ^3cetii.", name)
    set_pcvar_num(CVAR[1], 2)
    FogSystem()(id)
    TaskFog()
    }
    else
    {
    ColorChat(0, RED, "^4[Fog System] ^3Adminul^4 %s ^3a micit ^4densitatea ^3cetii.", name)

    set_pcvar_num(CVAR[1], 1)
    FogSystem()(id)
    TaskFog()
    }
    }
    else
    {
    ColorChat(id, RED, "^4[Fog System] ^3Ceata este ^4dezactivata^3, nu-i poti schimba ^4densitatea^3.")
    FogSystem()(id)
    }
    }
    case 2:
    {
    if(get_pcvar_num(CVAR[0]) == 1)
    {
    RGB[0] = random(256)
    RGB[1] = random(256)
    RGB[2] = random(256)

    ColorChat(0, RED, "^4[Fog System] ^3Adminul^4 %s ^3a schimbat ^4culoarea ^3cetii.", name)

    FogSystem()(id)
    TaskFog()
    }
    else
    {
    ColorChat(id, RED, "^4[Fog System] ^3Ceata este ^4dezactivata^3, nu-i poti schimba ^4culoarea^3.")
    FogSystem()(id)
    }
    }
    case 3:
    {
    set_pcvar_num(CVAR[0], 1)
    set_pcvar_num(CVAR[1], 1)

    RGB[0] = 155
    RGB[1] = 155
    RGB[2] = 155

    ColorChat(0, RED, "^4[Fog System] ^3Adminul^4 %s ^3a ^4resetat^3 setarile cetii.", name)

    FogSystem()(id)
    TaskFog()
    }
    }
    return PLUGIN_CONTINUE;
    }

    public TaskFog() {

    static density
    density = (4 * get_pcvar_num(CVAR[1]))

    if(get_pcvar_num(CVAR[0]) == 1) {

    message_begin(MSG_ALL, get_user_msgid("Fog"), {0,0,0}, 0);
    write_byte(RGB[0])
    write_byte(RGB[1])
    write_byte(RGB[2])
    write_byte(FogDensity[density])
    write_byte(FogDensity[density+1])
    write_byte(FogDensity[density+2])
    write_byte(FogDensity[density+3])
    message_end();
    }
    else
    {
    message_begin(MSG_ALL, get_user_msgid("Fog"), {0,0,0}, 0);
    write_byte(0);
    write_byte(0);
    write_byte(0);
    write_byte(0);
    write_byte(0);
    write_byte(0);
    write_byte(0);
    message_end();
    }

    return PLUGIN_CONTINUE;
    }


    Comenzi (chat/consola): se tasteaza /fog in chat (doar de admini bineinteles)

    Cvar-uri: -

    Modules (gen: sockets/orpheu/etc.): -

    Natives (daca exista): -

    Screenshot (daca exista):
    You have to register to be able to see this link. Register HERE! If you are already a member please log in! If you still you are not able to see the link you need to activate your account or an administrator need to activate your account!
    You have to register to be able to see this link. Register HERE! If you are already a member please log in! If you still you are not able to see the link you need to activate your account or an administrator need to activate your account!
    You have to register to be able to see this link. Register HERE! If you are already a member please log in! If you still you are not able to see the link you need to activate your account or an administrator need to activate your account!


    Alta informatie: Numai adminii cu flagul "i" pot avea acces la aceasta comanda
    Last edited by qp ^BalonaSh; 27-08-2018 at 11:11 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Partners
Humble Monthly Bundle
Voucher PC-Garage