Cerere First Kill

Categoria cu cereri de pluginuri si nu numai.

Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com

Forum rules
Accesează link-ul pentru a putea vedea regulile forumului

Daca doriti sa vi se modifice un plugin, va rugam postati aici .
Post Reply
User avatar
FaTzZu
Fost moderator
Fost moderator
Posts: 1206
Joined: 22 Dec 2012, 18:37
Detinator Steam: Da
Reputatie: Fost moderator ajutator
Has thanked: 114 times
Been thanked: 168 times

12 Aug 2013, 13:48

Salut am acest plugin facut de Askhanar

As dori ca primul care face frag sa primeasca 2 credite, dar sa se ia in considerare doar primul care face frag, indiferent de echipa.

First kill | Afiseaza codul
#include < amxmodx >
#include < cstrike >
 
#define PLUGIN "FirstKill Bonuses"
#define VERSION "1.0"

enum
{
	TERRO_KILL,
	CT_KILL,
	
	MAX_KILLS
}

new g_iFirstKillMoney[ MAX_KILLS ];
new bool:g_bFirstKillWasMade[ MAX_KILLS ];

new SyncHudMessage;
new g_iMaxPlayers;

public plugin_init( )
{
	register_plugin( PLUGIN, VERSION, "Askhanar" );
	
	register_event(  "HLTV",  "ev_NewRound",  "a",  "1=0",  "2=0"  );
	register_event(  "DeathMsg",  "ev_DeathMsg",  "a"  );
	
	// --| Banii primiti pentru fiecare first kill.
	g_iFirstKillMoney[ TERRO_KILL ] = 2000;		// --| FirstKill de la TERO
	g_iFirstKillMoney[ CT_KILL ] = 2000;		// --| FirstKill de la CT
	
	g_bFirstKillWasMade[ TERRO_KILL ] = false;
	g_bFirstKillWasMade[ CT_KILL ] = false;
	
	SyncHudMessage = CreateHudSyncObj( );
	g_iMaxPlayers = get_maxplayers( );
	// Add your code here...
}

public ev_NewRound( )
{
	g_bFirstKillWasMade[ TERRO_KILL ] = false;
	g_bFirstKillWasMade[ CT_KILL ] = false;
	
}

public ev_DeathMsg( )
{	
	
	static iKiller, iVictim;
	iKiller = read_data( 1 );
	iVictim = read_data( 2 );
	
	
	if( ( 1 <= iKiller <= g_iMaxPlayers ) && iKiller != iVictim )
	{
		
		if(  cs_get_user_team( iKiller ) == CS_TEAM_T && !g_bFirstKillWasMade[ TERRO_KILL ] )
		{
			g_bFirstKillWasMade[ TERRO_KILL ] = true;
			cs_set_user_money( iKiller, clamp( cs_get_user_money( iKiller ) + g_iFirstKillMoney[ TERRO_KILL ], 0, 16000 ), 1 );
			
			static szKillerName[ 32 ], szVictimName[ 32 ];
			
			get_user_name( iKiller, szKillerName, sizeof ( szKillerName ) -1 );
			get_user_name( iVictim, szVictimName, sizeof ( szVictimName ) -1 );
			
			set_hudmessage( 0, 255, 255, -1.0, 0.30, 0, 0.0, 4.5, 0.0, 0.0, -1 );
			ShowSyncHudMsg( 0, SyncHudMessage, "[T] %s a facut primul frag pe %s^n si a primit bonus %i$ !",
					szKillerName, szVictimName, g_iFirstKillMoney[ TERRO_KILL ] );
			
		}
		
		else if(  cs_get_user_team( iKiller ) == CS_TEAM_CT && !g_bFirstKillWasMade[ CT_KILL ] )
		{
			g_bFirstKillWasMade[ CT_KILL ] = true;
			cs_set_user_money( iKiller, clamp( cs_get_user_money( iKiller ) + g_iFirstKillMoney[ CT_KILL ], 0, 16000 ), 1 );
			
			static szKillerName[ 32 ], szVictimName[ 32 ];
			
			get_user_name( iKiller, szKillerName, sizeof ( szKillerName ) -1 );
			get_user_name( iVictim, szVictimName, sizeof ( szVictimName ) -1 );
			
			set_hudmessage( 0, 255, 255, -1.0, 0.30, 0, 0.0, 4.5, 0.0, 0.0, -1 );
			ShowSyncHudMsg( 0, SyncHudMessage, "[CT] %s a facut primul frag pe %s^n si a primit bonus %i$ !",
					szKillerName, szVictimName, g_iFirstKillMoney[ CT_KILL ] );
			
		}
		
	}
	
}
Iar include pentru credite
fcs | Afiseaza codul
#if defined _fcs_included
	#endinput
