AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Slay command (https://forums.alliedmods.net/showthread.php?t=107657)

(--eRRoR--) 10-28-2009 17:11

Slay command
 
Y want to add to the slay command the thuder soud like in admin mod.
In wath plugin is it from amxmodx?

EDIT:
Y found the code for slay but it isnt quite wath y ecspected to be.So a litle help please.
Where and how showuld y ad the emiting sound function.
(y want the sound to be played to the admin and the player to)

Code:

public cmdSlay(id, level, cid)
{
    if (!cmd_access(id, level, cid, 2))
        return PLUGIN_HANDLED
   
    new arg[32]
   
    read_argv(1, arg, 31)
   
    new player = cmd_target(id, arg, CMDTARGET_OBEY_IMMUNITY | CMDTARGET_ALLOW_SELF | CMDTARGET_ONLY_ALIVE)
   
    if (!player)
        return PLUGIN_HANDLED
   
    user_kill(player)
   
    new authid[32], name2[32], authid2[32], name[32]
   
    get_user_authid(id, authid, 31)
    get_user_name(id, name, 31)
    get_user_authid(player, authid2, 31)
    get_user_name(player, name2, 31)
   
    log_amx("Cmd: ^"%s<%d><%s><>^" slay ^"%s<%d><%s><>^"", name, get_user_userid(id), authid, name2, get_user_userid(player), authid2)

    show_activity_key("ADMIN_SLAY_1", "ADMIN_SLAY_2", name, name2);

    console_print(id, "[AMXX] %L", id, "CLIENT_SLAYED", name2)
   
    return PLUGIN_HANDLED
}


unnyquee 10-29-2009 08:36

Re: Slay command
 
Use this function where do you need it!
PHP Code:

emit_sound(indexchannelsample[], Float:volFloat:att,flagspitch); 

( Engleza ta e varza! )


All times are GMT -4. The time now is 17:44.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.