Raised This Month: $ Target: $400
 0% 

Help to fix this plugin


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
vermillioN25
Member
Join Date: Apr 2009
Location: Brazil
Old 08-07-2009 , 19:42   Help to fix this plugin
Reply With Quote #1

Well, I edited original Jail Rebel from ConnorMcLeod

It's looking like this:

PHP Code:
#include <amxmodx>
#include <cstrike>
#include <hamsandwich>

#define VERSION "0.0.1"

#define MAX_PLAYERS    32
#define IsPlayer(%1)    ( 1 <= %1 <= g_iMaxPlayers )

new g_iTKills[MAX_PLAYERS+1]
new 
g_bRebel[MAX_PLAYERS+1]

new 
g_iMaxPlayers
new gmsgSayText

public plugin_init()
{
    
register_plugin("Jail Rebel"VERSION"ConnorMcLeod")

    
RegisterHam(Ham_Killed"player""Player_Killed_Post"1)

    
register_event("DeathMsg""Event_DeathMsg""a")
    
register_event("Damage""Event_Damage""b""2>0""3=0")

    
g_iMaxPlayers get_maxplayers()
    
gmsgSayText get_user_msgid("SayText")
}

public 
client_putinserver(id)
{
    
g_bRebel[id] = false
    g_iTKills
[id] = 0
}

public 
Player_Killed_Postid )
{
    if( 
is_user_aliveid ) )
    {
        
g_bRebel[id] = false
        g_iTKills
[id] = 0
    
}
}

public 
Event_DeathMsg()
{
    new 
iVictim read_data(2)
    if( 
cs_get_user_teamiVictim ) == CS_TEAM_T )
    {
        new 
iKiller read_data(1)
        if( 
IsPlayeriKiller ) && cs_get_user_teamiKiller ) == CS_TEAM_CT )
        {
            if( 
g_bRebel[iVictim] )
            {
            new 
szVName[32], szKName[32]
            
get_user_name(iVictimszVNamecharsmax(szVName))
            
get_user_name(iKillerszKNamecharsmax(szKName))
            
client_print(0print_chat"[JailBreak] O oficial "%s" matou o fugitivo "%s""szKNameszKName)
            }
            else if( ++
g_iTKills[iKiller] > )
            {
            new 
szKName[32]
            
get_user_name(iKillerszKNamecharsmax(szKName))
            
user_silentkilliKiller )
            
client_print(0print_chat"[JailBreak] O oficial "%s" foi morto apos ter matado mais de 2 prisioneiros"szKName)
            }
        }
    }
}

public 
Event_Damageid )
{
    if( (
read_data(4) || read_data(5) || read_data(6)) && cs_get_user_team(id) == CS_TEAM_CT )
    {
        new 
iAttacker get_user_attacker(id)
        if(    
IsPlayer(iAttacker)
        &&    !
g_bRebel[iAttacker]
        &&    
is_user_alive(iAttacker)
        &&    
cs_get_user_team(iAttacker) == CS_TEAM_T    )
            {
            new 
szName[32]
            
get_user_name(iAttackerszNamecharsmax(szName))
            
g_bRebel[iAttacker] = true
            client_print_c
(0"[JailBreak] O prisioneiro "%s" agora e um fugitivo!"szName)
        }
    } 
And I'm getting this errors:

Quote:
//AMXXPC compile.exe
// by the AMX Mod X Dev Team

//// jail_rebel.sma
// C:\Program Files\Valve\HLServer\cstrike\addons\amxmodx\s cripting\jail_rebel.s
ma(74) : error 017: undefined symbol "s"
// C:\Program Files\Valve\HLServer\cstrike\addons\amxmodx\s cripting\jail_rebel.s
ma(74) : error 017: undefined symbol "s"
// C:\Program Files\Valve\HLServer\cstrike\addons\amxmodx\s cripting\jail_rebel.s
ma(74) : warning 215: expression has no effect
// C:\Program Files\Valve\HLServer\cstrike\addons\amxmodx\s cripting\jail_rebel.s
ma(74) : warning 215: expression has no effect
// C:\Program Files\Valve\HLServer\cstrike\addons\amxmodx\s cripting\jail_rebel.s
ma(74) : warning 215: expression has no effect
// C:\Program Files\Valve\HLServer\cstrike\addons\amxmodx\s cripting\jail_rebel.s
ma(74) : error 001: expected token: ";", but found ")"
// C:\Program Files\Valve\HLServer\cstrike\addons\amxmodx\s cripting\jail_rebel.s
ma(74) : fatal error 107: too many error messages on one line
//
// Compilation aborted.
// 4 Errors.
// Could not locate output file compiled\jail_rebel.amx (compile failed).
//
// Compilation Time: 0,11 sec
// ----------------------------------------

Press enter to exit ...
Line 74 is:
PHP Code:
            client_print(0print_chat"[JailBreak] O oficial "%s" matou o fugitivo "%s""szKNameszKName

What's wrong?
__________________
vermillioN25 is offline
 


Thread Tools
Display Modes

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 18:27.


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