#endif

#define _fcs_included



/*
 * Returns a players credits
 * 
 * @param		client - The player index to get points of
 * 
 * @return		The credits client
 * 
 */

native fcs_get_user_credits(client);

/*
 * Sets <credits> to client
 * 
 * @param		client - The player index to set points to
 * @param		credits - The amount of credits to set to client
 * 
 * @return		The credits of client
 * 
 */

native fcs_set_user_credits(client, credits);

/*
 * Adds <credits> points to client
 * 
 * @param		client - The player index to add points to
 * @param		credits - The amount of credits to add to client
 * 
 * @return		The credits of client
 * 
 */

stock fcs_add_user_credits(client, credits)
{
	return fcs_set_user_credits(client, fcs_get_user_credits(client) + credits);
}

/*
 * Subtracts <credits>  from client
 * 
 * @param		client - The player index to subtract points from
 * @param		credits - The amount of credits to substract from client
 * 
 * @return		The credits of client
 * 
 */

stock fcs_sub_user_credits(client, credits)
{
	return fcs_set_user_credits(client, fcs_get_user_credits(client) - credits);
}
A fool's brain digests philosophy into folly, science into superstition, and art into pedantry.

#RETIRED.
RoyalServer
User avatar
Ulquiorra
Fost moderator
Fost moderator
Posts: 2053
Joined: 25 Jul 2010, 17:29
Detinator Steam: Da
CS Status: A mai trecut o zi asteptand una mai buna
Detinator server CS: Retras.
SteamID: STEAM_0:1:318247XX
Reputatie: Fost Scripter eXtreamCS
Fost Moderator ajutator
Nick anterior: Askhanar
Location: Braila, Romania.
Has thanked: 215 times
Been thanked: 1132 times

12 Aug 2013, 16:36

| Afiseaza codul
/* Plugin generated by AMXX-Studio */

#include < amxmodx >
#include < cstrike >

#define PLUGIN "FirstKill Bonuses"
#define VERSION "1.0"

/*
 * Returns a players credits
 * 
 * @param		client - The player index to get points of
 * 
 * @return		The credits client
 * 
 */

native fcs_get_user_credits(client);

/*
 * Sets <credits> to client
 * 
 * @param		client - The player index to set points to
 * @param		credits - The amount of credits to set to client
 * 
 * @return		The credits of client
 * 
 */

native fcs_set_user_credits(client, credits);

/*
 * Adds <credits> points to client
 * 
 * @param		client - The player index to add points to
 * @param		credits - The amount of credits to add to client
 * 
 * @return		The credits of client
 * 
 */

stock fcs_add_user_credits(client, credits)
{
	return fcs_set_user_credits(client, fcs_get_user_credits(client) + credits);
}

/*
 * Subtracts <credits>  from client
 * 
 * @param		client - The player index to subtract points from
 * @param		credits - The amount of credits to substract from client
 * 
 * @return		The credits of client
 * 
 */

stock fcs_sub_user_credits(client, credits)
{
	return fcs_set_user_credits(client, fcs_get_user_credits(client) - credits);
}

enum
{
	TERRO_CREDITS,
	CT_CREDITS,
	
	MAX_CREDITS
}

new g_iFirstKillCredits[ MAX_CREDITS ];
new bool:g_bFirstKillWasMade;

new SyncHudMessage;
new g_iMaxPlayers;

public plugin_init( )
{
	register_plugin( PLUGIN, VERSION, "Askhanar" );
	
	register_event(  "HLTV",  "ev_NewRound",  "a",  "1=0",  "2=0"  );
	register_event(  "DeathMsg",  "ev_DeathMsg",  "a"  );
	
	// --| Banii primiti pentru fiecare first kill.
	g_iFirstKillCredits[ TERRO_CREDITS ] = 20;		// --| FirstKill de la TERO
	g_iFirstKillCredits[ CT_CREDITS ] = 15;		// --| FirstKill de la CT
	
	g_bFirstKillWasMade= false;
	
	SyncHudMessage = CreateHudSyncObj( );
	g_iMaxPlayers = get_maxplayers( );
	// Add your code here...
}

