Raised This Month: $ Target: $400
 0% 

[ES][ZP] Bullet Damage en el Zombie Plague


  
 
 
Thread Tools Display Modes
Author Message
Fail!
BANNED
Join Date: Jan 2010
Location: BFTCommunity
Old 02-01-2010 , 22:46   [ES][ZP] Bullet Damage en el Zombie Plague
#1

Hola.

Otra vez solicitando ayuda.
Ayer me pasaron un plugin que era de la despedida de un usuario. El nombre con el que me lo pasaron era: "Copia de mi Despedida.sma"

Lo mire un rato y encontre un bullet damage pero no me funciono. Alguien sabria decirme porque?

Primero dejo en el "plugin_init" lo siguiente:

PHP Code:
register_event("Damage""on_damage""b""2!0""3=0""4!0"
Y despues al final de todo el Zombie Plague:

PHP Code:
// Bullet Damage
public on_damage(id)
{
    if(
g_enabled)
    {       
        static 
attackerattacker get_user_attacker(id)
        static 
damagedamage read_data(2)   
        
        if(
g_showrecieved)
        {           
            
set_hudmessage(255000.450.5020.14.00.10.1, -1)
            
ShowSyncHudMsg(idg_hudmsg2"%i^n"damage)
        }
        
        if(
is_user_connected(attacker))
        {
            switch(
g_enabled)
            {
                case 
1:
                {
                    if (!
g_zombie[attacker] || g_survivor[attacker])
                    {
                        new 
iHealth get_user_health(id)
                        
set_hudmessage(0100200, -1.00.5520.14.00.020.02, -1)
                        
ShowSyncHudMsg(attackerg_hudmsg1"Damage: %i^nHP Restante: %d^n"damagedamage iHealth 20 iHealth)
                    }
                    else
                    {
                        if (
g_plagueround || g_nemround || g_swarmround)
                        {
                            new 
iHealth get_user_health(id)
                            
set_hudmessage(0100200, -1.00.5520.14.00.020.02, -1)
                            
ShowSyncHudMsg(attackerg_hudmsg1"Damage: %i^nHP Restante: %d^n"damagedamage iHealth 20 iHealth)
                        }
                        else
                        {
                            
set_hudmessage(0100200, -1.00.5520.14.00.020.02, -1)
                            
ShowSyncHudMsg(attackerg_hudmsg1"Damage: %i^n"damage)
                        }
                    }
                }
                case 
2:
                {
                    new 
iHealth get_user_health(id)
                    
set_hudmessage(02550, -1.00.5520.14.00.020.02, -1)
                    
ShowSyncHudMsg(attackerg_hudmsg1"Damage: %i^nHP Restante: %d^n"damage,  damage iHealth 20 iHealth)       
                }
            }
        }
    }

Fail! is offline
Send a message via MSN to Fail!
sombrilla
Veteran Member
Join Date: Apr 2009
Location: Buenos Aires
Old 02-01-2010 , 23:15   Re: [ES][ZP] Bullet Damage en el Zombie Plague
#2

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <zombieplague>

public plugin_init()
{
    
register_event("Damage""event_damage""b" "2!0""3=0""4!0")
}

public 
event_damage(victim)
{
    
set_hudmessage(002551.00.706.012.0)
    
show_hudmessage(get_user_attacker(victim), "[Damage: %d]^n[Vida: %d]",read_data(2),get_user_health(victim))

Ese me lo habia hecho Jaivi creo
__________________

sombrilla is offline
Send a message via MSN to sombrilla
Javivi
AlliedModders Donor
Join Date: Dec 2008
Old 02-02-2010 , 08:25   Re: [ES][ZP] Bullet Damage en el Zombie Plague
#3

Quote:
Originally Posted by sombrilla View Post
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <zombieplague>

public plugin_init()
{
    
register_event("Damage""event_damage""b" "2!0""3=0""4!0")
}

public 
event_damage(victim)
{
    
set_hudmessage(002551.00.706.012.0)
    
show_hudmessage(get_user_attacker(victim), "[Damage: %d]^n[Vida: %d]",read_data(2),get_user_health(victim))

Ese me lo habia hecho Jaivi creo
Creo que no fui yo.

Yo lo tengo en el takedamage, porque es inutil registrar otro evento que ya esta registrado con ham.

Despues de
PHP Code:
    // Attacker is human...
    
if (!g_zombie[attacker])
    {
        
// Armor multiplier for the final damage on normal zombies
        
if (!g_nemesis[victim])
        {
            
damage *= get_pcvar_float(cvar_zombiearmor)
            
SetHamParamFloat(4damage)
        } 
Pones
PHP Code:
            set_hudmessage(0100200, -1.00.5510.12.50.020.02, -1)
            
ShowSyncHudMsg(attackerg_MsgSync"DMG : %i^n"floatround(damage)) 
Y ya.
__________________
Javivi is offline
Starsailor
horrible hahah
Join Date: Aug 2008
Location: Buenos Aires
Old 02-02-2010 , 08:43   Re: [ES][ZP] Bullet Damage en el Zombie Plague
#4

Quote:
Originally Posted by sombrilla View Post
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <zombieplague>

public plugin_init()
{
    
register_event("Damage""event_damage""b" "2!0""3=0""4!0")
}

public 
event_damage(victim)
{
    
set_hudmessage(002551.00.706.012.0)
    
show_hudmessage(get_user_attacker(victim), "[Damage: %d]^n[Vida: %d]",read_data(2),get_user_health(victim))

Ese me lo habia hecho Jaivi creo
Lo habia hecho yo a ese, el include <zombieplague> es innecesario ahi
__________________
Find my plugins here..

Ex - Spanish Moderator.
Starsailor is offline
Fail!
BANNED
Join Date: Jan 2010
Location: BFTCommunity
Old 02-02-2010 , 09:43   Re: [ES][ZP] Bullet Damage en el Zombie Plague
#5

Es decir que lo que yo pase recien esta mal por eso no me funcionaba no?
Fail! is offline
Send a message via MSN to Fail!
sombrilla
Veteran Member
Join Date: Apr 2009
Location: Buenos Aires
Old 02-02-2010 , 10:45   Re: [ES][ZP] Bullet Damage en el Zombie Plague
#6

Quote:
Originally Posted by Starsailor View Post
Lo habia hecho yo a ese, el include <zombieplague> es innecesario ahi
Perdon q me halla olvidado , ah ok ni me habia fijado
__________________

sombrilla is offline
Send a message via MSN to sombrilla
SoldierPRO
Junior Member
Join Date: Mar 2013
Location: Monterrey N.L
Old 04-02-2013 , 00:08   Re: [ES][ZP] Bullet Damage en el Zombie Plague
#7

Pero Como lo instalo XD es que no se usar mucho amxmodx y soy new
__________________
SoldierPRO Helping people to have a good server
SoldierPRO is offline
Send a message via MSN to SoldierPRO Send a message via Skype™ to SoldierPRO
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 00:18.


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