Enviar respuesta 
busco plugins de piss
Autor Mensaje
potato02 Sin conexión
Miembro Junior


Trebol purpura
Mensajes: 42
Registro en: May 2019
Reputación: 0
Mensaje: #1
busco plugins de piss
busco plugins de piss ... encontre uno pero cuando hace piss se quieda quieto como 10 segundos .. tonces busco un plugins de piss que se pueda caminar y hacer piss a la vez
16/08/2019 11:51 PM
Encuentra todos sus mensajes Cita este mensaje en tu respuesta
matrix123 Sin conexión
Miembro Destacado


1k
Mensajes: 1,439
Registro en: Oct 2014
Reputación: 16
Mensaje: #2
RE: busco plugins de piss
Deja el codigo, más facil

17/08/2019 02:35 PM
Encuentra todos sus mensajes Cita este mensaje en tu respuesta
potato02 Sin conexión
Miembro Junior


Trebol purpura
Mensajes: 42
Registro en: May 2019
Reputación: 0
Mensaje: #3
RE: busco plugins de piss
Código PHP:
/*

Plugin: Amxx Piss
Version: 2.0
Author: KRoTaL (Based on TakeADookie by PaintLancer)


1.0  Release
1.1  Better effect
1.2  Bug fix
1.3  New effect + piss puddle
1.4a New effects, only for cs/cz/dod
1.4b New effects, only for other mods than cs/cz/dod
1.5  #define NO_CS_CZ added
1.6  Bug fix (DoD)
1.7  Bug fix
1.8  Some checks added
1.9  #define NO_CS_CZ changed into #define NO_CS_CZ
2.0  New cvar : amx_piss_effect

Commands: 

    To piss on a dead body you have to bind a key to: piss
    Open your console and write: bind "key" "piss"
    ex: bind "x" "piss"
    Then stand still above a dead player (cs/cz only), press your key and you'll piss on them ! 
    You can control the direction of the stream with your mouse.
    You are not able to move or to shoot for 10 seconds when you piss, so beware (cs/cz only).
    The puddle of piss will appear where you are aiming at 2 seconds after you start pissing, 
    so try to aim at the dead body instead of the sky or a wall ;)

    Players can say "/piss" in the chat to get some help.

Cvars:

    amx_maxpees 6        -    Maximum number of times a player is allowed to piss per round.

    amx_piss_admin 0        -    0 : All the players are allowed to piss
                              1 : Only admins with ADMIN_LEVEL_A flag are allowed to piss

    amx_piss_effect 0        -    0 : yellow bloodsprite
                              1 : yellow laserbeam

Setup:

    You need to put these files on your server:

    sound/piss/pissing.wav
    models/piss/piss_puddle1.mdl  
    models/piss/piss_puddle2.mdl    
    models/piss/piss_puddle3.mdl       
    models/piss/piss_puddle4.mdl      
    models/piss/piss_puddle5.mdl     
    models/piss/piss.mdl

    You need to enable Fun and Engine Modules for cs/cs-cz.
    You need to enable Engine Module for the other mods.

 Credits:

    Rastin for his trousers fly sounds
    SLayer KL for his piss puddle models

*/

// UNCOMMENT IF YOU USE ANOTHER MOD THAN CS and CS-CZ
//#define NO_CS_CZ




/********************************************************************************​*******************/

#include <amxmodx> 
#if !defined NO_CS_CZ
#include <fun>
#endif
#include <engine>


new piss_model
new piss_sprite
new water_splash
new count_piss[33]
new 
count_puddle[33]
new 
bool:PissFlag[33]
new 
bool:aim[33]
new 
Float:aim_origin[33][3]
#if !defined NO_CS_CZ
new player_origins[33][3]
new 
mod_name[32]
#endif