public ev_NewRound( )	g_bFirstKillWasMade = false;

public ev_DeathMsg( )
{	
	
	static iKiller, iVictim;
	iKiller = read_data( 1 );
	iVictim = read_data( 2 );
	
	
	if( ( 1 <= iKiller <= g_iMaxPlayers ) && iKiller != iVictim )
	{
		
		if( cs_get_user_team( iKiller ) == CS_TEAM_T && !g_bFirstKillWasMade )
		{
			g_bFirstKillWasMade = true;
			fcs_add_user_credits( iKiller, g_iFirstKillCredits[ TERRO_CREDITS ] );
			
			static szKillerName[ 32 ], szVictimName[ 32 ];
			
			get_user_name( iKiller, szKillerName, sizeof ( szKillerName ) -1 );
			get_user_name( iVictim, szVictimName, sizeof ( szVictimName ) -1 );
			
			set_hudmessage( 0, 255, 255, -1.0, 0.30, 0, 0.0, 4.5, 0.0, 0.0, -1 );
			ShowSyncHudMsg( 0, SyncHudMessage, "[T] %s a facut primul frag pe %s^n si a primit bonus %i credite !",
					szKillerName, szVictimName, g_iFirstKillCredits[ TERRO_CREDITS ] );
			
		}
		
		else if( cs_get_user_team( iKiller ) == CS_TEAM_CT && !g_bFirstKillWasMade )
		{
			g_bFirstKillWasMade = true;
			fcs_add_user_credits( iKiller, g_iFirstKillCredits[ CT_CREDITS ] );
			
			static szKillerName[ 32 ], szVictimName[ 32 ];
			
			get_user_name( iKiller, szKillerName, sizeof ( szKillerName ) -1 );
			get_user_name( iVictim, szVictimName, sizeof ( szVictimName ) -1 );
			
			set_hudmessage( 0, 255, 255, -1.0, 0.30, 0, 0.0, 4.5, 0.0, 0.0, -1 );
			ShowSyncHudMsg( 0, SyncHudMessage, "[T] %s a facut primul frag pe %s^n si a primit bonus %i credite !",
					szKillerName, szVictimName, g_iFirstKillCredits[ CT_CREDITS ] );
			
		}
		
	}
	
}
Untested.
Caut o persoana dedicata care se pricepe si stie ce face.
Vreau sa creeze si sa se ocupe de administrarea unui server de MU, da e vorba de vechiul joc..ma gandesc undeva la un season 3 ep1/2.

O sa achizitionez un domeniu .ro.
Totodata sponsorizez absolut orice este necesar.
Ma puteti contacta prin: http://solo.to/stfrzv
User avatar
Fantasy1
Utilizator neserios (tepar)
Utilizator neserios (tepar)
Posts: 4836
Joined: 05 Jul 2012, 01:26
Detinator Steam: Da
Reputatie: Membru Club eXtreamCS (1 Mar)
Utilizator neserios (TEPAR!)
Has thanked: 278 times
Been thanked: 217 times
Contact:

12 Aug 2013, 19:03

FaTzZu wrote:Salut am acest plugin facut de Askhanar

As dori ca primul care face frag sa primeasca 2 credite, dar sa se ia in considerare doar primul care face frag, indiferent de echipa.

First kill | Afiseaza codul
#include < amxmodx >
#include < cstrike >
 
#define PLUGIN "FirstKill Bonuses"
#define VERSION "1.0"

enum
{
	TERRO_KILL,
	CT_KILL,
	
	MAX_KILLS
}

new g_iFirstKillMoney[ MAX_KILLS ];
new bool:g_bFirstKillWasMade[ MAX_KILLS ];

new SyncHudMessage;
new g_iMaxPlayers;

public plugin_init( )
{
	register_plugin( PLUGIN, VERSION, "Askhanar" );
	
	register_event(  "HLTV",  "ev_NewRound",  "a",  "1=0",  "2=0"  );
	register_event(  "DeathMsg",  "ev_DeathMsg",  "a"  );
	
	// --| Banii primiti pentru fiecare first kill.
	g_iFirstKillMoney[ TERRO_KILL ] = 2000;		// --| FirstKill de la TERO
	g_iFirstKillMoney[ CT_KILL ] = 2000;		// --| FirstKill de la CT
	
	g_bFirstKillWasMade[ TERRO_KILL ] = false;
	g_bFirstKillWasMade[ CT_KILL ] = false;
	
	SyncHudMessage = CreateHudSyncObj( );
	g_iMaxPlayers = get_maxplayers( );
	// Add your code here...
}

