Bide şöyle denermisin ;
#1
Kod:
/* Plugin generated by AMXX-Studio */
#include <amxmodx>
#include <amxmisc>
// [+] JAIL INC //
#if defined _jail_included
#endinput
#endif
#define _jail_included
native jb_get_user_packs(id)
native jb_set_user_packs(id, ammount)
// [-] JAIL INC //
#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"
#define JBPACKS 15
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
register_event( "DeathMsg", "event_dmsg", "a" );
}
public event_dmsg( )
{
new victim = read_data( 2 );
if( get_user_team( victim ) == 1 )
{
new players[ 32 ], pnum;
get_players( players, pnum, "ae", "TERRORIST" );
if( pnum == 1 )
{
jb_set_user_packs( players[ 0 ], jb_get_user_packs( players[ 0 ] ) + JBPACKS );
}
}
}
#2
Kod:
/* Plugin generated by AMXX-Studio */
#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
// [+] JAIL INC //
#if defined _jail_included
#endinput
#endif
#define _jail_included
native jb_get_user_packs(id)
native jb_set_user_packs(id, ammount)
// [-] JAIL INC //
#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"
#define TIME 600.0
#define JBPACKS 15
new Float: g_PlayTime[ 33 ];
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
RegisterHam( Ham_Player_PreThink, "player", "fw_HamPreThink" );
}
public fw_HamPreThink( id )
{
if( is_user_connected( id ) )
{
if( get_gametime() - g_PlayTime[ id ] > TIME )
{
jb_set_user_packs( id, jb_get_user_packs( id ) + JBPACKS );
g_PlayTime[ id ] = get_gametime();
}
}
}