Raised This Month: $ Target: $400
 0% 

[ JailBreak ] Box Match


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
satelitegames
Member
Join Date: Nov 2010
Old 03-05-2012 , 12:55   [ JailBreak ] Box Match
Reply With Quote #1

Hello I wonder what this error and the plugin, it works correctly but when a prisoner kills another Frag and he loses money, how do I get this not happen?


Sorry my bad English




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

#define PLUGIN "JailBreak BOX" 
#define VERSION "0.1" 
#define AUTHOR "" 
 
new iFFiHandler
 
public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)

    
iFF get_cvar_pointer("mp_friendlyfire")
    
iHandler get_pcvar_num(iFF)

    
register_clcmd("say /box""cmd_Box")
    
    
    
RegisterHam(Ham_TraceAttack "player" "FwdTraceAttack")
}

public 
cmd_Box(id) {
    
// If The Player isn't Connected Or if the Player Not Alive
    
if(!is_user_connected(id) || !is_user_alive(id)) {
        
// Avsluta koden
        
return PLUGIN_HANDLED
    
}

    
// If The Player Not Are CT
    
if(cs_get_user_team(id) != CS_TEAM_CT) {
        
// Skriv att bara CT kan göra det
        
set_hudmessage(00200,-1.0, -1.0 ,06.012.0)
        
show_hudmessage(id"Apenas Guardas podem usar este comando")

        
// Avsluta koden
        
return PLUGIN_HANDLED
    
}

    switch(
iHandler) {
        case 
0: {
            
server_cmd("mp_friendlyfire 1")
            
set_hudmessage(02550, -1.0, -1.006.012.0)
            
show_hudmessage(id"Box Ativado!")
        }

        case 
1: {
            
server_cmd("mp_friendlyfire 0")
            
set_hudmessage(25500, -1.0, -1.006.012.0)
            
show_hudmessage(id"Box Desativado!")
        }
    }

    
iHandler = !iHandler 

    
return PLUGIN_HANDLED 


/*************************************************************************
***************************** T Friendly Fire ***************************
**************************************************************************/
public FwdTraceAttack(idattackerFloat:dmgFloat:dir[3], trdmgbit) {
    static 
CsTeams:ct_Team
    
if(iHandler) {
        
ct_Team cs_get_user_team(id)
        return ((
ct_Team == CS_TEAM_CT) && (ct_Team == cs_get_user_team(attacker))) ? HAM_SUPERCEDE HAM_IGNORED
    
}
    return 
HAM_IGNORED



Sure, and that this part here:

PHP Code:
public FwdTraceAttack(idattackerFloat:dmgFloat:dir[3], trdmgbit) {
    static 
CsTeams:ct_Team
    
if(iHandler) {
        
ct_Team cs_get_user_team(id)
        return ((
ct_Team == CS_TEAM_CT) && (ct_Team == cs_get_user_team(attacker))) ? HAM_SUPERCEDE HAM_IGNORED
    
}
    return 
HAM_IGNORED

__________________





Last edited by satelitegames; 03-05-2012 at 12:57.
satelitegames is offline
Carlen20
Senior Member
Join Date: Jun 2011
Location: Sweden
Old 03-06-2012 , 01:57   Re: [ JailBreak ] Box Match
Reply With Quote #2

Quote:
Originally Posted by satelitegames View Post
Hello I wonder what this error and the plugin, it works correctly but when a prisoner kills another Frag and he loses money, how do I get this not happen?


Sorry my bad English




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

#define PLUGIN "JailBreak BOX" 
#define VERSION "0.1" 
#define AUTHOR "Greenmaw" 
 
new iFFiHandler
 
public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)

    
iFF get_cvar_pointer("mp_friendlyfire")
    
iHandler get_pcvar_num(iFF)

    
register_clcmd("say /box""cmd_Box")
    
    
    
RegisterHam(Ham_TraceAttack "player" "FwdTraceAttack")
}

public 
cmd_Box(id) {
    
// If The Player isn't Connected Or if the Player Not Alive
    
if(!is_user_connected(id) || !is_user_alive(id)) {
        
// Avsluta koden
        
return PLUGIN_HANDLED
    
}

    
// If The Player Not Are CT
    
if(cs_get_user_team(id) != CS_TEAM_CT) {
        
// Skriv att bara CT kan göra det
        
set_hudmessage(00200,-1.0, -1.0 ,06.012.0)
        
show_hudmessage(id"Apenas Guardas podem usar este comando")

        
// Avsluta koden
        
return PLUGIN_HANDLED
    
}

    switch(
iHandler) {
        case 
0: {
            
server_cmd("mp_friendlyfire 1")
            
set_hudmessage(02550, -1.0, -1.006.012.0)
            
show_hudmessage(id"Box Ativado!")
        }

        case 
1: {
            
server_cmd("mp_friendlyfire 0")
            
set_hudmessage(25500, -1.0, -1.006.012.0)
            
show_hudmessage(id"Box Desativado!")
        }
    }

    
iHandler = !iHandler 

    
return PLUGIN_HANDLED 


/*************************************************************************
***************************** T Friendly Fire ***************************
**************************************************************************/
public FwdTraceAttack(idattackerFloat:dmgFloat:dir[3], trdmgbit) {
    static 
CsTeams:ct_Team
    
if(iHandler) {
        
ct_Team cs_get_user_team(id)
        return ((
ct_Team == CS_TEAM_CT) && (ct_Team == cs_get_user_team(attacker))) ? HAM_SUPERCEDE HAM_IGNORED
    
}
    return 
HAM_IGNORED



Sure, and that this part here:

PHP Code:
public FwdTraceAttack(idattackerFloat:dmgFloat:dir[3], trdmgbit) {
    static 
CsTeams:ct_Team
    
if(iHandler) {
        
ct_Team cs_get_user_team(id)
        return ((
ct_Team == CS_TEAM_CT) && (ct_Team == cs_get_user_team(attacker))) ? HAM_SUPERCEDE HAM_IGNORED
    
}
    return 
HAM_IGNORED

AUTHOR = Greenmaw (Greenmaw = me)
__________________
Nothing are impossible if you just use your mind!

Quote:
Originally Posted by NiceGuyx View Post
P.S: i'm the best coder here


Last edited by Carlen20; 03-06-2012 at 01:58.
Carlen20 is offline
satelitegames
Member
Join Date: Nov 2010
Old 03-06-2012 , 06:57   Re: [ JailBreak ] Box Match
Reply With Quote #3

Sorry to withdraw the rights, but as it has many plugins forum for each of these places your credits then do not know who created it real
__________________




satelitegames is offline
Carlen20
Senior Member
Join Date: Jun 2011
Location: Sweden
Old 03-06-2012 , 08:41   Re: [ JailBreak ] Box Match
Reply With Quote #4

I've create that plugin -.- i upploaded it here for some weeks ago
__________________
Nothing are impossible if you just use your mind!

Quote:
Originally Posted by NiceGuyx View Post
P.S: i'm the best coder here

Carlen20 is offline
satelitegames
Member
Join Date: Nov 2010
Old 03-09-2012 , 07:08   Re: [ JailBreak ] Box Match
Reply With Quote #5

but you could help me fix it?
__________________




satelitegames is offline
Carlen20
Senior Member
Join Date: Jun 2011
Location: Sweden
Old 03-09-2012 , 10:51   Re: [ JailBreak ] Box Match
Reply With Quote #6

Sure
__________________
Nothing are impossible if you just use your mind!

Quote:
Originally Posted by NiceGuyx View Post
P.S: i'm the best coder here

Carlen20 is offline
XoSeR
Junior Member
Join Date: Aug 2011
Old 03-10-2012 , 05:29   Re: [ JailBreak ] Box Match
Reply With Quote #7

It's not a problem mod, this command I think.
XoSeR is offline
Carlen20
Senior Member
Join Date: Jun 2011
Location: Sweden
Old 03-10-2012 , 06:20   Re: [ JailBreak ] Box Match
Reply With Quote #8

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

#define PLUGIN "JailBreak BOX" 
#define VERSION "0.1" 
#define AUTHOR "Greenmaw" 
 
new iFFiHandler
new iCash[33]

public 
plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_event("DeathMsg""Event_DeathMsg""a")
    
    
iFF get_cvar_pointer("mp_friendlyfire")
    
iHandler get_pcvar_num(iFF)

    
register_clcmd("say /box""cmd_Box")
    
    
    
RegisterHam(Ham_TraceAttack "player" "FwdTraceAttack")
}

public 
cmd_Box(id) {
    
// If the user not connected or not alive
    
if(!is_user_connected(id) || !is_user_alive(id)) {
        
// End The Code
        
return PLUGIN_HANDLED
    
}

    
// if the user not are CT 
    
if(cs_get_user_team(id) != CS_TEAM_CT) {
        
// Write That Only CT Can Use That Command
        
set_hudmessage(00200,-1.0, -1.0 ,06.012.0)
        
show_hudmessage(id"Only CT Can Use This Command")

        
// End The Code
        
return PLUGIN_HANDLED
    
}

    switch(
iHandler) {
        case 
0: {
            
server_cmd("mp_friendlyfire 1")
            
set_hudmessage(02550, -1.0, -1.006.012.0)
            
show_hudmessage(id"Jailbreak Box Activated!")
        }

        case 
1: {
            
server_cmd("mp_friendlyfire 0")
            
set_hudmessage(25500, -1.0, -1.006.012.0)
            
show_hudmessage(id"Jailbreak Box Deactivated!")
        }
    }
    

    
iHandler = !iHandler 

    
return PLUGIN_HANDLED 


public 
Event_DeathMsg()
{
    new 
iKiller read_data(1)
    new 
iVictim read_data(2)
    new 
iHeadshot read_data(3)
    
    if(
cs_get_user_team(iVictim) == CS_TEAM_T && is_user_alive(iKiller))
    {
        if(
iHeadshot)
            
iCash[iKiller] += 80
        
else
            
iCash[iKiller] += 40
    
}
}

/*************************************************************************
***************************** T Friendly Fire ***************************
**************************************************************************/
public FwdTraceAttack(idattackerFloat:dmgFloat:dir[3], trdmgbit) {
    static 
CsTeams:ct_Team
    
if(iHandler) {
        
ct_Team cs_get_user_team(id)
        return ((
ct_Team == CS_TEAM_CT) && (ct_Team == cs_get_user_team(attacker))) ? HAM_SUPERCEDE HAM_IGNORED
    
}
    return 
HAM_IGNORED

This would probably work pm me for more help.
__________________
Nothing are impossible if you just use your mind!

Quote:
Originally Posted by NiceGuyx View Post
P.S: i'm the best coder here

Carlen20 is offline
satelitegames
Member
Join Date: Nov 2010
Old 03-11-2012 , 19:42   Re: [ JailBreak ] Box Match
Reply With Quote #9

Thanks I will test
__________________




satelitegames is offline
Carlen20
Senior Member
Join Date: Jun 2011
Location: Sweden
Old 03-12-2012 , 02:43   Re: [ JailBreak ] Box Match
Reply With Quote #10

Quote:
Originally Posted by satelitegames View Post
Thanks I will test
np
__________________
Nothing are impossible if you just use your mind!

Quote:
Originally Posted by NiceGuyx View Post
P.S: i'm the best coder here

Carlen20 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 23:54.


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