public ev_NewRound( )
{
	g_bFirstKillWasMade[ TERRO_KILL ] = false;
	g_bFirstKillWasMade[ CT_KILL ] = false;
	
}

public ev_DeathMsg( )
{	
	
	static iKiller, iVictim;
	iKiller = read_data( 1 );
	iVictim = read_data( 2 );
	
	
	if( ( 1 <= iKiller <= g_iMaxPlayers ) && iKiller != iVictim )
	{
		
		if(  cs_get_user_team( iKiller ) == CS_TEAM_T && !g_bFirstKillWasMade[ TERRO_KILL ] )
		{
			g_bFirstKillWasMade[ TERRO_KILL ] = true;
			cs_set_user_money( iKiller, clamp( cs_get_user_money( iKiller ) + g_iFirstKillMoney[ TERRO_KILL ], 0, 16000 ), 1 );
			
			static szKillerName[ 32 ], szVictimName[ 32 ];
			
			get_user_name( iKiller, szKillerName, sizeof ( szKillerName ) -1 );
			get_user_name( iVictim, szVictimName, sizeof ( szVictimName ) -1 );
			
			set_hudmessage( 0, 255, 255, -1.0, 0.30, 0, 0.0, 4.5, 0.0, 0.0, -1 );
			ShowSyncHudMsg( 0, SyncHudMessage, "[T] %s a facut primul frag pe %s^n si a primit bonus %i$ !",
					szKillerName, szVictimName, g_iFirstKillMoney[ TERRO_KILL ] );
			
		}
		
		else if(  cs_get_user_team( iKiller ) == CS_TEAM_CT && !g_bFirstKillWasMade[ CT_KILL ] )
		{
			g_bFirstKillWasMade[ CT_KILL ] = true;
			cs_set_user_money( iKiller, clamp( cs_get_user_money( iKiller ) + g_iFirstKillMoney[ CT_KILL ], 0, 16000 ), 1 );
			
			static szKillerName[ 32 ], szVictimName[ 32 ];
			
			get_user_name( iKiller, szKillerName, sizeof ( szKillerName ) -1 );
			get_user_name( iVictim, szVictimName, sizeof ( szVictimName ) -1 );
			
			set_hudmessage( 0, 255, 255, -1.0, 0.30, 0, 0.0, 4.5, 0.0, 0.0, -1 );
			ShowSyncHudMsg( 0, SyncHudMessage, "[CT] %s a facut primul frag pe %s^n si a primit bonus %i$ !",
					szKillerName, szVictimName, g_iFirstKillMoney[ CT_KILL ] );
			
		}
		
	}
	
}
Iar include pentru credite
fcs | Afiseaza codul
#if defined _fcs_included
	#endinput
#endif

#define _fcs_included



/*
 * Returns a players credits
 * 
 * @param		client - The player index to get points of
 * 
 * @return		The credits client
 * 
 */

native fcs_get_user_credits(client);

/*
 * Sets <credits> to client
 * 
 * @param		client - The player index to set points to
 * @param		credits - The amount of credits to set to client
 * 
 * @return		The credits of client
 * 
 */

native fcs_set_user_credits(client, credits);

/*
 * Adds <credits> points to client
 * 
 * @param		client - The player index to add points to
 * @param		credits - The amount of credits to add to client
 * 
 * @return		The credits of client
 * 
 */

stock fcs_add_user_credits(client, credits)
{
	return fcs_set_user_credits(client, fcs_get_user_credits(client) + credits);
}

/*
 * Subtracts <credits>  from client
 * 
 * @param		client - The player index to subtract points from
 * @param		credits - The amount of credits to substract from client
 * 
 * @return		The credits of client
 * 
 */

stock fcs_sub_user_credits(client, credits)
{
	return fcs_set_user_credits(client, fcs_get_user_credits(client) - credits);
}
Chiar asa ati ajuns , plagiati la maxim?