public piss_on_player(id
{

if (
get_cvar_num("amx_maxpees")==0
    return 
PLUGIN_HANDLED 
if (!is_user_alive(id)) 
    return 
PLUGIN_HANDLED 
if ( (get_cvar_num("amx_piss_admin")==1) && !(get_user_flags(id) & ADMIN_LEVEL_A) )
{
    
console_print(id"[AMXX] You have not access to this command.")
    return 
PLUGIN_HANDLED
}
if(
PissFlag[id])
    return 
PLUGIN_HANDLED

#if !defined NO_CS_CZ
new player_origin[3], players[32], inum=0distlast_dist=99999last_id 

get_user_origin
(id,player_origin,0
get_players(players,inum,"b"
if (
inum>0) { 
    for (new 
i=0;i<inum;i++) { 
        if (
players[i]!=id) { 
            
dist get_distance(player_origin,player_origins[players[i]]) 
            if (
dist<last_dist) { 
                
last_id players[i
                
last_dist dist 
            

        } 
    } 
    if (
last_dist<80) { 
#endif
        
if (count_piss[id] > get_cvar_num("amx_maxpees")) { 
            
client_print(id,print_chat,"You can only piss on a player %d time%s in a round !"get_cvar_num("amx_maxpees"), (get_cvar_num("amx_maxpees")>1) ? "s" ""
            return 
PLUGIN_CONTINUE 
        
}
        new 
player_name[32
        
get_user_name(idplayer_name31)
        
#if !defined NO_CS_CZ
        
new dead_name[32]
        
get_user_name(last_iddead_name31)
        
client_print(0,print_chat,"%s Is Pissing On %s's Dead Body !! HaHaHaHa !!"player_namedead_name)
        
#else
        
client_print(0,print_chat,"%s Is Pissing !!"player_name)
        
#endif
        
count_piss[id]+=1
        count_puddle
[id]=1
        
new ids[1]
        
ids[0]=id
        PissFlag
[id]=true
        aim
[id]=false
        
#if !defined NO_CS_CZ
        
if( (equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
        {
            
client_cmd(id"weapon_knife")
            
set_user_maxspeed(id, -1.0)
        }
        
#endif
        
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"1.0ATTN_NORM0PITCH_NORM
        switch(
get_cvar_num("amx_piss_effect"))
        {
            case 
0:  set_task(0.2,"make_pee",1481+id,ids,1,"a",48)
            case 
1:  set_task(0.1,"make_pee",1481+id,ids,1,"a",102)
            default: 
set_task(0.2,"make_pee",1481+id,ids,1,"a",48)
        }
        
set_task(2.2,"place_puddle",3424+id,ids,1,"a",4)
        
#if !defined NO_CS_CZ
        
set_task(12.0,"weapons_back",6794+id,ids,1)
    }
    else
    {
        
client_print(id,print_chat,"There are no dead bodies around you.")
        return 
PLUGIN_HANDLED
    
}
}
#endif
return PLUGIN_HANDLED
}

public 
sqrt(num

    new 
div num 
    
new result 
    
while (div result) { 
        
div = (div result) / 
        result 
num div 
    

    return 
div 


public 
make_pee(ids[]) 

    new 
id=ids[0]
    new 
vec[3
    new 
aimvec[3
    new 
velocityvec[3
    new 
length 
    get_user_origin
(id,vec
    
get_user_origin(id,aimvec,3
    new 
distance get_distance(vec,aimvec
    new 
speed floatround(distance*1.9)

    
velocityvec[0]=aimvec[0]-vec[0
    
velocityvec[1]=aimvec[1]-vec[1
    
velocityvec[2]=aimvec[2]-vec[2

    
length=sqrt(velocityvec[0]*velocityvec[0]+velocityvec[1]*velocityvec[1]+velocityvec[2]*velocityvec[2]) 

    
velocityvec[0]=velocityvec[0]*speed/length 
    velocityvec
[1]=velocityvec[1]*speed/length 
    velocityvec
[2]=velocityvec[2]*speed/length 

    
switch(get_cvar_num("amx_piss_effect"))
    {
        case 
0:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(101)
            
write_coord(vec[0])
            
write_coord(vec[1])
            
write_coord(vec[2])
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]) 
            
write_byte(102// color
            
write_byte(160// speed
            
message_end()
        }
        case 
1:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY
            
write_byte(106
            
write_coord(vec[0]) 
            
write_coord(vec[1]) 
            
write_coord(vec[2]) 
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]+100
            
write_angle (0
            
write_short (piss_model
            
write_byte (0
            
write_byte (255
            
message_end()  

            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY
            
write_byte (1)    
            
write_short (id
            
write_coord(aimvec[0]) 
            
write_coord(aimvec[1]) 
            
write_coord(aimvec[2]) 
            
write_short(piss_sprite
            
write_byte// framestart 
            
write_byte// framerate 
            
write_byte// life 
            
write_byte// width 
            
write_byte// noise 
            
write_byte255 // r, g, b 
            
write_byte255 // r, g, b 
            
write_byte// r, g, b 
            
write_byte200 // brightness 
            
write_byte10 // speed 
            
message_end()

            
message_beginMSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(17)
            
write_coord(aimvec[0]) 
            
write_coord(aimvec[1]) 
            
write_coord(aimvec[2]) 
            
write_short(water_splash)
            
write_byte(16)
            
write_byte(18)
            
message_end()

        }
        default:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(101)
            
write_coord(vec[0])
            
write_coord(vec[1])
            
write_coord(vec[2])
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]) 
            
write_byte(102// color
            
write_byte(160// speed
            
message_end()
        }
    }


public 
place_puddle(ids[]) 
{
    new 
id=ids[0]
    if(!
aim[id])
    {
        new 
origin[3]
        
get_user_origin(id,origin,3
        
aim_origin[id][0]=float(origin[0])
        
aim_origin[id][1]=float(origin[1])
        
aim_origin[id][2]=float(origin[2])
    }

    new 
puddle_entity
    puddle_entity 
create_entity("info_target")

    if(
puddle_entity == 0) {
        return 
PLUGIN_HANDLED_MAIN
    
}

    new 
Float:MinBox[3]
    new 
Float:MaxBox[3]

    
MinBox[0] = -1.0
    MinBox
[1] = -1.0
    MinBox
[2] = -1.0
    MaxBox
[0] = 1.0
    MaxBox
[1] = 1.0
    MaxBox
[2] = 1.0

    entity_set_vector
(puddle_entityEV_VEC_minsMinBox)
    
entity_set_vector(puddle_entityEV_VEC_maxsMaxBox)

    switch(
count_puddle[id])
    {
        case 
1:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle1")
            
entity_set_model(puddle_entity"models/piss/piss_puddle1.mdl")
        }
        case 
2:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle2")
            
entity_set_model(puddle_entity"models/piss/piss_puddle2.mdl")
        }
        case 
3:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle3")
            
entity_set_model(puddle_entity"models/piss/piss_puddle3.mdl")
        }
        case 
4:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle4")
            
entity_set_model(puddle_entity"models/piss/piss_puddle4.mdl")
        }
        case 
5:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle5")
            
entity_set_model(puddle_entity"models/piss/piss_puddle5.mdl")
            
#if defined NO_CS_CZ
               
PissFlag[id]=false
            
#endif
        
}
        default: {}
    }

    
entity_set_origin(puddle_entityaim_origin[id])
    
entity_set_int(puddle_entityEV_INT_solid3)   
    
entity_set_int(puddle_entityEV_INT_movetype6
    
entity_set_edict(puddle_entityEV_ENT_ownerid)

    
count_puddle[id]+=1
    aim
[id]=true 

       
return PLUGIN_CONTINUE
}

public 
death_event() 

       new 
victim read_data(2)
     
#if !defined NO_CS_CZ      
    
get_user_origin(victim,player_origins[victim],0
    
#endif

    
if(PissFlag[victim]) 
        
reset_piss(victim)

       return 
PLUGIN_CONTINUE 
}

#if !defined NO_CS_CZ
public weapons_back(ids[]) 

       
PissFlag[ids[0]]=false 
    
if( (equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
    {
        
set_user_maxspeed(ids[0], 250.0)
    }
}

public 
cur_weapon(id

    if(
PissFlag[id]) 
    { 
        if( (
equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
        {
            
client_cmd(id"weapon_knife")
            
set_user_maxspeed(id, -1.0)
        }
    }

    return 
PLUGIN_CONTINUE

#endif

public reset_piss(id
{
    if(
task_exists(1481+id))
        
remove_task(1481+id)
    if(
task_exists(3424+id))
        
remove_task(3424+id)
    
#if !defined NO_CS_CZ
    
if(task_exists(6794+id))
        
remove_task(6794+id)
    
#endif
    
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"0.0ATTN_NORM0PITCH_NORM
    
PissFlag[id]=false

    
return PLUGIN_CONTINUE 
}

public 
reset_hud(id)
{
    if(
task_exists(1481+id))
        
remove_task(1481+id)
    if(
task_exists(3424+id))
        
remove_task(3424+id)
    
#if !defined NO_CS_CZ
    
if(task_exists(6794+id))
        
remove_task(6794+id)
    
#endif
    
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"0.0ATTN_NORM0PITCH_NORM
    
PissFlag[id]=false

    
new iCurrent

    
for (new i=i<count_piss[id] ; i++)
    {                
        
iCurrent find_ent_by_class(-1"piss_puddle1")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle2")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle3")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle4")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle5")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
      }
    
count_piss[id]=1

    
return PLUGIN_CONTINUE 


public 
piss_help(id
{
    
client_print(idprint_chat"To piss on a dead body you have to bind a key to: piss")
    
client_print(idprint_chat"Open your console and write: bind ^"key^" ^"piss^"")
    
client_print(idprint_chat"ex: bind ^"x^" ^"piss^"")

    return 
PLUGIN_CONTINUE
}

public 
handle_say(id
{
    new 
said[192]
    
read_args(said,192)
    
remove_quotes(said)

    if( (
containi(said"piss") != -1) && !(containi(said"/piss") != -1) ) {
        
client_print(idprint_chat"[AMXX] For Piss help say /piss")
    }

    return 
PLUGIN_CONTINUE
}

public 
plugin_precache() 

    if (
file_exists("sound/piss/pissing.wav"))
        
precache_sound"piss/pissing.wav")   
    if (
file_exists("models/piss/piss_puddle1.mdl"))      
        
precache_model("models/piss/piss_puddle1.mdl")  
    if (
file_exists("models/piss/piss_puddle2.mdl"))      
        
precache_model("models/piss/piss_puddle2.mdl"
    if (
file_exists("models/piss/piss_puddle3.mdl"))      
        
precache_model("models/piss/piss_puddle3.mdl"
    if (
file_exists("models/piss/piss_puddle4.mdl"))      
        
precache_model("models/piss/piss_puddle4.mdl"
    if (
file_exists("models/piss/piss_puddle5.mdl"))      
        
precache_model("models/piss/piss_puddle5.mdl"
    if (
file_exists("models/piss/piss.mdl"))      
        
piss_model precache_model("models/piss/piss.mdl")  
    
piss_sprite precache_model("sprites/plasma.spr")
    
water_splash precache_model("sprites/wsplash3.spr")

       return 
PLUGIN_CONTINUE 
}

public 
client_connect(id)
{
    
PissFlag[id]=false
    count_piss
[id]=1
    
    
return PLUGIN_CONTINUE
}

public 
client_disconnect(id)
{
    
reset_hud(id)

    return 
PLUGIN_CONTINUE
}

public 
plugin_init() 

    
register_plugin("AMXX Piss","2.0","KRoTaL"
    
register_clcmd("piss","piss_on_player",0,"- Piss on a dead player"
    
register_clcmd("say /piss","piss_help",0,"- Displays piss help"
    
register_clcmd("say","handle_say")
    
register_cvar("amx_maxpees","6")
    
register_cvar("amx_piss_admin","0")
    
register_cvar("amx_piss_effect","0")
    
register_event("DeathMsg","death_event","a"
    
register_event("ResetHUD""reset_hud""be")
    
#if !defined NO_CS_CZ
    
register_event("CurWeapon","cur_weapon","be","1=1")
    
get_modname(mod_name,31)
    
#endif

    
return PLUGIN_CONTINUE



este plugins solo permite mear a los muertes y se demora como 10 segundos ... la idea es que permita mear en todo momento y pueda caminar meando ..... 50 segundos para mear otra vez
18/08/2019 02:28 PM
Encuentra todos sus mensajes Cita este mensaje en tu respuesta
OsweRRR Ausente
Miembro Destacado


Mensajes: 955
Registro en: Feb 2015
Reputación: 11
Mensaje: #4
RE: busco plugins de piss
eso es legal?

Image

(18/11/2014 05:47 PM)Neeeeeeeeeel.- escribió:  Por qué necesitan una guía para todo? Meté mano y que salga lo que salga... es la mejor forma de aprender.

(16/05/2016 11:08 PM)kikizon2 escribió:  No cabe duda que tienen mierda en vez de cerebro, par de pendejos v:
18/08/2019 10:09 PM
Visita su sitio web Encuentra todos sus mensajes Cita este mensaje en tu respuesta
potato02 Sin conexión
Miembro Junior


Trebol purpura
Mensajes: 42
Registro en: May 2019
Reputación: 0
Mensaje: #5
RE: busco plugins de piss
sipo si yo e visto que al mear lo puedes hacer cuando estas vivo por eso lo digo no es que se me haya ocurrido a mi ... por eso digo busco plugins
19/08/2019 03:01 AM
Encuentra todos sus mensajes Cita este mensaje en tu respuesta
Mariano Gyt Sin conexión
Miembro


Mensajes: 50
Registro en: Dec 2017
Reputación: 0
Mensaje: #6
RE: busco plugins de piss
Para que no se quede quieto meando, creo que tiene que sacar todo lo referido a max speed? Creo..
19/08/2019 02:23 PM
Visita su sitio web Encuentra todos sus mensajes Cita este mensaje en tu respuesta
potato02 Sin conexión
Miembro Junior


Trebol purpura
Mensajes: 42
Registro en: May 2019
Reputación: 0
Mensaje: #7
RE: busco plugins de piss
Mensaje: #6RE: busco plugins de piss
Para que no se quede quieto meando, creo que tiene que sacar todo lo referido a max speed? Creo..

nose como editar plugins quien me ayudaa
20/08/2019 02:24 PM
Encuentra todos sus mensajes Cita este mensaje en tu respuesta
rojedafeik Sin conexión
Miembro


Mensajes: 90
Registro en: Dec 2017
Reputación: 0
Mensaje: #8
RE: busco plugins de piss
Prueba este https://gamebanana.com/gamefiles/download/2936

"Deja a un lobo vivo y las ovejas nunca estarán a salvo."
Image
20/08/2019 03:05 PM
Encuentra todos sus mensajes Cita este mensaje en tu respuesta
potato02 Sin conexión
Miembro Junior


Trebol purpura
Mensajes: 42
Registro en: May 2019
Reputación: 0
Mensaje: #9
RE: busco plugins de piss
me ayudan con este plugins para que solo le funcione a los admin con acceso ADMIN_IMMUNITY
PORFA ... solo el piss funcione a los admin que tengan acceso

Código PHP:
/*

Plugin: Amxx Piss
Version: 2.0
Author: KRoTaL (Based on TakeADookie by PaintLancer)


1.0  Release
1.1  Better effect
1.2  Bug fix
1.3  New effect + piss puddle
1.4a New effects, only for cs/cz/dod
1.4b New effects, only for other mods than cs/cz/dod
1.5  #define NO_CS_CZ added
1.6  Bug fix (DoD)
1.7  Bug fix
1.8  Some checks added
1.9  #define NO_CS_CZ changed into #define NO_CS_CZ
2.0  New cvar : amx_piss_effect

Commands: 

    To piss on a dead body you have to bind a key to: piss
    Open your console and write: bind "key" "piss"
    ex: bind "x" "piss"
    Then stand still above a dead player (cs/cz only), press your key and you'll piss on them ! 
    You can control the direction of the stream with your mouse.
    You are not able to move or to shoot for 10 seconds when you piss, so beware (cs/cz only).
    The puddle of piss will appear where you are aiming at 2 seconds after you start pissing, 
    so try to aim at the dead body instead of the sky or a wall ;)

    Players can say "/piss" in the chat to get some help.

Cvars:

    amx_maxpees 6        -    Maximum number of times a player is allowed to piss per round.

    amx_piss_admin 0        -    0 : All the players are allowed to piss
                              1 : Only admins with ADMIN_LEVEL_A flag are allowed to piss

    amx_piss_effect 0        -    0 : yellow bloodsprite
                              1 : yellow laserbeam

Setup:

    You need to put these files on your server:

    sound/piss/pissing.wav
    models/piss/piss_puddle1.mdl  
    models/piss/piss_puddle2.mdl    
    models/piss/piss_puddle3.mdl       
    models/piss/piss_puddle4.mdl      
    models/piss/piss_puddle5.mdl     
    models/piss/piss.mdl

    You need to enable Fun and Engine Modules for cs/cs-cz.
    You need to enable Engine Module for the other mods.

 Credits:

    Rastin for his trousers fly sounds
    SLayer KL for his piss puddle models

*/

// UNCOMMENT IF YOU USE ANOTHER MOD THAN CS and CS-CZ
//#define NO_CS_CZ




/********************************************************************************​*******************/

#include <amxmodx> 
#if !defined NO_CS_CZ
#include <fun>
#endif
#include <engine>


new piss_model
new piss_sprite
new water_splash
new count_piss[33]
new 
count_puddle[33]
new 
bool:PissFlag[33]
new 
bool:aim[33]
new 
Float:aim_origin[33][3]
#if !defined NO_CS_CZ
new player_origins[33][3]
new 
mod_name[32]
#endif

public piss_on_player(id
{

if (
get_cvar_num("amx_maxpees")==0
    return 
PLUGIN_HANDLED 
if (!is_user_alive(id)) 
    return 
PLUGIN_HANDLED 
if ( (get_cvar_num("amx_piss_admin")==1) && !(get_user_flags(id) & ADMIN_LEVEL_A) )
{
    
console_print(id"[AMXX] You have not access to this command.")
    return 
PLUGIN_HANDLED
}
if(
PissFlag[id])
    return 
PLUGIN_HANDLED

#if !defined NO_CS_CZ
new player_origin[3], players[32], inum=0distlast_dist=99999last_id 

get_user_origin
(id,player_origin,0
get_players(players,inum,"b"
if (
inum>0) { 
    for (new 
i=0;i<inum;i++) { 
        if (
players[i]!=id) { 
            
dist get_distance(player_origin,player_origins[players[i]]) 
            if (
dist<last_dist) { 
                
last_id players[i
                
last_dist dist 
            

        } 
    } 
    if (
last_dist<80) { 
#endif
        
if (count_piss[id] > get_cvar_num("amx_maxpees")) { 
            
client_print(id,print_chat,"You can only piss on a player %d time%s in a round !"get_cvar_num("amx_maxpees"), (get_cvar_num("amx_maxpees")>1) ? "s" ""
            return 
PLUGIN_CONTINUE 
        
}
        new 
player_name[32
        
get_user_name(idplayer_name31)
        
#if !defined NO_CS_CZ
        
new dead_name[32]
        
get_user_name(last_iddead_name31)
        
client_print(0,print_chat,"%s Is Pissing On %s's Dead Body !! HaHaHaHa !!"player_namedead_name)
        
#else
        
client_print(0,print_chat,"%s Is Pissing !!"player_name)
        
#endif
        
count_piss[id]+=1
        count_puddle
[id]=1
        
new ids[1]
        
ids[0]=id
        PissFlag
[id]=true
        aim
[id]=false
        
#if !defined NO_CS_CZ
        
if( (equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
        {
            
client_cmd(id"weapon_knife")
            
set_user_maxspeed(id, -1.0)
        }
        
#endif
        
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"1.0ATTN_NORM0PITCH_NORM
        switch(
get_cvar_num("amx_piss_effect"))
        {
            case 
0:  set_task(0.2,"make_pee",1481+id,ids,1,"a",48)
            case 
1:  set_task(0.1,"make_pee",1481+id,ids,1,"a",102)
            default: 
set_task(0.2,"make_pee",1481+id,ids,1,"a",48)
        }
        
set_task(2.2,"place_puddle",3424+id,ids,1,"a",4)
        
#if !defined NO_CS_CZ
        
set_task(12.0,"weapons_back",6794+id,ids,1)
    }
    else
    {
        
client_print(id,print_chat,"There are no dead bodies around you.")
        return 
PLUGIN_HANDLED
    
}
}
#endif
return PLUGIN_HANDLED
}

public 
sqrt(num

    new 
div num 
    
new result 
    
while (div result) { 
        
div = (div result) / 
        result 
num div 
    

    return 
div 


public 
make_pee(ids[]) 

    new 
id=ids[0]
    new 
vec[3
    new 
aimvec[3
    new 
velocityvec[3
    new 
length 
    get_user_origin
(id,vec
    
get_user_origin(id,aimvec,3
    new 
distance get_distance(vec,aimvec
    new 
speed floatround(distance*1.9)

    
velocityvec[0]=aimvec[0]-vec[0
    
velocityvec[1]=aimvec[1]-vec[1
    
velocityvec[2]=aimvec[2]-vec[2

    
length=sqrt(velocityvec[0]*velocityvec[0]+velocityvec[1]*velocityvec[1]+velocityvec[2]*velocityvec[2]) 

    
velocityvec[0]=velocityvec[0]*speed/length 
    velocityvec
[1]=velocityvec[1]*speed/length 
    velocityvec
[2]=velocityvec[2]*speed/length 

    
switch(get_cvar_num("amx_piss_effect"))
    {
        case 
0:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(101)
            
write_coord(vec[0])
            
write_coord(vec[1])
            
write_coord(vec[2])
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]) 
            
write_byte(102// color
            
write_byte(160// speed
            
message_end()
        }
        case 
1:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY
            
write_byte(106
            
write_coord(vec[0]) 
            
write_coord(vec[1]) 
            
write_coord(vec[2]) 
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]+100
            
write_angle (0
            
write_short (piss_model
            
write_byte (0
            
write_byte (255
            
message_end()  

            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY
            
write_byte (1)    
            
write_short (id
            
write_coord(aimvec[0]) 
            
write_coord(aimvec[1]) 
            
write_coord(aimvec[2]) 
            
write_short(piss_sprite
            
write_byte// framestart 
            
write_byte// framerate 
            
write_byte// life 
            
write_byte// width 
            
write_byte// noise 
            
write_byte255 // r, g, b 
            
write_byte255 // r, g, b 
            
write_byte// r, g, b 
            
write_byte200 // brightness 
            
write_byte10 // speed 
            
message_end()

            
message_beginMSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(17)
            
write_coord(aimvec[0]) 
            
write_coord(aimvec[1]) 
            
write_coord(aimvec[2]) 
            
write_short(water_splash)
            
write_byte(16)
            
write_byte(18)
            
message_end()

        }
        default:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(101)
            
write_coord(vec[0])
            
write_coord(vec[1])
            
write_coord(vec[2])
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]) 
            
write_byte(102// color
            
write_byte(160// speed
            
message_end()
        }
    }


public 
place_puddle(ids[]) 
{
    new 
id=ids[0]
    if(!
aim[id])
    {
        new 
origin[3]
        
get_user_origin(id,origin,3
        
aim_origin[id][0]=float(origin[0])
        
aim_origin[id][1]=float(origin[1])
        
aim_origin[id][2]=float(origin[2])
    }

    new 
puddle_entity
    puddle_entity 
create_entity("info_target")

    if(
puddle_entity == 0) {
        return 
PLUGIN_HANDLED_MAIN
    
}

    new 
Float:MinBox[3]
    new 
Float:MaxBox[3]

    
MinBox[0] = -1.0
    MinBox
[1] = -1.0
    MinBox
[2] = -1.0
    MaxBox
[0] = 1.0
    MaxBox
[1] = 1.0
    MaxBox
[2] = 1.0

    entity_set_vector
(puddle_entityEV_VEC_minsMinBox)
    
entity_set_vector(puddle_entityEV_VEC_maxsMaxBox)

    switch(
count_puddle[id])
    {
        case 
1:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle1")
            
entity_set_model(puddle_entity"models/piss/piss_puddle1.mdl")
        }
        case 
2:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle2")
            
entity_set_model(puddle_entity"models/piss/piss_puddle2.mdl")
        }
        case 
3:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle3")
            
entity_set_model(puddle_entity"models/piss/piss_puddle3.mdl")
        }
        case 
4:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle4")
            
entity_set_model(puddle_entity"models/piss/piss_puddle4.mdl")
        }
        case 
5:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle5")
            
entity_set_model(puddle_entity"models/piss/piss_puddle5.mdl")
            
#if defined NO_CS_CZ
               
PissFlag[id]=false
            
#endif
        
}
        default: {}
    }

    
entity_set_origin(puddle_entityaim_origin[id])
    
entity_set_int(puddle_entityEV_INT_solid3)   
    
entity_set_int(puddle_entityEV_INT_movetype6
    
entity_set_edict(puddle_entityEV_ENT_ownerid)

    
count_puddle[id]+=1
    aim
[id]=true 

       
return PLUGIN_CONTINUE
}

public 
death_event() 

       new 
victim read_data(2)
     
#if !defined NO_CS_CZ      
    
get_user_origin(victim,player_origins[victim],0
    
#endif

    
if(PissFlag[victim]) 
        
reset_piss(victim)

       return 
PLUGIN_CONTINUE 
}

#if !defined NO_CS_CZ
public weapons_back(ids[]) 

       
PissFlag[ids[0]]=false 
    
if( (equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
    {
        
set_user_maxspeed(ids[0], 250.0)
    }
}

public 
cur_weapon(id

    if(
PissFlag[id]) 
    { 
        if( (
equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
        {
            
client_cmd(id"weapon_knife")
            
set_user_maxspeed(id, -1.0)
        }
    }

    return 
PLUGIN_CONTINUE

#endif

public reset_piss(id
{
    if(
task_exists(1481+id))
        
remove_task(1481+id)
    if(
task_exists(3424+id))
        
remove_task(3424+id)
    
#if !defined NO_CS_CZ
    
if(task_exists(6794+id))
        
remove_task(6794+id)
    
#endif
    
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"0.0ATTN_NORM0PITCH_NORM
    
PissFlag[id]=false

    
return PLUGIN_CONTINUE 
}

public 
reset_hud(id)
{
    if(
task_exists(1481+id))
        
remove_task(1481+id)
    if(
task_exists(3424+id))
        
remove_task(3424+id)
    
#if !defined NO_CS_CZ
    
if(task_exists(6794+id))
        
remove_task(6794+id)
    
#endif
    
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"0.0ATTN_NORM0PITCH_NORM
    
PissFlag[id]=false

    
new iCurrent

    
for (new i=i<count_piss[id] ; i++)
    {                
        
iCurrent find_ent_by_class(-1"piss_puddle1")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle2")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle3")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle4")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle5")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
      }
    
count_piss[id]=1

    
return PLUGIN_CONTINUE 


public 
piss_help(id
{
    
client_print(idprint_chat"To piss on a dead body you have to bind a key to: piss")
    
client_print(idprint_chat"Open your console and write: bind ^"key^" ^"piss^"")
    
client_print(idprint_chat"ex: bind ^"x^" ^"piss^"")

    return 
PLUGIN_CONTINUE
}

public 
handle_say(id
{
    new 
said[192]
    
read_args(said,192)
    
remove_quotes(said)

    if( (
containi(said"piss") != -1) && !(containi(said"/piss") != -1) ) {
        
client_print(idprint_chat"[AMXX] For Piss help say /piss")
    }

    return 
PLUGIN_CONTINUE
}

public 
plugin_precache() 

    if (
file_exists("sound/piss/pissing.wav"))
        
precache_sound"piss/pissing.wav")   
    if (
file_exists("models/piss/piss_puddle1.mdl"))      
        
precache_model("models/piss/piss_puddle1.mdl")  
    if (
file_exists("models/piss/piss_puddle2.mdl"))      
        
precache_model("models/piss/piss_puddle2.mdl"
    if (
file_exists("models/piss/piss_puddle3.mdl"))      
        
precache_model("models/piss/piss_puddle3.mdl"
    if (
file_exists("models/piss/piss_puddle4.mdl"))      
        
precache_model("models/piss/piss_puddle4.mdl"
    if (
file_exists("models/piss/piss_puddle5.mdl"))      
        
precache_model("models/piss/piss_puddle5.mdl"
    if (
file_exists("models/piss/piss.mdl"))      
        
piss_model precache_model("models/piss/piss.mdl")  
    
piss_sprite precache_model("sprites/plasma.spr")
    
water_splash precache_model("sprites/wsplash3.spr")

       return 
PLUGIN_CONTINUE 
}

public 
client_connect(id)
{
    
PissFlag[id]=false
    count_piss
[id]=1
    
    
return PLUGIN_CONTINUE
}

public 
client_disconnect(id)
{
    
reset_hud(id)

    return 
PLUGIN_CONTINUE
}

public 
plugin_init() 

    
register_plugin("AMXX Piss","2.0","KRoTaL"
    
register_clcmd("piss","piss_on_player",0,"- Piss on a dead player"
    
register_clcmd("say /piss","piss_help",0,"- Displays piss help"
    
register_clcmd("say","handle_say")
    
register_cvar("amx_maxpees","6")
    
register_cvar("amx_piss_admin","0")
    
register_cvar("amx_piss_effect","0")
    
register_event("DeathMsg","death_event","a"
    
register_event("ResetHUD""reset_hud""be")
    
#if !defined NO_CS_CZ
    
register_event("CurWeapon","cur_weapon","be","1=1")
    
get_modname(mod_name,31)
    
#endif

    
return PLUGIN_CONTINUE

20/08/2019 10:04 PM
Encuentra todos sus mensajes Cita este mensaje en tu respuesta
Mariano Gyt Sin conexión
Miembro


Mensajes: 50
Registro en: Dec 2017
Reputación: 0
Mensaje: #10
RE: busco plugins de piss
(20/08/2019 10:04 PM)potato02 escribió:  me ayudan con este plugins para que solo le funcione a los admin con acceso ADMIN_IMMUNITY
PORFA ... solo el piss funcione a los admin que tengan acceso

Código PHP:
/*

Plugin: Amxx Piss
Version: 2.0
Author: KRoTaL (Based on TakeADookie by PaintLancer)


1.0  Release
1.1  Better effect
1.2  Bug fix
1.3  New effect + piss puddle
1.4a New effects, only for cs/cz/dod
1.4b New effects, only for other mods than cs/cz/dod
1.5  #define NO_CS_CZ added
1.6  Bug fix (DoD)
1.7  Bug fix
1.8  Some checks added
1.9  #define NO_CS_CZ changed into #define NO_CS_CZ
2.0  New cvar : amx_piss_effect

Commands: 

    To piss on a dead body you have to bind a key to: piss
    Open your console and write: bind "key" "piss"
    ex: bind "x" "piss"
    Then stand still above a dead player (cs/cz only), press your key and you'll piss on them ! 
    You can control the direction of the stream with your mouse.
    You are not able to move or to shoot for 10 seconds when you piss, so beware (cs/cz only).
    The puddle of piss will appear where you are aiming at 2 seconds after you start pissing, 
    so try to aim at the dead body instead of the sky or a wall ;)

    Players can say "/piss" in the chat to get some help.

Cvars:

    amx_maxpees 6        -    Maximum number of times a player is allowed to piss per round.

    amx_piss_admin 0        -    0 : All the players are allowed to piss
                              1 : Only admins with ADMIN_LEVEL_A flag are allowed to piss

    amx_piss_effect 0        -    0 : yellow bloodsprite
                              1 : yellow laserbeam

Setup:

    You need to put these files on your server:

    sound/piss/pissing.wav
    models/piss/piss_puddle1.mdl  
    models/piss/piss_puddle2.mdl    
    models/piss/piss_puddle3.mdl       
    models/piss/piss_puddle4.mdl      
    models/piss/piss_puddle5.mdl     
    models/piss/piss.mdl

    You need to enable Fun and Engine Modules for cs/cs-cz.
    You need to enable Engine Module for the other mods.

 Credits:

    Rastin for his trousers fly sounds
    SLayer KL for his piss puddle models

*/

// UNCOMMENT IF YOU USE ANOTHER MOD THAN CS and CS-CZ
//#define NO_CS_CZ




/********************************************************************************​*******************/

#include <amxmodx> 
#if !defined NO_CS_CZ
#include <fun>
#endif
#include <engine>


new piss_model
new piss_sprite
new water_splash
new count_piss[33]
new 
count_puddle[33]
new 
bool:PissFlag[33]
new 
bool:aim[33]
new 
Float:aim_origin[33][3]
#if !defined NO_CS_CZ
new player_origins[33][3]
new 
mod_name[32]
#endif

public piss_on_player(id
{

if (
get_cvar_num("amx_maxpees")==0
    return 
PLUGIN_HANDLED 
if (!is_user_alive(id)) 
    return 
PLUGIN_HANDLED 
if ( (get_cvar_num("amx_piss_admin")==1) && !(get_user_flags(id) & ADMIN_LEVEL_A) )
{
    
console_print(id"[AMXX] You have not access to this command.")
    return 
PLUGIN_HANDLED
}
if(
PissFlag[id])
    return 
PLUGIN_HANDLED

#if !defined NO_CS_CZ
new player_origin[3], players[32], inum=0distlast_dist=99999last_id 

get_user_origin
(id,player_origin,0
get_players(players,inum,"b"
if (
inum>0) { 
    for (new 
i=0;i<inum;i++) { 
        if (
players[i]!=id) { 
            
dist get_distance(player_origin,player_origins[players[i]]) 
            if (
dist<last_dist) { 
                
last_id players[i
                
last_dist dist 
            

        } 
    } 
    if (
last_dist<80) { 
#endif
        
if (count_piss[id] > get_cvar_num("amx_maxpees")) { 
            
client_print(id,print_chat,"You can only piss on a player %d time%s in a round !"get_cvar_num("amx_maxpees"), (get_cvar_num("amx_maxpees")>1) ? "s" ""
            return 
PLUGIN_CONTINUE 
        
}
        new 
player_name[32
        
get_user_name(idplayer_name31)
        
#if !defined NO_CS_CZ
        
new dead_name[32]
        
get_user_name(last_iddead_name31)
        
client_print(0,print_chat,"%s Is Pissing On %s's Dead Body !! HaHaHaHa !!"player_namedead_name)
        
#else
        
client_print(0,print_chat,"%s Is Pissing !!"player_name)
        
#endif
        
count_piss[id]+=1
        count_puddle
[id]=1
        
new ids[1]
        
ids[0]=id
        PissFlag
[id]=true
        aim
[id]=false
        
#if !defined NO_CS_CZ
        
if( (equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
        {
            
client_cmd(id"weapon_knife")
            
set_user_maxspeed(id, -1.0)
        }
        
#endif
        
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"1.0ATTN_NORM0PITCH_NORM
        switch(
get_cvar_num("amx_piss_effect"))
        {
            case 
0:  set_task(0.2,"make_pee",1481+id,ids,1,"a",48)
            case 
1:  set_task(0.1,"make_pee",1481+id,ids,1,"a",102)
            default: 
set_task(0.2,"make_pee",1481+id,ids,1,"a",48)
        }
        
set_task(2.2,"place_puddle",3424+id,ids,1,"a",4)
        
#if !defined NO_CS_CZ
        
set_task(12.0,"weapons_back",6794+id,ids,1)
    }
    else
    {
        
client_print(id,print_chat,"There are no dead bodies around you.")
        return 
PLUGIN_HANDLED
    
}
}
#endif
return PLUGIN_HANDLED
}

public 
sqrt(num

    new 
div num 
    
new result 
    
while (div result) { 
        
div = (div result) / 
        result 
num div 
    

    return 
div 


public 
make_pee(ids[]) 

    new 
id=ids[0]
    new 
vec[3
    new 
aimvec[3
    new 
velocityvec[3
    new 
length 
    get_user_origin
(id,vec
    
get_user_origin(id,aimvec,3
    new 
distance get_distance(vec,aimvec
    new 
speed floatround(distance*1.9)

    
velocityvec[0]=aimvec[0]-vec[0
    
velocityvec[1]=aimvec[1]-vec[1
    
velocityvec[2]=aimvec[2]-vec[2

    
length=sqrt(velocityvec[0]*velocityvec[0]+velocityvec[1]*velocityvec[1]+velocityvec[2]*velocityvec[2]) 

    
velocityvec[0]=velocityvec[0]*speed/length 
    velocityvec
[1]=velocityvec[1]*speed/length 
    velocityvec
[2]=velocityvec[2]*speed/length 

    
switch(get_cvar_num("amx_piss_effect"))
    {
        case 
0:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(101)
            
write_coord(vec[0])
            
write_coord(vec[1])
            
write_coord(vec[2])
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]) 
            
write_byte(102// color
            
write_byte(160// speed
            
message_end()
        }
        case 
1:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY
            
write_byte(106
            
write_coord(vec[0]) 
            
write_coord(vec[1]) 
            
write_coord(vec[2]) 
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]+100
            
write_angle (0
            
write_short (piss_model
            
write_byte (0
            
write_byte (255
            
message_end()  

            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY
            
write_byte (1)    
            
write_short (id
            
write_coord(aimvec[0]) 
            
write_coord(aimvec[1]) 
            
write_coord(aimvec[2]) 
            
write_short(piss_sprite
            
write_byte// framestart 
            
write_byte// framerate 
            
write_byte// life 
            
write_byte// width 
            
write_byte// noise 
            
write_byte255 // r, g, b 
            
write_byte255 // r, g, b 
            
write_byte// r, g, b 
            
write_byte200 // brightness 
            
write_byte10 // speed 
            
message_end()

            
message_beginMSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(17)
            
write_coord(aimvec[0]) 
            
write_coord(aimvec[1]) 
            
write_coord(aimvec[2]) 
            
write_short(water_splash)
            
write_byte(16)
            
write_byte(18)
            
message_end()

        }
        default:
        {
            
message_begin(MSG_BROADCAST,SVC_TEMPENTITY)
            
write_byte(101)
            
write_coord(vec[0])
            
write_coord(vec[1])
            
write_coord(vec[2])
            
write_coord(velocityvec[0]) 
            
write_coord(velocityvec[1]) 
            
write_coord(velocityvec[2]) 
            
write_byte(102// color
            
write_byte(160// speed
            
message_end()
        }
    }


public 
place_puddle(ids[]) 
{
    new 
id=ids[0]
    if(!
aim[id])
    {
        new 
origin[3]
        
get_user_origin(id,origin,3
        
aim_origin[id][0]=float(origin[0])
        
aim_origin[id][1]=float(origin[1])
        
aim_origin[id][2]=float(origin[2])
    }

    new 
puddle_entity
    puddle_entity 
create_entity("info_target")

    if(
puddle_entity == 0) {
        return 
PLUGIN_HANDLED_MAIN
    
}

    new 
Float:MinBox[3]
    new 
Float:MaxBox[3]

    
MinBox[0] = -1.0
    MinBox
[1] = -1.0
    MinBox
[2] = -1.0
    MaxBox
[0] = 1.0
    MaxBox
[1] = 1.0
    MaxBox
[2] = 1.0

    entity_set_vector
(puddle_entityEV_VEC_minsMinBox)
    
entity_set_vector(puddle_entityEV_VEC_maxsMaxBox)

    switch(
count_puddle[id])
    {
        case 
1:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle1")
            
entity_set_model(puddle_entity"models/piss/piss_puddle1.mdl")
        }
        case 
2:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle2")
            
entity_set_model(puddle_entity"models/piss/piss_puddle2.mdl")
        }
        case 
3:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle3")
            
entity_set_model(puddle_entity"models/piss/piss_puddle3.mdl")
        }
        case 
4:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle4")
            
entity_set_model(puddle_entity"models/piss/piss_puddle4.mdl")
        }
        case 
5:
        {          
            
entity_set_string(puddle_entityEV_SZ_classname"piss_puddle5")
            
entity_set_model(puddle_entity"models/piss/piss_puddle5.mdl")
            
#if defined NO_CS_CZ
               
PissFlag[id]=false
            
#endif
        
}
        default: {}
    }

    
entity_set_origin(puddle_entityaim_origin[id])
    
entity_set_int(puddle_entityEV_INT_solid3)   
    
entity_set_int(puddle_entityEV_INT_movetype6
    
entity_set_edict(puddle_entityEV_ENT_ownerid)

    
count_puddle[id]+=1
    aim
[id]=true 

       
return PLUGIN_CONTINUE
}

public 
death_event() 

       new 
victim read_data(2)
     
#if !defined NO_CS_CZ      
    
get_user_origin(victim,player_origins[victim],0
    
#endif

    
if(PissFlag[victim]) 
        
reset_piss(victim)

       return 
PLUGIN_CONTINUE 
}

#if !defined NO_CS_CZ
public weapons_back(ids[]) 

       
PissFlag[ids[0]]=false 
    
if( (equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
    {
        
set_user_maxspeed(ids[0], 250.0)
    }
}

public 
cur_weapon(id

    if(
PissFlag[id]) 
    { 
        if( (
equali(mod_name,"cstrike")) || (equali(mod_name,"czero")) )
        {
            
client_cmd(id"weapon_knife")
            
set_user_maxspeed(id, -1.0)
        }
    }

    return 
PLUGIN_CONTINUE

#endif

public reset_piss(id
{
    if(
task_exists(1481+id))
        
remove_task(1481+id)
    if(
task_exists(3424+id))
        
remove_task(3424+id)
    
#if !defined NO_CS_CZ
    
if(task_exists(6794+id))
        
remove_task(6794+id)
    
#endif
    
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"0.0ATTN_NORM0PITCH_NORM
    
PissFlag[id]=false

    
return PLUGIN_CONTINUE 
}

public 
reset_hud(id)
{
    if(
task_exists(1481+id))
        
remove_task(1481+id)
    if(
task_exists(3424+id))
        
remove_task(3424+id)
    
#if !defined NO_CS_CZ
    
if(task_exists(6794+id))
        
remove_task(6794+id)
    
#endif
    
emit_sound(id,CHAN_VOICE,"piss/pissing.wav"0.0ATTN_NORM0PITCH_NORM
    
PissFlag[id]=false

    
new iCurrent

    
for (new i=i<count_piss[id] ; i++)
    {                
        
iCurrent find_ent_by_class(-1"piss_puddle1")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle2")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle3")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle4")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
        
iCurrent find_ent_by_class(-1"piss_puddle5")
        if(
iCurrent != -1)
            
remove_entity(iCurrent)
      }
    
count_piss[id]=1

    
return PLUGIN_CONTINUE 


public 
piss_help(id
{
    
client_print(idprint_chat"To piss on a dead body you have to bind a key to: piss")
    
client_print(idprint_chat"Open your console and write: bind ^"key^" ^"piss^"")
    
client_print(idprint_chat"ex: bind ^"x^" ^"piss^"")

    return 
PLUGIN_CONTINUE
}

public 
handle_say(id
{
    new 
said[192]
    
read_args(said,192)
    
remove_quotes(said)

    if( (
containi(said"piss") != -1) && !(containi(said"/piss") != -1) ) {
        
client_print(idprint_chat"[AMXX] For Piss help say /piss")
    }

    return 
PLUGIN_CONTINUE
}

public 
plugin_precache() 

    if (
file_exists("sound/piss/pissing.wav"))
        
precache_sound"piss/pissing.wav")   
    if (
file_exists("models/piss/piss_puddle1.mdl"))      
        
precache_model("models/piss/piss_puddle1.mdl")  
    if (
file_exists("models/piss/piss_puddle2.mdl"))      
        
precache_model("models/piss/piss_puddle2.mdl"
    if (
file_exists("models/piss/piss_puddle3.mdl"))      
        
precache_model("models/piss/piss_puddle3.mdl"
    if (
file_exists("models/piss/piss_puddle4.mdl"))      
        
precache_model("models/piss/piss_puddle4.mdl"
    if (
file_exists("models/piss/piss_puddle5.mdl"))      
        
precache_model("models/piss/piss_puddle5.mdl"
    if (
file_exists("models/piss/piss.mdl"))      
        
piss_model precache_model("models/piss/piss.mdl")  
    
piss_sprite precache_model("sprites/plasma.spr")
    
water_splash precache_model("sprites/wsplash3.spr")

       return 
PLUGIN_CONTINUE 
}

public 
client_connect(id)
{
    
PissFlag[id]=false
    count_piss
[id]=1
    
    
return PLUGIN_CONTINUE
}

public 
client_disconnect(id)
{
    
reset_hud(id)

    return 
PLUGIN_CONTINUE
}

public 
plugin_init() 

    
register_plugin("AMXX Piss","2.0","KRoTaL"
    
register_clcmd("piss","piss_on_player",0,"- Piss on a dead player"
    
register_clcmd("say /piss","piss_help",0,"- Displays piss help"
    
register_clcmd("say","handle_say")
    
register_cvar("amx_maxpees","6")
    
register_cvar("amx_piss_admin","0")
    
register_cvar("amx_piss_effect","0")
    
register_event("DeathMsg","death_event","a"
    
register_event("ResetHUD""reset_hud""be")
    
#if !defined NO_CS_CZ
    
register_event("CurWeapon","cur_weapon","be","1=1")
    
get_modname(mod_name,31)
    
#endif

    
return PLUGIN_CONTINUE


ADMIN_LEVEL_A cambialo por ADMIN_IMMUNITY y para que le sirva solo a los admins activalo amx_piss_admin "1"
(Este mensaje fue modificado por última vez en: 21/08/2019 12:24 AM por Mariano Gyt.)
21/08/2019 12:24 AM
Visita su sitio web Encuentra todos sus mensajes Cita este mensaje en tu respuesta
Enviar respuesta 


Salto de foro:


Usuario(s) navegando en este tema: 1 invitado(s)

Contáctanos | Allied Modders en español | Volver arriba | Volver al contenido | Archivo (Modo simple) | Sindicación RSS