Raised This Month: $51 Target: $400
 12% 

[HELP] compilation error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Welgericht
Member
Join Date: Jul 2010
Old 09-13-2010 , 11:14   [HELP] compilation error
Reply With Quote #1

Hello everyone,

I have problem with plugin compilation,



PHP Code:
Error on line 21column 17encoding error 
my 21 line
PHP Code:
 new boolhas_deagle[33
Please help me, guys.
Welgericht is offline
Vechta
Veteran Member
Join Date: Jun 2010
Old 09-13-2010 , 11:22   Re: [HELP] compilation error
Reply With Quote #2

send whole code
Vechta is offline
Welgericht
Member
Join Date: Jul 2010
Old 09-13-2010 , 11:24   Re: [HELP] compilation error
Reply With Quote #3

here it is

Last edited by Welgericht; 09-13-2010 at 11:42.
Welgericht is offline
Vechta
Veteran Member
Join Date: Jun 2010
Old 09-13-2010 , 11:30   Re: [HELP] compilation error
Reply With Quote #4

try this:
PHP Code:
#include <amxmodx>
#include <zombieplague>
#include <hamsandwich>
#include <fun>
#include <cstrike>
#include <fakemeta>
#include <xs>

#define PLUGIN  "[EI] Dynamic deagle"
#define VERSION "beta"
#define AUTHOR  "twistedeuphoria/Emp`" //edited for usual zombieplague by Doomsday.

#define DEAGLE_COST 150
#define DEAGLE_FROST 1.0
#define DEAGLE_FIRE 3
#define DEAGLE_POWER 300.0
#define DEAGLE_SHOCK 500.0
#define DEAGLE_HEALTH 200
#define DEAGLE_AP_MIN 5
#define DEAGLE_AP_MAX 25

new has_deagle[33]
new 
g_msgScreenFade
new g_itemid_dd

public plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR);
    
zp_register_extra_item("Dynamic deagle"DEAGLE_COSTZP_TEAM_HUMAN);
    
    
register_event("DeathMsg""death""a");
    
g_msgScreenFade get_user_msgid("ScreenFade");
    
RegisterHam(Ham_TakeDamage"player""HamPreDamage");
}

public 
zp_extra_item_selected(idattackeritemid)
{
    if ( 
itemid == g_itemid_dd )
    {
        
has_deagle[idattacker] = true
        give_item
(idattacker"weapon_deagle")
        
cs_set_user_bpammo(idattackerCSW_DEAGLE254)
    }
}

public 
client_connect(id)
    
has_deagle[id] = false

public client_disconnect(id)
{
    
has_deagle[id] = false
}

public 
death(id)
    
has_deagle[id] = false

public zp_user_infected_post(idinfector)
    
has_deagle[id] = false

public HamPreDamage(thisidinflictoridattackerFloat:damagedamagebits)
{
    if(  
has_deagle[idattacker] && get_user_weapon(idattacker) == CSW_DEAGLE && !zp_get_user_nemesis(this))
    {
        switch( 
random(8) )
        {
            case 
1:
            {
                
zp_set_user_frozen(this1DEAGLE_FROST);
                
client_print(idattackerprint_center"Dynamic Deagle: Frost Shot");
                
client_print(thisprint_center"Dynamic Deagle: Frost Shot");
            }
            case 
2:
            {
                
zp_set_user_burn(thisDEAGLE_FIRE);
                
client_print(idattackerprint_center"Dynamic Deagle: Fire Shot");
                
client_print(thisprint_center"Dynamic Deagle: Fire Shot");
            }
            case 
3:
            {
                                        
client_print(idattackerprint_center"Dynamic Deagle: Black Shot");
                                        
client_print(thisprint_center"Dynamic Deagle: Black Shot");
                                        
message_begin(MSG_ONE_UNRELIABLEg_msgScreenFade_this)
                                        
write_short(UNIT_SECOND// duration
                                        
write_short(0// hold time
                                        
write_short(FFADE_IN// fade type
                                        
write_byte(0// red
                                        
write_byte(0// green
                                        
write_byte(0// blue
                                        
write_byte(255// alpha
                                        
message_end()
            }
            case 
4:
            {
                                        
client_print(idattackerprint_center"Dynamic Deagle: White Shot");
                                        
client_print(thisprint_center"Dynamic Deagle: White Shot");
                                        
message_begin(MSG_ONE_UNRELIABLEg_msgScreenFade_this)
                                        
write_short(UNIT_SECOND// duration
                                        
write_short(0// hold time
                                        
write_short(FFADE_IN// fade type
                                        
write_byte(255// red
                                        
write_byte(255// green
                                        
write_byte(255// blue
                                        
write_byte(255// alpha
                                        
message_end()
            }
            case 
5:
            {
                                        
client_print(idattackerprint_center"Dynamic Deagle: Power Shot");
                                        
client_print(thisprint_center"Dynamic Deagle: Power Shot");
                                        
SetHamParamFloat(4damage+DEAGLE_POWER);
            }
            case 
6:
            {
                                        
client_print(idattackerprint_center"Dynamic Deagle: Shock Shot");
                                        
client_print(thisprint_center"Dynamic Deagle: Shock Shot");
 
                                        new 
Float:start_origin[3], Float:end_origin[3];
                                        
pev(idattackerpev_originstart_origin);
                                        
pev(thispev_originend_origin);
                                        
start_origin[0] = end_origin[0] - start_origin[0];
                                        
start_origin[1] = end_origin[1] - start_origin[1];
                                        
start_origin[2] = 0.0;
                                        
xs_vec_normalizestart_originend_origin );
                                        
end_origin[0] *= DEAGLE_SHOCK;
                                        
end_origin[1] *= DEAGLE_SHOCK;
                                        
end_origin[2] = 50.0;
                                        
set_pev(thispev_velocityend_origin);
 
                                        
SetHamParamFloat(40.0);
            }
            case 
7:
            {
                                        
client_print(idattackerprint_center"Dynamic Deagle: Zombie Health Shot");
                                        
client_print(thisprint_center"Dynamic Deagle: Zombie Health Shot");
                                        
set_user_health(thisget_user_health(this)+DEAGLE_HEALTH);
            }
            default:
            {
                                        new 
ap_give random_num(DEAGLE_AP_MIN,DEAGLE_AP_MAX);
                                        
client_print(idattackerprint_center"Dynamic Deagle: +%d AP Shot",ap_give);
                                        
zp_set_user_ammo_packs(idattackerzp_get_user_ammo_packs(idattacker)+ap_give);
                                
            }
        }
    }

Vechta is offline
Welgericht
Member
Join Date: Jul 2010
Old 09-13-2010 , 11:41   Re: [HELP] compilation error
Reply With Quote #5

Vechta Thank you very much :]

Last edited by Welgericht; 09-13-2010 at 11:59.
Welgericht is offline
Reply



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 10:51.


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