:-j
CLICK AICI pentru FORUM
- Un Forum Care Nu Poate Fi Spart -
- Un Forum Care Nu Modifica Topicurile Cu Tepari -
- Vrei Indexare In Google? Posteaza Tzeparii La Noi -

- Daca ai nevoie sa te ajut cu un addons/plugin etc se plateste, nu ajut cu nimic pe GRATIS -
User avatar
FaNT4
Membru, skill +1
Membru, skill +1
Posts: 281
Joined: 28 Jul 2013, 16:42
Detinator Steam: Nu
Detinator server CS: ....
SteamID: dane_furiencso
Reputatie: Ban 2 luni!
Has thanked: 56 times
Been thanked: 18 times
Contact:

12 Aug 2013, 19:20

=)) Acum toti or inceput sa plagieze
Eu sunt exclus m-am lasat =))
Tu vrei plimbari, poze la rasarit,
Da astea-s pacate in lumea mea,si eu m-am spovedit


Daca te-am ajutat apasa pe: Image
mIRr0r# =D
Membru, skill 0
Membru, skill 0
Posts: 45
Joined: 27 Apr 2013, 21:55
Detinator Steam: Nu
CS Status: BB.DEVILCS.RO
Has thanked: 10 times
Been thanked: 1 time
Contact:

12 Aug 2013, 19:52

fantasy nu vad care ar fi problema :-j in toata treaba asta
Image
Server: (25:47) Bb.Proskill.Ro # BaseBuilder 6.5 , Cautam Admini
Ip: 95.64.36.30:27015
Name: PSR @ mIRr-0r.dll
Functie: Detinator + FTP
Rank/Top15: 1
User avatar
FaTzZu
Fost moderator
Fost moderator
Posts: 1206
Joined: 22 Dec 2012, 18:37
Detinator Steam: Da
Reputatie: Fost moderator ajutator
Has thanked: 114 times
Been thanked: 168 times

12 Aug 2013, 19:55

Ce ma? :O cine te-a plagiat frate , nu aveam habar ca tu ai pluginul pe server ... ideea mi-a venit pe moment :|


Si ca sa sti, eu si trr am avut primii idea, tu plagiand , uite si dovada
Link | Afiseaza codul
http://www.extreamcs.com/forum/cereri-c ... 89502.html
A fool's brain digests philosophy into folly, science into superstition, and art into pedantry.

#RETIRED.
User avatar
Rony
Utilizator neserios (tepar)
Utilizator neserios (tepar)
Posts: 966
Joined: 11 Mar 2013, 11:43
Detinator Steam: Da
CS Status: CO-FOUNDER BETANO
Detinator server CS: CS1.6 , CS:GO
SteamID: 31r1
Reputatie: Membru Club eXtreamCS (1 luna)
Membru Club eXtreamCs (28 Feb)
Utilizator neserios (tepar)
Location: NAPOLI
Has thanked: 173 times
Been thanked: 66 times
Contact:

12 Aug 2013, 20:14

plugin e primul care face frag in fiecare runda sau fiecare mapa?
User avatar
oneeightone
Fost moderator
Fost moderator
Posts: 2547
Joined: 17 Jul 2009, 19:29
Detinator Steam: Da
Reputatie: Fost super moderator
Membru Club eXtreamCS (o luna)
Nick anterior : LiGHTERS
0.3 / 3
Has thanked: 68 times
Been thanked: 521 times

12 Aug 2013, 20:17

Rony wrote:plugin e primul care face frag in fiecare runda sau fiecare mapa?
Fiecare runda.
User avatar
Rony
Utilizator neserios (tepar)
Utilizator neserios (tepar)
Posts: 966
Joined: 11 Mar 2013, 11:43
Detinator Steam: Da
CS Status: CO-FOUNDER BETANO
Detinator server CS: CS1.6 , CS:GO
SteamID: 31r1
Reputatie: Membru Club eXtreamCS (1 luna)
Membru Club eXtreamCs (28 Feb)
Utilizator neserios (tepar)
Location: NAPOLI
Has thanked: 173 times
Been thanked: 66 times
Contact:

12 Aug 2013, 20:17

oneeightone wrote:
Rony wrote:plugin e primul care face frag in fiecare runda sau fiecare mapa?
Fiecare runda.
multumesc
Post Reply

Return to “Cereri”

  • Information
  • Who is online

    Users browsing this forum: Google [Bot], Yandex [Bot] and 31 guests