Serwery wiaderko.com Zwiń / Rozwiń kategorię

HashJama [TP] 193.33.176.148:27015 | tp.wiaderko.com status serwera HashJama [TP] połącz

HashJama CS:GO [DM] 193.33.176.53:27015 | dm.wiaderko.com status serwera HashJama CS:GO [DM] połącz

HashJama CS:GO [FFA] 193.33.176.15:27015 | ffa.wiaderko.com status serwera HashJama CS:GO FFA [FFA] połącz

HashJama [TeamSpeak 3] 62.210.99.220:9987 | ts.wiaderko.com status serwera HashJama [TP ELITE] 62.210.99.220:27015 połącz

SPONSOR:
pukawka.pl

Nabór na JUNIOR ADMINA forum - Więcej informacji > Klik <
Pokaż wyniki od 1 do 17 z 17
  1. #1
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Poprawenie pluginu

    Siema,,prosze o upravenie pluginu [ERORS] 26 dzieki
    Kod:
    #include <amxmodx>
    #include <cstrike>
    #include <fun>
    #include <fakemeta>
    #include <hamsandwich>
    
    #define AUTHOR "Matlaku"
    
    new g_player_class[33]
    new player_bh[33]
    new Rychlost[33] = 0
    // nastavenie odpocitavania
    new Float:reset_funkcie = 30.0
    new Float:dlzka_funkcie = 15.0
    new info_cooldown[33]
    new info_funkcia[33]
    new stop[33] = 1
    new g_active[33] = 0
    new g_rychlost[33] = 0
    new const g_Sound[] = "sound/misc/spiderman.wav"
    new const c_Sound[] = "sound/misc/AliG.wav"
    new const a_Sound[] = "sound/misc/batman11.wav"
    new const b_Sound[] = "sound/misc/hellbo.wav"
    new const e_Sound[] = "sound/misc/jab.wav"
    new const h_Sound[] = "sound/misc/GunMen.wav"
    new const r_Sound[] = "sound/misc/rikku1.wav"
    public plugin_init()
    {
    register_plugin("Dr_menu Vytvoril \wMatlaku", "1.3.5", "Matlaku")
    RegisterHam(Ham_Spawn,"player","player_spawn" ,1);
    register_forward(FM_PlayerPreThink, "bunnyhop");
    register_clcmd("schopnost","ability");
    register_concmd("schopnost","ability");
    register_clcmd("schopnost2","abilityhelboy");
    register_concmd("schopnost2","abilityhelboy");
    register_clcmd("schopnost0","abilityjabjab");
    register_concmd("schopnost0","abilityjabjab");
    register_clcmd("schopnost4","abilitygun");
    register_concmd("schopnost4","abilitygun");
    }
    public player_spawn(id)
    {
    player_bh[id] = 0
    if( is_user_alive(id) && cs_get_user_team(id) & CS_TEAM_CT )
    set_task(0.5,"human_menu",id);
    }
    public plugin_precache()
    {
    precache_model("models/player/hb/hb.mdl")
    precache_model("models/player/spiderman/spiderman.mdl")
    precache_model("models/player/jabjab/jabjab.mdl")
    precache_model("models/player/alig/alig.mdl")
    precache_model("models/player/Rikku/Rikku.mdl")
    precache_model("models/player/GunMen/GunMen.mdl")
    precache_model("models/player/css_batman/css_batman.mdl")
    precache_generic(g_Sound)
    precache_generic(c_Sound)
    precache_generic(a_Sound)
    precache_generic(b_Sound)
    precache_generic(e_Sound)
    precache_generic(h_Sound)
    precache_generic(r_Sound)
    }
    public human_menu(id)
    {
    new menu = menu_create("\yVyber si postavu ", "human_menu_handler")
    menu_additem(menu, "\wHellBoy (Velka Sila)", "1", 0)
    menu_additem(menu, "\wJab Jab (Rychlost) \r[\yVIP\r]", "2", 0)
    menu_additem(menu, "\wAli-G (BunnyHop) \r[\yVIP\r]", "3", 0)
    menu_additem(menu, "\wSpiderMan (SuperSkoky) \r[\yVIP\r]", "4", 0)
    menu_additem(menu, "\wRikku (Neviditelnost) \r[\yEVIP\r]", "5", ADMIN_LEVEL_H)
    menu_additem(menu, "\wGunMen (Uzi + MP5) \r[\yEVIP\r]", "6", ADMIN_LEVEL_H)
    menu_additem(menu, "\wBatman (Oslepeni) \r[\yEVIP\r]", "7", ADMIN_LEVEL_H) // NEVIDITELNOST NIECO INE
    menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
    menu_display(id, menu, 0)
    }
    public human_menu_handler(id, menu, item)
    {
    if( item == MENU_EXIT )
    {
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    new data[6], iName[64]
    new access, callback
    menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
    new key = str_to_num(data)
    switch(key)
    {
    case 1:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED; //puvodne if(is_user_alive(id) )
    g_player_class[id] = 1
    cs_set_user_model(id,"hb")
    client_cmd(id,"bind v schopnost2")
    ChatColor(id, "!g[Netrix-GP] Vybral jsis postavu: !tHelBoy !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",b_Sound)
    }
    case 2:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED
    g_player_class[id] = 2
    cs_set_user_model(id,"jabjab")
    client_cmd(id,"bind v schopnost0")
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tJab Jab !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",e_Sound)
    
    }
    case 3:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    player_bh[id] = 3
    cs_set_user_model(id,"alig")
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tAli-G !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",c_Sound)
    }
    case 4:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    g_player_class[id] = 4
    cs_set_user_model(id,"spiderman")
    client_cmd(id,"bind v schopnost")
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tSpiderman !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",g_Sound)
    }
    case 5:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 5
    cs_set_user_model(id,"Rikku") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    ChatColor(id, "!y[Netrix-GP] !gVybral jsis postavu: !tRikku")
    client_cmd(id,"mp3 play %s",r_Sound)
    }
    case 6:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 6
    cs_set_user_model(id,"GunMen")
    client_cmd(id,"bind v schopnost4")
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tGunMen !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",h_Sound)
    }
    case 7:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 7
    cs_set_user_model(id,"css_batman") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    ChatColor(id, "!y[Netrix-GP] !gVybral jsis postavu: !tBatman")
    client_cmd(id,"mp3 play %s",a_Sound)
    
    }
    }
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    public bunnyhop(id)
    {
    if(!player_bh[id])
    return PLUGIN_CONTINUE
    
    if (pev(id, pev_button) & IN_JUMP) {
    new flags = pev(id, pev_flags)
    
    if (flags & FL_WATERJUMP)
    return FMRES_IGNORED;
    if ( pev(id, pev_waterlevel) >= 2 )
    return FMRES_IGNORED;
    if ( !(flags & FL_ONGROUND) )
    return FMRES_IGNORED;
    
    new Float:velocity[3];
    pev(id, pev_velocity, velocity);
    velocity[2] += 250.0;
    set_pev(id, pev_velocity, velocity);
    
    set_pev(id, pev_gaitsequence, 6);
    
    }
    return FMRES_IGNORED;
    }
    
    public Speed(id)
    { 
    if(Rychlost[id])
    {
    set_user_maxspeed(id, 350.0)
    }
    }
    
    public Gun(id)
    {
    give_item(id, "weapon_uzi")	
    give_item(id, "weapon_mp5")
    }
    
    public show_time(id)
    {
    if(is_user_alive(id))
    {
    info_cooldown[id] = info_cooldown[id] - 1
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Obnoveni Schopnosti : %d",info_cooldown[id])
    }
    }	
    
    public show_infor(id)
    {
    if(is_user_alive(id))
    {
    info_funkcia[id] = info_funkcia[id] - 1
    
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Konec Schopnosti : %d",info_funkcia[id])
    }
    }
    
    public reset(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_task(reset_funkcie,"obnovenie",id)
    set_task(1.0,"show_time",id,_,_,"a",info_cooldown[id])
    }
    }
    
    public obnovenie(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 0
    g_active[id] = 0
    set_task(0.5,"human_menu",id);
    new mess[192]
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    formatex(mess,charsmax(mess),"Tvoje schopnost byla obnovena !")
    message_begin(MSG_ONE,get_user_msgid("SayText"),_,id)
    write_byte(id)
    write_string(mess)
    message_end()
    }
    }
    
    public ability(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 0.50)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityhelboy(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 255)
    set_user_armor(id, 255)
    set_user_gravity(id, 1.00)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityjabjab(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_user_maxspeed(id, 350.0)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilitygun(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    give_item(id, "weapon_knife")
    give_item(id, "weapon_mac10")
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public startround()
    {
    for(new x = 1;x <= get_maxplayers();x++)
    {
    info_cooldown[x] = floatround(reset_funkcie)
    remove_task(x)
    }
    }
    
    stock ChatColor(const id, const input[], any:...) {
    new count = 1, players[ 32 ]
    static msg[ 191 ]
    vformat( msg, 190, input, 3 )
    
    replace_all( msg, 190, "!g", "^4" )
    replace_all( msg, 190, "!y", "^1" )
    replace_all( msg, 190, "!t", "^3" )
    
    
    if(id) players[ 0 ] = id; else get_players( players, count, "ch" )
    {
    for(new i = 0; i < count; i++)
    {
    if( is_user_connected( players[ i ] ) )
    {
    message_begin( MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players[ i ] ) 
    write_byte( players[ i ] )
    write_string( msg )
    message_end( )
    }
    }
    }
    }
    Ostatnio edytowane przez layka_LUBII ; 15-03-2013 o 20:48

  2. #2
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    First, include <colorchat>
    Then replace
    ChatColor(id, "!y[Netrix-GP] !gVybral jsis postavu: !tBatman")
    With
    ColorChat(id, "!y[Netrix-GP] !gVybral jsis postavu: !tBatman")

    You can find more detailed guide here: http://www.forums.wiaderko.com/porad...na-czacie.html
    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  3. #3
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    nedziala prosze repair

    Welcome to the AMX Mod X 1.8.1-300 Compiler.
    Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

    Error: Argument type mismatch (argument 2) on line 97
    Error: Argument type mismatch (argument 2) on line 106
    Error: Argument type mismatch (argument 2) on line 118
    Error: Argument type mismatch (argument 2) on line 127
    Error: Argument type mismatch (argument 2) on line 138
    Error: Argument type mismatch (argument 2) on line 147
    Error: Argument type mismatch (argument 2) on line 158
    Error: Invalid expression, assumed zero on line 211
    Error: Undefined symbol "Player_Spawn" on line 211
    Error: Number of arguments does not match definition on line 213
    Error: Invalid expression, assumed zero on line 220
    Error: Undefined symbol "show_infor" on line 220
    Error: Invalid expression, assumed zero on line 226
    Error: Undefined symbol "Player_Spawn" on line 226
    Error: Number of arguments does not match definition on line 228
    Error: Invalid expression, assumed zero on line 235
    Error: Undefined symbol "reset" on line 235
    Error: Invalid expression, assumed zero on line 248
    Error: Undefined symbol "obnovenie" on line 248
    Error: Invalid expression, assumed zero on line 256
    Error: Undefined symbol "Player_Spawn" on line 256
    Error: Number of arguments does not match definition on line 258
    Error: Invalid expression, assumed zero on line 268
    Error: Undefined symbol "ability" on line 268
    Error: Invalid expression, assumed zero on line 286
    Error: Undefined symbol "abilityhelboy" on line 286

    Compilation aborted.
    26 Errors.
    Could not locate output file C:\Documents and Settings\Slavo\Desktop\Untitled.amx (compile failed).

  4. #4
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    Daj obecny kod.
    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  5. #5
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    Tu jest obecny kod z 26 Errors

    Kod:
    #include <amxmodx>
    #include <cstrike>
    #include <fun>
    #include <fakemeta>
    #include <hamsandwich>
    
    #define AUTHOR "Matlaku"
    
    new g_player_class[33]
    new player_bh[33]
    new Rychlost[33] = 0
    // nastavenie odpocitavania
    new Float:reset_funkcie = 30.0
    new Float:dlzka_funkcie = 15.0
    new info_cooldown[33]
    new info_funkcia[33]
    new stop[33] = 1
    new g_active[33] = 0
    new g_rychlost[33] = 0
    new const g_Sound[] = "sound/misc/spiderman.wav"
    new const c_Sound[] = "sound/misc/AliG.wav"
    new const a_Sound[] = "sound/misc/batman11.wav"
    new const b_Sound[] = "sound/misc/hellbo.wav"
    new const e_Sound[] = "sound/misc/jab.wav"
    new const h_Sound[] = "sound/misc/GunMen.wav"
    new const r_Sound[] = "sound/misc/rikku1.wav"
    public plugin_init()
    {
    register_plugin("Dr_menu Vytvoril \wMatlaku", "1.3.5", "Matlaku")
    RegisterHam(Ham_Spawn,"player","player_spawn" ,1);
    register_forward(FM_PlayerPreThink, "bunnyhop");
    register_clcmd("schopnost","ability");
    register_concmd("schopnost","ability");
    register_clcmd("schopnost2","abilityhelboy");
    register_concmd("schopnost2","abilityhelboy");
    register_clcmd("schopnost0","abilityjabjab");
    register_concmd("schopnost0","abilityjabjab");
    register_clcmd("schopnost4","abilitygun");
    register_concmd("schopnost4","abilitygun");
    }
    public player_spawn(id)
    {
    player_bh[id] = 0
    if( is_user_alive(id) && cs_get_user_team(id) & CS_TEAM_CT )
    set_task(0.5,"human_menu",id);
    }
    public plugin_precache()
    {
    precache_model("models/player/hb/hb.mdl")
    precache_model("models/player/spiderman/spiderman.mdl")
    precache_model("models/player/jabjab/jabjab.mdl")
    precache_model("models/player/alig/alig.mdl")
    precache_model("models/player/Rikku/Rikku.mdl")
    precache_model("models/player/GunMen/GunMen.mdl")
    precache_model("models/player/css_batman/css_batman.mdl")
    precache_generic(g_Sound)
    precache_generic(c_Sound)
    precache_generic(a_Sound)
    precache_generic(b_Sound)
    precache_generic(e_Sound)
    precache_generic(h_Sound)
    precache_generic(r_Sound)
    }
    public human_menu(id)
    {
    new menu = menu_create("\yVyber si postavu ", "human_menu_handler")
    menu_additem(menu, "\wHellBoy (Velka Sila)", "1", 0)
    menu_additem(menu, "\wJab Jab (Rychlost) \r[\yVIP\r]", "2", 0)
    menu_additem(menu, "\wAli-G (BunnyHop) \r[\yVIP\r]", "3", 0)
    menu_additem(menu, "\wSpiderMan (SuperSkoky) \r[\yVIP\r]", "4", 0)
    menu_additem(menu, "\wRikku (Neviditelnost) \r[\yEVIP\r]", "5", ADMIN_LEVEL_H)
    menu_additem(menu, "\wGunMen (Uzi + MP5) \r[\yEVIP\r]", "6", ADMIN_LEVEL_H)
    menu_additem(menu, "\wBatman (Oslepeni) \r[\yEVIP\r]", "7", ADMIN_LEVEL_H) // NEVIDITELNOST NIECO INE
    menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
    menu_display(id, menu, 0)
    }
    public human_menu_handler(id, menu, item)
    {
    if( item == MENU_EXIT )
    {
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    new data[6], iName[64]
    new access, callback
    menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
    new key = str_to_num(data)
    switch(key)
    {
    case 1:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED; //puvodne if(is_user_alive(id) )
    g_player_class[id] = 1
    cs_set_user_model(id,"hb")
    client_cmd(id,"bind v schopnost2")
    ChatColor(id, "!g[Netrix-GP] Vybral jsis postavu: !tHelBoy !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",b_Sound)
    }
    case 2:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED
    g_player_class[id] = 2
    cs_set_user_model(id,"jabjab")
    client_cmd(id,"bind v schopnost0")
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tJab Jab !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",e_Sound)
    
    }
    case 3:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    player_bh[id] = 3
    cs_set_user_model(id,"alig")
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tAli-G !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",c_Sound)
    }
    case 4:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    g_player_class[id] = 4
    cs_set_user_model(id,"spiderman")
    client_cmd(id,"bind v schopnost")
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tSpiderman !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",g_Sound)
    }
    case 5:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 5
    cs_set_user_model(id,"Rikku") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    ChatColor(id, "!y[Netrix-GP] !gVybral jsis postavu: !tRikku")
    client_cmd(id,"mp3 play %s",r_Sound)
    }
    case 6:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 6
    cs_set_user_model(id,"GunMen")
    client_cmd(id,"bind v schopnost4")
    ChatColor(id, "!g[Netrix-GP] !gVybral jsis postavu: !tGunMen !g, Schopnost se zapina !tV !g!!")
    client_cmd(id,"mp3 play %s",h_Sound)
    }
    case 7:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 7
    cs_set_user_model(id,"css_batman") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    ChatColor(id, "!y[Netrix-GP] !gVybral jsis postavu: !tBatman")
    client_cmd(id,"mp3 play %s",a_Sound)
    
    }
    }
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    public bunnyhop(id)
    {
    if(!player_bh[id])
    return PLUGIN_CONTINUE
    
    if (pev(id, pev_button) & IN_JUMP) {
    new flags = pev(id, pev_flags)
    
    if (flags & FL_WATERJUMP)
    return FMRES_IGNORED;
    if ( pev(id, pev_waterlevel) >= 2 )
    return FMRES_IGNORED;
    if ( !(flags & FL_ONGROUND) )
    return FMRES_IGNORED;
    
    new Float:velocity[3];
    pev(id, pev_velocity, velocity);
    velocity[2] += 250.0;
    set_pev(id, pev_velocity, velocity);
    
    set_pev(id, pev_gaitsequence, 6);
    
    }
    return FMRES_IGNORED;
    }
    
    public Speed(id)
    { 
    if(Rychlost[id])
    {
    set_user_maxspeed(id, 350.0)
    }
    }
    
    public Gun(id)
    {
    give_item(id, "weapon_uzi")	
    give_item(id, "weapon_mp5")
    }
    
    public show_time(id)
    {
    if(is_user_alive(id))
    {
    info_cooldown[id] = info_cooldown[id] - 1
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Obnoveni Schopnosti : %d",info_cooldown[id])
    }
    }	
    
    public show_infor(id)
    {
    if(is_user_alive(id))
    {
    info_funkcia[id] = info_funkcia[id] - 1
    
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Konec Schopnosti : %d",info_funkcia[id])
    }
    }
    
    public reset(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_task(reset_funkcie,"obnovenie",id)
    set_task(1.0,"show_time",id,_,_,"a",info_cooldown[id])
    }
    }
    
    public obnovenie(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 0
    g_active[id] = 0
    set_task(0.5,"human_menu",id);
    new mess[192]
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    formatex(mess,charsmax(mess),"Tvoje schopnost byla obnovena !")
    message_begin(MSG_ONE,get_user_msgid("SayText"),_,id)
    write_byte(id)
    write_string(mess)
    message_end()
    }
    }
    
    public ability(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 0.50)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityhelboy(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 255)
    set_user_armor(id, 255)
    set_user_gravity(id, 1.00)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityjabjab(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_user_maxspeed(id, 350.0)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilitygun(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    give_item(id, "weapon_knife")
    give_item(id, "weapon_mac10")
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public startround()
    {
    for(new x = 1;x <= get_maxplayers();x++)
    {
    info_cooldown[x] = floatround(reset_funkcie)
    remove_task(x)
    }
    }
    
    stock ChatColor(const id, const input[], any:...) {
    new count = 1, players[ 32 ]
    static msg[ 191 ]
    vformat( msg, 190, input, 3 )
    
    replace_all( msg, 190, "!g", "^4" )
    replace_all( msg, 190, "!y", "^1" )
    replace_all( msg, 190, "!t", "^3" )
    
    
    if(id) players[ 0 ] = id; else get_players( players, count, "ch" )
    {
    for(new i = 0; i < count; i++)
    {
    if( is_user_connected( players[ i ] ) )
    {
    message_begin( MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players[ i ] ) 
    write_byte( players[ i ] )
    write_string( msg )
    message_end( )
    }
    }
    }
    }

  6. #6
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    Nie poprawiłeś niczego co ci napisałem...
    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  7. #7
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    poprawił Colorchat i tak 26 ERROR

  8. #8
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    Nie poprawił, przecież widzę...
    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  9. #9
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    Naven i dal het Colorchat i tak 26 ERRORS

    Welcome to the AMX Mod X 1.8.1-300 Compiler.
    Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

    Error: Invalid expression, assumed zero on line 203
    Error: Undefined symbol "Player_Spawn" on line 203
    Error: Number of arguments does not match definition on line 205
    Error: Invalid expression, assumed zero on line 212
    Error: Undefined symbol "show_infor" on line 212
    Error: Invalid expression, assumed zero on line 218
    Error: Undefined symbol "Player_Spawn" on line 218
    Error: Number of arguments does not match definition on line 220
    Error: Invalid expression, assumed zero on line 227
    Error: Undefined symbol "reset" on line 227
    Error: Invalid expression, assumed zero on line 240
    Error: Undefined symbol "obnovenie" on line 240
    Error: Invalid expression, assumed zero on line 248
    Error: Undefined symbol "Player_Spawn" on line 248
    Error: Number of arguments does not match definition on line 250
    Error: Invalid expression, assumed zero on line 260
    Error: Undefined symbol "ability" on line 260
    Error: Invalid expression, assumed zero on line 278
    Error: Undefined symbol "abilityhelboy" on line 278
    Error: Invalid expression, assumed zero on line 296
    Error: Undefined symbol "abilityjabjab" on line 296
    Error: Invalid expression, assumed zero on line 315
    Error: Undefined symbol "abilitygun" on line 315
    Error: Invalid expression, assumed zero on line 335
    Error: Undefined symbol "startround" on line 335
    Error: Expected token: "}", but found "-end of file-" on line 342

    Compilation aborted.
    26 Errors.
    Could not locate output file C:\Documents and Settings\Slavo\Desktop\Untitled.amx (compile failed).

    Kod:
    #include <amxmodx>
    #include <cstrike>
    #include <fun>
    #include <fakemeta>
    #include <hamsandwich>
    
    #define AUTHOR "Matlaku"
    
    new g_player_class[33]
    new player_bh[33]
    new Rychlost[33] = 0
    // nastavenie odpocitavania
    new Float:reset_funkcie = 30.0
    new Float:dlzka_funkcie = 15.0
    new info_cooldown[33]
    new info_funkcia[33]
    new stop[33] = 1
    new g_active[33] = 0
    new g_rychlost[33] = 0
    new const g_Sound[] = "sound/misc/spiderman.wav"
    new const c_Sound[] = "sound/misc/AliG.wav"
    new const a_Sound[] = "sound/misc/batman11.wav"
    new const b_Sound[] = "sound/misc/hellbo.wav"
    new const e_Sound[] = "sound/misc/jab.wav"
    new const h_Sound[] = "sound/misc/GunMen.wav"
    new const r_Sound[] = "sound/misc/rikku1.wav"
    public plugin_init()
    {
    register_plugin("Dr_menu Vytvoril \wMatlaku", "1.3.5", "Matlaku")
    RegisterHam(Ham_Spawn,"player","player_spawn" ,1);
    register_forward(FM_PlayerPreThink, "bunnyhop");
    register_clcmd("schopnost","ability");
    register_concmd("schopnost","ability");
    register_clcmd("schopnost2","abilityhelboy");
    register_concmd("schopnost2","abilityhelboy");
    register_clcmd("schopnost0","abilityjabjab");
    register_concmd("schopnost0","abilityjabjab");
    register_clcmd("schopnost4","abilitygun");
    register_concmd("schopnost4","abilitygun");
    }
    public player_spawn(id)
    {
    player_bh[id] = 0
    if( is_user_alive(id) && cs_get_user_team(id) & CS_TEAM_CT )
    set_task(0.5,"human_menu",id);
    }
    public plugin_precache()
    {
    precache_model("models/player/hb/hb.mdl")
    precache_model("models/player/spiderman/spiderman.mdl")
    precache_model("models/player/jabjab/jabjab.mdl")
    precache_model("models/player/alig/alig.mdl")
    precache_model("models/player/Rikku/Rikku.mdl")
    precache_model("models/player/GunMen/GunMen.mdl")
    precache_model("models/player/css_batman/css_batman.mdl")
    precache_generic(g_Sound)
    precache_generic(c_Sound)
    precache_generic(a_Sound)
    precache_generic(b_Sound)
    precache_generic(e_Sound)
    precache_generic(h_Sound)
    precache_generic(r_Sound)
    }
    public human_menu(id)
    {
    new menu = menu_create("\yVyber si postavu ", "human_menu_handler")
    menu_additem(menu, "\wHellBoy (Velka Sila)", "1", 0)
    menu_additem(menu, "\wJab Jab (Rychlost) \r[\yVIP\r]", "2", 0)
    menu_additem(menu, "\wAli-G (BunnyHop) \r[\yVIP\r]", "3", 0)
    menu_additem(menu, "\wSpiderMan (SuperSkoky) \r[\yVIP\r]", "4", 0)
    menu_additem(menu, "\wRikku (Neviditelnost) \r[\yEVIP\r]", "5", ADMIN_LEVEL_H)
    menu_additem(menu, "\wGunMen (Uzi + MP5) \r[\yEVIP\r]", "6", ADMIN_LEVEL_H)
    menu_additem(menu, "\wBatman (Oslepeni) \r[\yEVIP\r]", "7", ADMIN_LEVEL_H) // NEVIDITELNOST NIECO INE
    menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
    menu_display(id, menu, 0)
    }
    public human_menu_handler(id, menu, item)
    {
    if( item == MENU_EXIT )
    {
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    new data[6], iName[64]
    new access, callback
    menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
    new key = str_to_num(data)
    switch(key)
    {
    case 1:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED; //puvodne if(is_user_alive(id) )
    g_player_class[id] = 1
    cs_set_user_model(id,"hb")
    client_cmd(id,"bind v schopnost2")
    client_cmd(id,"mp3 play %s",b_Sound)
    }
    case 2:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED
    g_player_class[id] = 2
    cs_set_user_model(id,"jabjab")
    client_cmd(id,"bind v schopnost0")
    client_cmd(id,"mp3 play %s",e_Sound)
    
    }
    case 3:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    player_bh[id] = 3
    cs_set_user_model(id,"alig")
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",c_Sound)
    }
    case 4:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    g_player_class[id] = 4
    cs_set_user_model(id,"spiderman")
    client_cmd(id,"bind v schopnost")
    client_cmd(id,"mp3 play %s",g_Sound)
    }
    case 5:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 5
    cs_set_user_model(id,"Rikku") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",r_Sound)
    }
    case 6:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 6
    cs_set_user_model(id,"GunMen")
    client_cmd(id,"bind v schopnost4")
    client_cmd(id,"mp3 play %s",h_Sound)
    }
    case 7:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 7
    cs_set_user_model(id,"css_batman") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",a_Sound)
    
    }
    }
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    public bunnyhop(id)
    {
    if(!player_bh[id])
    return PLUGIN_CONTINUE
    
    if (pev(id, pev_button) & IN_JUMP) {
    new flags = pev(id, pev_flags)
    
    if (flags & FL_WATERJUMP)
    return FMRES_IGNORED;
    if ( pev(id, pev_waterlevel) >= 2 )
    return FMRES_IGNORED;
    if ( !(flags & FL_ONGROUND) )
    return FMRES_IGNORED;
    
    new Float:velocity[3];
    pev(id, pev_velocity, velocity);
    velocity[2] += 250.0;
    set_pev(id, pev_velocity, velocity);
    
    set_pev(id, pev_gaitsequence, 6);
    
    }
    return FMRES_IGNORED;
    }
    
    public Speed(id)
    { 
    if(Rychlost[id])
    {
    set_user_maxspeed(id, 350.0)
    }
    }
    
    public Gun(id)
    {
    give_item(id, "weapon_uzi")	
    give_item(id, "weapon_mp5")
    }
    
    public show_time(id)
    {
    if(is_user_alive(id))
    {
    info_cooldown[id] = info_cooldown[id] - 1
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Obnoveni Schopnosti : %d",info_cooldown[id])
    }
    }	
    
    public show_infor(id)
    {
    if(is_user_alive(id))
    {
    info_funkcia[id] = info_funkcia[id] - 1
    
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Konec Schopnosti : %d",info_funkcia[id])
    }
    }
    
    public reset(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_task(reset_funkcie,"obnovenie",id)
    set_task(1.0,"show_time",id,_,_,"a",info_cooldown[id])
    }
    }
    
    public obnovenie(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 0
    g_active[id] = 0
    set_task(0.5,"human_menu",id);
    new mess[192]
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    formatex(mess,charsmax(mess),"Tvoje schopnost byla obnovena !")
    message_begin(MSG_ONE,get_user_msgid("SayText"),_,id)
    write_byte(id)
    write_string(mess)
    message_end()
    }
    }
    
    public ability(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 0.50)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityhelboy(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 255)
    set_user_armor(id, 255)
    set_user_gravity(id, 1.00)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityjabjab(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_user_maxspeed(id, 350.0)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilitygun(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    give_item(id, "weapon_knife")
    give_item(id, "weapon_mac10")
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public startround()
    {
    for(new x = 1;x <= get_maxplayers();x++)
    {
    info_cooldown[x] = floatround(reset_funkcie)
    remove_task(x)
    }
    }

  10. #10
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    Nie możesz w taki sposób użyć funkcji
    Kod php:
    public show_time(id)
    {
        if(
    is_user_alive(id))
        {
            
    //info_cooldown[id] = info_cooldown[id] 
            
    public Player_Spawn(id
            {
                
    human_menu(id)
                
    register_logevent("startround"2"1=Round_Start")
                
    set_hudmessage1201201200.750.8000.10.80.10.1, -
                
    show_hudmessage(id"Obnoveni Schopnosti : %d",info_cooldown[id])
            }
        } 
    ->
    Kod php:
    public show_time(id)
    {
        if(
    is_user_alive(id))
        {
            
    //info_cooldown[id] = info_cooldown[id] 
            
    Player_Spawn(id
            {
                
    human_menu(id)
                
    register_logevent("startround"2"1=Round_Start")
                
    set_hudmessage1201201200.750.8000.10.80.10.1, -
                
    show_hudmessage(id"Obnoveni Schopnosti : %d",info_cooldown[id])
            }
        } 
    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  11. #11
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    dalem naven i 25 ERRORS

    Kod:
    #include <amxmodx>
    #include <cstrike>
    #include <fun>
    #include <fakemeta>
    #include <hamsandwich>
    
    #define AUTHOR "Matlaku"
    
    new g_player_class[33]
    new player_bh[33]
    new Rychlost[33] = 0
    // nastavenie odpocitavania
    new Float:reset_funkcie = 30.0
    new Float:dlzka_funkcie = 15.0
    new info_cooldown[33]
    new info_funkcia[33]
    new stop[33] = 1
    new g_active[33] = 0
    new g_rychlost[33] = 0
    new const g_Sound[] = "sound/misc/spiderman.wav"
    new const c_Sound[] = "sound/misc/AliG.wav"
    new const a_Sound[] = "sound/misc/batman11.wav"
    new const b_Sound[] = "sound/misc/hellbo.wav"
    new const e_Sound[] = "sound/misc/jab.wav"
    new const h_Sound[] = "sound/misc/GunMen.wav"
    new const r_Sound[] = "sound/misc/rikku1.wav"
    public plugin_init()
    {
    register_plugin("Dr_menu Vytvoril \wMatlaku", "1.3.5", "Matlaku")
    RegisterHam(Ham_Spawn,"player","player_spawn" ,1);
    register_forward(FM_PlayerPreThink, "bunnyhop");
    register_clcmd("schopnost","ability");
    register_concmd("schopnost","ability");
    register_clcmd("schopnost2","abilityhelboy");
    register_concmd("schopnost2","abilityhelboy");
    register_clcmd("schopnost0","abilityjabjab");
    register_concmd("schopnost0","abilityjabjab");
    register_clcmd("schopnost4","abilitygun");
    register_concmd("schopnost4","abilitygun");
    }
    public player_spawn(id)
    {
    player_bh[id] = 0
    if( is_user_alive(id) && cs_get_user_team(id) & CS_TEAM_CT )
    set_task(0.5,"human_menu",id);
    }
    public plugin_precache()
    {
    precache_model("models/player/hb/hb.mdl")
    precache_model("models/player/spiderman/spiderman.mdl")
    precache_model("models/player/jabjab/jabjab.mdl")
    precache_model("models/player/alig/alig.mdl")
    precache_model("models/player/Rikku/Rikku.mdl")
    precache_model("models/player/GunMen/GunMen.mdl")
    precache_model("models/player/css_batman/css_batman.mdl")
    precache_generic(g_Sound)
    precache_generic(c_Sound)
    precache_generic(a_Sound)
    precache_generic(b_Sound)
    precache_generic(e_Sound)
    precache_generic(h_Sound)
    precache_generic(r_Sound)
    }
    public human_menu(id)
    {
    new menu = menu_create("\yVyber si postavu ", "human_menu_handler")
    menu_additem(menu, "\wHellBoy (Velka Sila)", "1", 0)
    menu_additem(menu, "\wJab Jab (Rychlost) \r[\yVIP\r]", "2", 0)
    menu_additem(menu, "\wAli-G (BunnyHop) \r[\yVIP\r]", "3", 0)
    menu_additem(menu, "\wSpiderMan (SuperSkoky) \r[\yVIP\r]", "4", 0)
    menu_additem(menu, "\wRikku (Neviditelnost) \r[\yEVIP\r]", "5", ADMIN_LEVEL_H)
    menu_additem(menu, "\wGunMen (Uzi + MP5) \r[\yEVIP\r]", "6", ADMIN_LEVEL_H)
    menu_additem(menu, "\wBatman (Oslepeni) \r[\yEVIP\r]", "7", ADMIN_LEVEL_H) // NEVIDITELNOST NIECO INE
    menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
    menu_display(id, menu, 0)
    }
    public human_menu_handler(id, menu, item)
    {
    if( item == MENU_EXIT )
    {
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    new data[6], iName[64]
    new access, callback
    menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
    new key = str_to_num(data)
    switch(key)
    {
    case 1:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED; //puvodne if(is_user_alive(id) )
    g_player_class[id] = 1
    cs_set_user_model(id,"hb")
    client_cmd(id,"bind v schopnost2")
    client_cmd(id,"mp3 play %s",b_Sound)
    }
    case 2:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED
    g_player_class[id] = 2
    cs_set_user_model(id,"jabjab")
    client_cmd(id,"bind v schopnost0")
    client_cmd(id,"mp3 play %s",e_Sound)
    
    }
    case 3:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    player_bh[id] = 3
    cs_set_user_model(id,"alig")
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",c_Sound)
    }
    case 4:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    g_player_class[id] = 4
    cs_set_user_model(id,"spiderman")
    client_cmd(id,"bind v schopnost")
    client_cmd(id,"mp3 play %s",g_Sound)
    }
    case 5:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 5
    cs_set_user_model(id,"Rikku") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",r_Sound)
    }
    case 6:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 6
    cs_set_user_model(id,"GunMen")
    client_cmd(id,"bind v schopnost4")
    client_cmd(id,"mp3 play %s",h_Sound)
    }
    case 7:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 7
    cs_set_user_model(id,"css_batman") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",a_Sound)
    
    }
    }
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    public bunnyhop(id)
    {
    if(!player_bh[id])
    return PLUGIN_CONTINUE
    
    if (pev(id, pev_button) & IN_JUMP) {
    new flags = pev(id, pev_flags)
    
    if (flags & FL_WATERJUMP)
    return FMRES_IGNORED;
    if ( pev(id, pev_waterlevel) >= 2 )
    return FMRES_IGNORED;
    if ( !(flags & FL_ONGROUND) )
    return FMRES_IGNORED;
    
    new Float:velocity[3];
    pev(id, pev_velocity, velocity);
    velocity[2] += 250.0;
    set_pev(id, pev_velocity, velocity);
    
    set_pev(id, pev_gaitsequence, 6);
    
    }
    return FMRES_IGNORED;
    }
    
    public Speed(id)
    { 
    if(Rychlost[id])
    {
    set_user_maxspeed(id, 350.0)
    }
    }
    
    public Gun(id)
    {
    give_item(id, "weapon_uzi")	
    give_item(id, "weapon_mp5")
    }
    
    public show_time(id)
    {
    if(is_user_alive(id))
    {
    //info_cooldown[id] = info_cooldown[id] 
    public Player_Spawn(id) 
    {
    human_menu(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Obnoveni Schopnosti : %d",info_cooldown[id])
    }
    } 	
    
    public show_infor(id)
    {
    if(is_user_alive(id))
    {
    info_funkcia[id] = info_funkcia[id] - 1
    
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Konec Schopnosti : %d",info_funkcia[id])
    }
    }
    
    public reset(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_task(reset_funkcie,"obnovenie",id)
    set_task(1.0,"show_time",id,_,_,"a",info_cooldown[id])
    }
    }
    
    public obnovenie(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 0
    g_active[id] = 0
    set_task(0.5,"human_menu",id);
    new mess[192]
    public Player_Spawn(id) 
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    formatex(mess,charsmax(mess),"Tvoje schopnost byla obnovena !")
    message_begin(MSG_ONE,get_user_msgid("SayText"),_,id)
    write_byte(id)
    write_string(mess)
    message_end()
    }
    }
    
    public ability(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 0.50)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityhelboy(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 255)
    set_user_armor(id, 255)
    set_user_gravity(id, 1.00)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityjabjab(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_user_maxspeed(id, 350.0)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilitygun(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    give_item(id, "weapon_knife")
    give_item(id, "weapon_mac10")
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public startround()
    {
    for(new x = 1;x <= get_maxplayers();x++)
    {
    info_cooldown[x] = floatround(reset_funkcie)
    remove_task(x)
    }
    }

  12. #12
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    Nie we wszystkich miejscach poprawiłeś.
    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  13. #13
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    Cytat Zamieszczone przez naven Zobacz posta
    Nie możesz w taki sposób użyć funkcji
    Kod php:
    public show_time(id)
    {
        if(
    is_user_alive(id))
        {
            
    //info_cooldown[id] = info_cooldown[id] 
            
    public Player_Spawn(id
            {
                
    human_menu(id)
                
    register_logevent("startround"2"1=Round_Start")
                
    set_hudmessage1201201200.750.8000.10.80.10.1, -
                
    show_hudmessage(id"Obnoveni Schopnosti : %d",info_cooldown[id])
            }
        } 
    ->
    Kod php:
    public show_time(id)
    {
        if(
    is_user_alive(id))
        {
            
    //info_cooldown[id] = info_cooldown[id] 
            
    Player_Spawn(id
            {
                
    human_menu(id)
                
    register_logevent("startround"2"1=Round_Start")
                
    set_hudmessage1201201200.750.8000.10.80.10.1, -
                
    show_hudmessage(id"Obnoveni Schopnosti : %d",info_cooldown[id])
            }
        } 

    rovnake si dal kody

  14. #14
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    public Player_Spawn(id)
    ->
    Player_Spawn(id)
    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  15. #15
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    Juz len 22 ERRORS

    Kod:
    #include <amxmodx>
    #include <cstrike>
    #include <fun>
    #include <fakemeta>
    #include <hamsandwich>
    
    #define AUTHOR "Matlaku"
    
    new g_player_class[33]
    new player_bh[33]
    new Rychlost[33] = 0
    // nastavenie odpocitavania
    new Float:reset_funkcie = 30.0
    new Float:dlzka_funkcie = 15.0
    new info_cooldown[33]
    new info_funkcia[33]
    new stop[33] = 1
    new g_active[33] = 0
    new g_rychlost[33] = 0
    new const g_Sound[] = "sound/misc/spiderman.wav"
    new const c_Sound[] = "sound/misc/AliG.wav"
    new const a_Sound[] = "sound/misc/batman11.wav"
    new const b_Sound[] = "sound/misc/hellbo.wav"
    new const e_Sound[] = "sound/misc/jab.wav"
    new const h_Sound[] = "sound/misc/GunMen.wav"
    new const r_Sound[] = "sound/misc/rikku1.wav"
    public plugin_init()
    {
    register_plugin("Dr_menu Vytvoril \wMatlaku", "1.3.5", "Matlaku")
    RegisterHam(Ham_Spawn,"player","player_spawn" ,1);
    register_forward(FM_PlayerPreThink, "bunnyhop");
    register_clcmd("schopnost","ability");
    register_concmd("schopnost","ability");
    register_clcmd("schopnost2","abilityhelboy");
    register_concmd("schopnost2","abilityhelboy");
    register_clcmd("schopnost0","abilityjabjab");
    register_concmd("schopnost0","abilityjabjab");
    register_clcmd("schopnost4","abilitygun");
    register_concmd("schopnost4","abilitygun");
    }
    public player_spawn(id)
    {
    player_bh[id] = 0
    if( is_user_alive(id) && cs_get_user_team(id) & CS_TEAM_CT )
    set_task(0.5,"human_menu",id);
    }
    public plugin_precache()
    {
    precache_model("models/player/hb/hb.mdl")
    precache_model("models/player/spiderman/spiderman.mdl")
    precache_model("models/player/jabjab/jabjab.mdl")
    precache_model("models/player/alig/alig.mdl")
    precache_model("models/player/Rikku/Rikku.mdl")
    precache_model("models/player/GunMen/GunMen.mdl")
    precache_model("models/player/css_batman/css_batman.mdl")
    precache_generic(g_Sound)
    precache_generic(c_Sound)
    precache_generic(a_Sound)
    precache_generic(b_Sound)
    precache_generic(e_Sound)
    precache_generic(h_Sound)
    precache_generic(r_Sound)
    }
    public human_menu(id)
    {
    new menu = menu_create("\yVyber si postavu ", "human_menu_handler")
    menu_additem(menu, "\wHellBoy (Velka Sila)", "1", 0)
    menu_additem(menu, "\wJab Jab (Rychlost) \r[\yVIP\r]", "2", 0)
    menu_additem(menu, "\wAli-G (BunnyHop) \r[\yVIP\r]", "3", 0)
    menu_additem(menu, "\wSpiderMan (SuperSkoky) \r[\yVIP\r]", "4", 0)
    menu_additem(menu, "\wRikku (Neviditelnost) \r[\yEVIP\r]", "5", ADMIN_LEVEL_H)
    menu_additem(menu, "\wGunMen (Uzi + MP5) \r[\yEVIP\r]", "6", ADMIN_LEVEL_H)
    menu_additem(menu, "\wBatman (Oslepeni) \r[\yEVIP\r]", "7", ADMIN_LEVEL_H) // NEVIDITELNOST NIECO INE
    menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
    menu_display(id, menu, 0)
    }
    public human_menu_handler(id, menu, item)
    {
    if( item == MENU_EXIT )
    {
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    new data[6], iName[64]
    new access, callback
    menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
    new key = str_to_num(data)
    switch(key)
    {
    case 1:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED; //puvodne if(is_user_alive(id) )
    g_player_class[id] = 1
    cs_set_user_model(id,"hb")
    client_cmd(id,"bind v schopnost2")
    client_cmd(id,"mp3 play %s",b_Sound)
    }
    case 2:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED
    g_player_class[id] = 2
    cs_set_user_model(id,"jabjab")
    client_cmd(id,"bind v schopnost0")
    client_cmd(id,"mp3 play %s",e_Sound)
    
    }
    case 3:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    player_bh[id] = 3
    cs_set_user_model(id,"alig")
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",c_Sound)
    }
    case 4:
    {
    if(!is_user_alive(id) ) return PLUGIN_HANDLED;
    g_player_class[id] = 4
    cs_set_user_model(id,"spiderman")
    client_cmd(id,"bind v schopnost")
    client_cmd(id,"mp3 play %s",g_Sound)
    }
    case 5:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 5
    cs_set_user_model(id,"Rikku") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",r_Sound)
    }
    case 6:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 6
    cs_set_user_model(id,"GunMen")
    client_cmd(id,"bind v schopnost4")
    client_cmd(id,"mp3 play %s",h_Sound)
    }
    case 7:
    {
    if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
    g_player_class[id] = 7
    cs_set_user_model(id,"css_batman") // !!!!
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    client_cmd(id,"mp3 play %s",a_Sound)
    
    }
    }
    menu_destroy(menu)
    return PLUGIN_HANDLED
    }
    public bunnyhop(id)
    {
    if(!player_bh[id])
    return PLUGIN_CONTINUE
    
    if (pev(id, pev_button) & IN_JUMP) {
    new flags = pev(id, pev_flags)
    
    if (flags & FL_WATERJUMP)
    return FMRES_IGNORED;
    if ( pev(id, pev_waterlevel) >= 2 )
    return FMRES_IGNORED;
    if ( !(flags & FL_ONGROUND) )
    return FMRES_IGNORED;
    
    new Float:velocity[3];
    pev(id, pev_velocity, velocity);
    velocity[2] += 250.0;
    set_pev(id, pev_velocity, velocity);
    
    set_pev(id, pev_gaitsequence, 6);
    
    }
    return FMRES_IGNORED;
    }
    
    public Speed(id)
    { 
    if(Rychlost[id])
    {
    set_user_maxspeed(id, 350.0)
    }
    }
    
    public Gun(id)
    {
    give_item(id, "weapon_uzi")	
    give_item(id, "weapon_mp5")
    }
    
    public show_time(id)
    {
    if(is_user_alive(id))
    {
    //info_cooldown[id] = info_cooldown[id] 
    Player_Spawn(id)
    {
    human_menu(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Obnoveni Schopnosti : %d",info_cooldown[id])
    }
    } 	
    
    public show_infor(id)
    {
    if(is_user_alive(id))
    {
    info_funkcia[id] = info_funkcia[id] - 1
    
    Player_Spawn(id)
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    set_hudmessage( 120, 120, 120, 0.75, 0.80, 0, 0.1, 0.8, 0.1, 0.1, -1 ) 
    show_hudmessage(id, "Konec Schopnosti : %d",info_funkcia[id])
    }
    }
    
    public reset(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_task(reset_funkcie,"obnovenie",id)
    set_task(1.0,"show_time",id,_,_,"a",info_cooldown[id])
    }
    }
    
    public obnovenie(id)
    {
    if(is_user_alive(id))
    {
    stop[id] = 0
    g_active[id] = 0
    set_task(0.5,"human_menu",id);
    new mess[192]
    Player_Spawn(id)
    {
    human_menu_handler(id)
    register_logevent("startround", 2, "1=Round_Start")
    formatex(mess,charsmax(mess),"Tvoje schopnost byla obnovena !")
    message_begin(MSG_ONE,get_user_msgid("SayText"),_,id)
    write_byte(id)
    write_string(mess)
    message_end()
    }
    }
    
    public ability(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 0.50)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityhelboy(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 255)
    set_user_armor(id, 255)
    set_user_gravity(id, 1.00)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilityjabjab(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    set_user_maxspeed(id, 350.0)
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public abilitygun(id)
    {
    if(g_active[id] == 0)
    {
    //funkcia
    g_active[id] = 1
    set_user_health(id, 100)
    set_user_armor(id, 100)
    set_user_gravity(id, 1.00)
    give_item(id, "weapon_knife")
    give_item(id, "weapon_mac10")
    stop[id] = 0
    set_task(dlzka_funkcie,"reset",id)
    info_funkcia[id] = floatround(dlzka_funkcie)
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
    info_cooldown[id] = floatround(reset_funkcie)
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
    }
    }
    
    public startround()
    {
    for(new x = 1;x <= get_maxplayers();x++)
    {
    info_cooldown[x] = floatround(reset_funkcie)
    remove_task(x)
    }
    }

  16. #16
    Adminus pospolitus Awatar naven
    Dołączył
    Jan 2008
    Wiek
    25
    Posty
    10,802
    Thanks
    31
    Thanked 652 Times in 605 Posts

    Domyślnie Odp: Poprawenie pluginu

    Kod php:
    #include <amxmodx>
    #include <cstrike>
    #include <fun>
    #include <fakemeta>
    #include <hamsandwich>

    #define AUTHOR "Matlaku"

    new g_player_class[33]
    new 
    player_bh[33]
    new 
    Rychlost[33] = 0
    // nastavenie odpocitavania
    new Float:reset_funkcie 30.0
    new Float:dlzka_funkcie 15.0
    new info_cooldown[33]
    new 
    info_funkcia[33]
    new 
    stop[33] = 1
    new g_active[33] = 0
    //new g_rychlost[33] = 0
    new const g_Sound[] = "sound/misc/spiderman.wav"
    new const c_Sound[] = "sound/misc/AliG.wav"
    new const a_Sound[] = "sound/misc/batman11.wav"
    new const b_Sound[] = "sound/misc/hellbo.wav"
    new const e_Sound[] = "sound/misc/jab.wav"
    new const h_Sound[] = "sound/misc/GunMen.wav"
    new const r_Sound[] = "sound/misc/rikku1.wav"
    public plugin_init()
    {
        
    register_plugin("Dr_menu Vytvoril \wMatlaku""1.3.5""Matlaku")
        
    RegisterHam(Ham_Spawn,"player","player_spawn" ,1);
        
    register_forward(FM_PlayerPreThink"bunnyhop");
        
    register_clcmd("schopnost","ability");
        
    register_concmd("schopnost","ability");
        
    register_clcmd("schopnost2","abilityhelboy");
        
    register_concmd("schopnost2","abilityhelboy");
        
    register_clcmd("schopnost0","abilityjabjab");
        
    register_concmd("schopnost0","abilityjabjab");
        
    register_clcmd("schopnost4","abilitygun");
        
    register_concmd("schopnost4","abilitygun");
    }
    public 
    player_spawn(id)
    {
        
    player_bh[id] = 0
        
    if( is_user_alive(id) && cs_get_user_team(id) & CS_TEAM_CT )
            
    set_task(0.5,"human_menu",id);
    }
    public 
    plugin_precache()
    {
        
    precache_model("models/player/hb/hb.mdl")
        
    precache_model("models/player/spiderman/spiderman.mdl")
        
    precache_model("models/player/jabjab/jabjab.mdl")
        
    precache_model("models/player/alig/alig.mdl")
        
    precache_model("models/player/Rikku/Rikku.mdl")
        
    precache_model("models/player/GunMen/GunMen.mdl")
        
    precache_model("models/player/css_batman/css_batman.mdl")
        
    precache_generic(g_Sound)
        
    precache_generic(c_Sound)
        
    precache_generic(a_Sound)
        
    precache_generic(b_Sound)
        
    precache_generic(e_Sound)
        
    precache_generic(h_Sound)
        
    precache_generic(r_Sound)
    }
    public 
    human_menu(id)
    {
        new 
    menu menu_create("\yVyber si postavu ""human_menu_handler")
        
    menu_additem(menu"\wHellBoy (Velka Sila)""1"0)
        
    menu_additem(menu"\wJab Jab (Rychlost) \r[\yVIP\r]""2"0)
        
    menu_additem(menu"\wAli-G (BunnyHop) \r[\yVIP\r]""3"0)
        
    menu_additem(menu"\wSpiderMan (SuperSkoky) \r[\yVIP\r]""4"0)
        
    menu_additem(menu"\wRikku (Neviditelnost) \r[\yEVIP\r]""5"ADMIN_LEVEL_H)
        
    menu_additem(menu"\wGunMen (Uzi + MP5) \r[\yEVIP\r]""6"ADMIN_LEVEL_H)
        
    menu_additem(menu"\wBatman (Oslepeni) \r[\yEVIP\r]""7"ADMIN_LEVEL_H// NEVIDITELNOST NIECO INE
        
    menu_setprop(menuMPROP_EXITMEXIT_ALL)
        
    menu_display(idmenu0)
    }
    public 
    human_menu_handler(idmenuitem)
    {
        if( 
    item == MENU_EXIT )
        {
            
    menu_destroy(menu)
            return 
    PLUGIN_HANDLED
        
    }
        new 
    data[6], iName[64]
        new 
    accesscallback
        menu_item_getinfo
    (menuitemaccessdata5iName63callback)
        new 
    key str_to_num(data)
        switch(
    key)
        {
            case 
    1:
            {
                if(!
    is_user_alive(id) ) return PLUGIN_HANDLED//puvodne if(is_user_alive(id) )
                
    g_player_class[id] = 1
                cs_set_user_model
    (id,"hb")
                
    client_cmd(id,"bind v schopnost2")
                
    client_cmd(id,"mp3 play %s",b_Sound)
            }
            case 
    2:
            {
                if(!
    is_user_alive(id) ) return PLUGIN_HANDLED
                g_player_class
    [id] = 2
                cs_set_user_model
    (id,"jabjab")
                
    client_cmd(id,"bind v schopnost0")
                
    client_cmd(id,"mp3 play %s",e_Sound)
                
            }
            case 
    3:
            {
                if(!
    is_user_alive(id) ) return PLUGIN_HANDLED;
                
    player_bh[id] = 3
                cs_set_user_model
    (id,"alig")
                
    set_user_health(id100)
                
    set_user_armor(id100)
                
    set_user_gravity(id1.00)
                
    client_cmd(id,"mp3 play %s",c_Sound)
            }
            case 
    4:
            {
                if(!
    is_user_alive(id) ) return PLUGIN_HANDLED;
                
    g_player_class[id] = 4
                cs_set_user_model
    (id,"spiderman")
                
    client_cmd(id,"bind v schopnost")
                
    client_cmd(id,"mp3 play %s",g_Sound)
            }
            case 
    5:
            {
                if(!
    is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
                
    g_player_class[id] = 5
                cs_set_user_model
    (id,"Rikku"// !!!!
                
    set_user_health(id100)
                
    set_user_armor(id100)
                
    set_user_gravity(id1.00)
                
    client_cmd(id,"mp3 play %s",r_Sound)
            }
            case 
    6:
            {
                if(!
    is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
                
    g_player_class[id] = 6
                cs_set_user_model
    (id,"GunMen")
                
    client_cmd(id,"bind v schopnost4")
                
    client_cmd(id,"mp3 play %s",h_Sound)
            }
            case 
    7:
            {
                if(!
    is_user_alive(id) || !(get_user_flags(id) & ADMIN_LEVEL_H) ) return PLUGIN_HANDLED;
                
    g_player_class[id] = 7
                cs_set_user_model
    (id,"css_batman"// !!!!
                
    set_user_health(id100)
                
    set_user_armor(id100)
                
    set_user_gravity(id1.00)
                
    client_cmd(id,"mp3 play %s",a_Sound)
                
            }
        }
        
    menu_destroy(menu)
        return 
    PLUGIN_HANDLED
    }
    public 
    bunnyhop(id)
    {
        if(!
    player_bh[id])
            return 
    PLUGIN_CONTINUE
        
        
    if (pev(idpev_button) & IN_JUMP) {
            new 
    flags pev(idpev_flags)
            
            if (
    flags FL_WATERJUMP)
                return 
    FMRES_IGNORED;
            if ( 
    pev(idpev_waterlevel) >= )
                return 
    FMRES_IGNORED;
            if ( !(
    flags FL_ONGROUND) )
                return 
    FMRES_IGNORED;
            
            new 
    Float:velocity[3];
            
    pev(idpev_velocityvelocity);
            
    velocity[2] += 250.0;
            
    set_pev(idpev_velocityvelocity);
            
            
    set_pev(idpev_gaitsequence6);
            
        }
        return 
    FMRES_IGNORED;
    }

    public 
    Speed(id)

        if(
    Rychlost[id])
        {
            
    set_user_maxspeed(id350.0)
        }
    }

    public 
    Gun(id)
    {
        
    give_item(id"weapon_uzi")    
        
    give_item(id"weapon_mp5")
    }

    public 
    show_time(id)
    {
        if(
    is_user_alive(id))
        {
            
    //info_cooldown[id] = info_cooldown[id] 
            //Player_Spawn(id)        human_menu(id)
            
    register_logevent("startround"2"1=Round_Start")
            
    set_hudmessage1201201200.750.8000.10.80.10.1, -
            
    show_hudmessage(id"Obnoveni Schopnosti : %d",info_cooldown[id])
        }
    }     

    public 
    show_infor(id)
    {
        if(
    is_user_alive(id))
        {
            
    //info_funkcia[id] = info_funkcia[id] - 1
            
    info_funkcia[id]--;
            
            
    //Player_Spawn(id)
            
    human_menu(id)
            
    register_logevent("startround"2"1=Round_Start")
            
    set_hudmessage1201201200.750.8000.10.80.10.1, -
            
    show_hudmessage(id"Konec Schopnosti : %d",info_funkcia[id])
        }
    }

    public 
    reset(id)
    {
        if(
    is_user_alive(id))
        {
            
    stop[id] = 1
            set_user_health
    (id100)
            
    set_user_armor(id100)
            
    set_user_gravity(id1.00)
            
    set_task(reset_funkcie,"obnovenie",id)
            
    set_task(1.0,"show_time",id,_,_,"a",info_cooldown[id])
        }
    }

    public 
    obnovenie(id)
    {
        if(
    is_user_alive(id))
        {
            
    stop[id] = 0
            g_active
    [id] = 0
            set_task
    (0.5,"human_menu",id);
            new 
    mess[192]
            
    //Player_Spawn(id)
            
    human_menu(id)
            
    register_logevent("startround"2"1=Round_Start")
            
    formatex(mess,charsmax(mess),"Tvoje schopnost byla obnovena !")
            
    message_begin(MSG_ONE,get_user_msgid("SayText"),_,id)
            
    write_byte(id)
            
    write_string(mess)
            
    message_end()
        }
    }

    public 
    ability(id)
    {
        if(
    g_active[id] == 0)
        {
            
    //funkcia
            
    g_active[id] = 1
            set_user_health
    (id100)
            
    set_user_armor(id100)
            
    set_user_gravity(id0.50)
            
    stop[id] = 0
            set_task
    (dlzka_funkcie,"reset",id)
            
    info_funkcia[id] = floatround(dlzka_funkcie)
            
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
            
    info_cooldown[id] = floatround(reset_funkcie)
            
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
        }
    }

    public 
    abilityhelboy(id)
    {
        if(
    g_active[id] == 0)
        {
            
    //funkcia
            
    g_active[id] = 1
            set_user_health
    (id255)
            
    set_user_armor(id255)
            
    set_user_gravity(id1.00)
            
    stop[id] = 0
            set_task
    (dlzka_funkcie,"reset",id)
            
    info_funkcia[id] = floatround(dlzka_funkcie)
            
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
            
    info_cooldown[id] = floatround(reset_funkcie)
            
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
        }
    }

    public 
    abilityjabjab(id)
    {
        if(
    g_active[id] == 0)
        {
            
    //funkcia
            
    g_active[id] = 1
            set_user_health
    (id100)
            
    set_user_armor(id100)
            
    set_user_gravity(id1.00)
            
    set_user_maxspeed(id350.0)
            
    stop[id] = 0
            set_task
    (dlzka_funkcie,"reset",id)
            
    info_funkcia[id] = floatround(dlzka_funkcie)
            
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
            
    info_cooldown[id] = floatround(reset_funkcie)
            
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
        }
    }

    public 
    abilitygun(id)
    {
        if(
    g_active[id] == 0)
        {
            
    //funkcia
            
    g_active[id] = 1
            set_user_health
    (id100)
            
    set_user_armor(id100)
            
    set_user_gravity(id1.00)
            
    give_item(id"weapon_knife")
            
    give_item(id"weapon_mac10")
            
    stop[id] = 0
            set_task
    (dlzka_funkcie,"reset",id)
            
    info_funkcia[id] = floatround(dlzka_funkcie)
            
    set_task(1.0,"show_infor",id,_,_,"a",info_funkcia[id])
            
    info_cooldown[id] = floatround(reset_funkcie)
            
    emit_sound(id,CHAN_STREAM,"misc/reset.wav",VOL_NORM,ATTN_IDLE,0,PITCH_NORM)
        }
    }

    public 
    startround()
    {
        for(new 
    1;<= get_maxplayers();x++)
        {
            
    info_cooldown[x] = floatround(reset_funkcie)
            
    remove_task(x)
        }

    Najlepszy hosting Hidden Content href="Hidden Content target="_blank">tutaj
    Konfiguracja amxx, instalacja pluginów, pisanie pluginów AMXX. Więcej info na Hidden Content

    "At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.

  17. #17
    Lamka Awatar layka_LUBII
    Dołączył
    Sep 2012
    Wiek
    19
    Posty
    45
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Domyślnie Odp: Poprawenie pluginu

    dzieki naven LOCK

Podobne wątki

  1. Przerobienie pluginu VIP
    By tYsU^ in forum Pisanie pluginów AMXX
    Odpowiedzi: 1
    Ostatni post / autor: 28-01-2011, 12:15
  2. PLUGINU VIP
    By Demonho in forum Szukam pluginu AMX/AMXX
    Odpowiedzi: 1
    Ostatni post / autor: 08-11-2010, 23:39
  3. Szukam pluginu
    By ngl in forum Szukam pluginu AMX/AMXX
    Odpowiedzi: 0
    Ostatni post / autor: 18-04-2009, 10:30
  4. szukam pluginu
    By sebek9 in forum Szukam pluginu AMX/AMXX
    Odpowiedzi: 1
    Ostatni post / autor: 14-04-2009, 13:03
  5. sz.pluginu
    By HardStyle in forum Amx Mod X
    Odpowiedzi: 4
    Ostatni post / autor: 03-12-2007, 14:20

Odwiedzający poszukiwali:

Nikt jeszcze nie odwiedził tej strony poprzez wyszukiwarki

Uprawnienia umieszczania postów

  • Nie możesz zakładać nowych tematów
  • Nie możesz pisać wiadomości
  • Nie możesz dodawać załączników
  • Nie możesz edytować swoich postów
  •