-- Closed Thread
Results 1 to 4 of 4
  1. Cerere Ajutor [REZOLVAT]

    #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

    Cerere Ajutor [REZOLVAT]

    Stie cineva cum pot compila pe amxx colorchat? ca da eroare la compilator cand incerc...Multumesc!

    #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;
    }
    Last edited by ~TraNda~; 30-08-2018 at 09:53 PM.

  2. Cerere Ajutor [REZOLVAT]

    #2
    Administrator Tiger's Avatar
    Member since
    Sep 2010
    Location
    127.0.0.1
    Posts
    8,962
    Blog Entries
    3
    Mentioned
    167 Post(s)
    Achievements Mentions Received 3 Mentions Given 2 Mentions Received 2 Mentions Received 1 Mentions Given 1 Threads Rating Received 2 Threads Rating Received 1 Visitor Messages Received 1
    Doneaza
    Sustine Comunitatea WarGods!
    Fii unul de-al nostru! Doneaza
    Doneaza in Cont Bancar
    Click aici pentru a face o Donatie

    Plugin-ul va merge compilat, nu stiu insa si functionalitatea lui.

    AMXX Code:
    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!
    *****************

    Thanks qp ^BalonaSh a dat Thanks acetui post

  3. Cerere Ajutor [REZOLVAT]

    #3
    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

    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!

    vad ca nu merge.....trebuie scos sau ceva....

    EDIT: scuze....nu am incercat toate compiler-urile. Multumesc, poti da T/C
    Last edited by qp ^BalonaSh; 30-08-2018 at 08:21 PM.

  4. Cerere Ajutor [REZOLVAT]

    #4
    VIP ~TraNda~'s Avatar
    Member since
    Feb 2014
    Location
    WarGods
    Posts
    12,099
    Last username
    LiOn. ~JoK3r ~
    Blog Entries
    4
    Mentioned
    95 Post(s)
    Achievements Days Registered 4 Mentions Received 2 Mentions Received 1 Mentions Given 4 Mentions Given 3 Mentions Given 2 Mentions Given 1 Threads Rating Received 1
    Doneaza
    Sustine Comunitatea WarGods!
    Fii unul de-al nostru! Doneaza
    Doneaza in Cont Bancar
    Click aici pentru a face o Donatie

    -------------

    TraNda - WarGods | R.R.M - AngeL - LiOn. - pichacku - Jok3r - UnicA

    P A C E

    DISCORD: unknown.cfg


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