←  Prośby o Klasę/Perk

AMXX.pl: Support AMX Mod X i SourceMod

»

Perk
7 perków, awp snajper

Locked

cruel's Photo cruel 04.11.2012

Witam!

Czy zrobi ktoś takie perki na cod nowy? Ważne, aby były sprawdzone i działały.

Naboje pułkownika -
zadają 20 dodatkowe
obrażenia
Naboje oficera - zadają 15
dodatkowych obrażeń
AWP sniper -
natychmiastowe zabicie z
awp
SCOUT sniper -
natychmiastowe zabicie ze
scouta
Naboje kapitana - zadają
25 dodatkowych obrażeń, co
5 sekund tracisz 5 hp (proszę
o sprawdzoną i działającą
wersję)
Podręcznik szpiega -
posiadasz ubranie wroga,
masz 1/LW szans na
natychmiastowe zabicie z he;
chcę aby było 1/1-6 (też
proszę o sprawną i działającą
wersję)
Tajemnica generała-natychmiastowe zabicie z he
Quote

Emil29's Photo Emil29 04.11.2012

Awp sniper


/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <hamsandwich>
#include <fun>
#include <codmod>

#define DMG_BULLET (1<<1)

new const perk_name[] = "AWP Snajper";
new const perk_desc[] = "Natychmiastowe zabicie z AWP";

new bool:ma_perk[33];

public plugin_init()
{
register_plugin(perk_name, "1.0", "QTM_Peyote");

cod_register_perk(perk_name, perk_desc);
RegisterHam(Ham_TakeDamage, "player", "TakeDamage");
}

public cod_perk_enabled(id)
{
cod_give_weapon(id, CSW_AWP);
ma_perk[id] = true;
}

public cod_perk_disabled(id)
{
cod_take_weapon(id, CSW_AWP);
ma_perk[id] = false;
}

public TakeDamage(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;

if(!ma_perk[idattacker])
return HAM_IGNORED;

if(get_user_team(this) != get_user_team(idattacker) && get_user_weapon(idattacker) == CSW_AWP && damagebits & DMG_BULLET)
cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);

return HAM_IGNORED;
}

Quote

cruel's Photo cruel 04.11.2012

Mam takie cos na serwerze juz i nie dziala...
Quote

  • +
  • -
Split's Photo Split 04.11.2012

Naboje pulkownika:
#include <amxmodx>
#include <hamsandwich>
#include <codmod>
new const perk_name[] = "Naboje Pulkownika";
new const perk_desc[] = "Zadajesz 20 obrazen wiecej";
new bool:ma_perk[33];
new wartosc_perku[33];
public plugin_init()
{
register_plugin(perk_name, "1.0", "sCerR*!");
cod_register_perk(perk_name, perk_desc, 20, 20);

RegisterHam(Ham_TakeDamage, "player", "TakeDamage");
}
public cod_perk_enabled(id, wartosc)
{
ma_perk[id] = true;
wartosc_perku[id] = wartosc;
}
public cod_perk_disabled(id)
ma_perk[id] = false;
public TakeDamage(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
  return HAM_IGNORED;

if(ma_perk[idattacker])
  cod_inflict_damage(idattacker, this, float(wartosc_perku[idattacker]), 0.0, idinflictor, damagebits);

return HAM_IGNORED;
}

Podrecznik Szpiega:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <codmod>
#include <hamsandwich>
#include <cstrike>

new const nazwa[] = "Podrecznik Szpiega";
new const opis[] = "Masz 1/LW szans na natychmiastowe zabicie z HE. Posiadasz ubranie wroga";

new const CT_Skins[][] = {"sas","gsg9","urban","gign"};
new const Terro_Skins[][] = {"arctic","leet","guerilla","terror"};

new bool:ma_klase[33];
new wartosc_perku[33];
new num[33];

#define DMG_HEGRENADE (1<<24)


public plugin_init()
{
register_plugin(nazwa, "1.0", "QTM_Peyote");

cod_register_perk(nazwa, opis, 1, 3);

RegisterHam(Ham_TakeDamage, "player", "TakeDamage");
RegisterHam(Ham_Spawn, "player", "Odrodzenie", 1);

}

public cod_perk_enabled(id, wartosc)
{
ma_klase[id] = true;
wartosc_perku[id] = wartosc;
cod_give_weapon(id, CSW_HEGRENADE);
num[id] = random_num(0, 3);
cs_set_user_model(id, (get_user_team(id) == 1)? CT_Skins[num[id]]: Terro_Skins[num[id]]);
}

public cod_perk_disabled(id)
{
ma_klase[id] = false;
cod_take_weapon(id, CSW_HEGRENADE);
cs_set_user_model(id, (get_user_team(id) == 1)? Terro_Skins[num[id]]: CT_Skins[num[id]]);
num[id] = 0;
}

public TakeDamage(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;

if(!ma_klase[idattacker])
return HAM_IGNORED;

if(get_user_team(this) != get_user_team(idattacker) && damagebits & DMG_HEGRENADE && random_num(1, wartosc_perku[idattacker]) == 1)
cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);

return HAM_IGNORED;
}
public Odrodzenie(id)
{
if(ma_klase[id])
{
cs_set_user_model(id, (get_user_team(id) == 1)? CT_Skins[num[id]]: Terro_Skins[num[id]]);
}
}

Tajemnica Generala:

/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <hamsandwich>
#include <cstrike>
#include <fun>
#include <codmod>

#define DMG_HEGRENADE (1<<24)

new const perk_name[] = "Tajemnica Generala";
new const perk_desc[] = "Zadajesz 100(+inteligencja) obrazen z HE";

new bool:ma_perk[33];

public plugin_init()
{
register_plugin(perk_name, "1.0", "QTM_Peyote");

cod_register_perk(perk_name, perk_desc);
RegisterHam(Ham_TakeDamage, "player", "TakeDamage");
}

public cod_perk_enabled(id)
{
ma_perk[id] = true;
cod_give_weapon(id, CSW_HEGRENADE);
}

public cod_perk_disabled(id)
{
ma_perk[id] = false;
cod_take_weapon(id, CSW_HEGRENADE);
}

public TakeDamage(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;

if(!ma_perk[idattacker])
return HAM_IGNORED;

if(damagebits & DMG_HEGRENADE && get_user_team(this) != get_user_team(idattacker))
cod_inflict_damage(idattacker, this, 101.0-damage, 1.0, idinflictor, damagebits);

return HAM_IGNORED;
}

Edited by Jotpe, 04.11.2012 17:05.
Quote

cruel's Photo cruel 04.11.2012

Zadajesz 100(+inteligencja) obrazen z HE

Nie chodziło mi o 100 obrażeń! Tylko natychmiastowe zabicie!
Quote

  • +
  • -
Split's Photo Split 04.11.2012

new const perk_desc[] = "Zadajesz 100(+inteligencja) obrazen z HE";

100 obrazen to 1/1 z HE
Quote

cruel's Photo cruel 04.11.2012

nieee chyba na codzie niektórzy mają więcej hp niż 100? Np. 200
Quote

  • +
  • -
Split's Photo Split 04.11.2012

Na wszystkich sma jest 100 :P to wiec...
Sprawdz na servie moge cie zapewnic ze 1/1 jest
Edited by Jotpe, 04.11.2012 17:38.
Quote

cruel's Photo cruel 04.11.2012

Nie możesz mnie zapewnić, bo używałem już tego perku i zadaje 100 obrażeń, a nie zabija od razu, jak to było w starym codzie....
Quote

  • +
  • -
Split's Photo Split 04.11.2012

Scout sniper:

/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <hamsandwich>
#include <fun>
#include <codmod>

#define DMG_BULLET (1<<1)

new const perk_name[] = "Scout Sniper";
new const perk_desc[] = "Natychmiastowe zabicie z Scouta";

new bool:ma_perk[33];

public plugin_init() 
{
register_plugin(perk_name, "1.0", "QTM_Peyote");

cod_register_perk(perk_name, perk_desc);
RegisterHam(Ham_TakeDamage, "player", "TakeDamage");
}

public cod_perk_enabled(id)
{
cod_give_weapon(id, CSW_SCOUT);
ma_perk[id] = true;
}

public cod_perk_disabled(id)
{
cod_take_weapon(id, CSW_SCOUT);
ma_perk[id] = false;
}

public TakeDamage(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;

if(!ma_perk[idattacker])
return HAM_IGNORED;

if(get_user_team(this) != get_user_team(idattacker) && get_user_weapon(idattacker) == CSW_SCOUT && damagebits & DMG_BULLET)
cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);

return HAM_IGNORED;
}

/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par }
*/
Quote

cruel's Photo cruel 04.11.2012

Te #include <fun> musi być, bo skompilowałem bez niego :D

Awp i scout nie działa... niech zrobi ktoś sprawdzone i działające
Quote

  • +
  • -
Split's Photo Split 04.11.2012

Nie dziala bo usunales chyba fun w Perku Scout Sniper :facepalm:
Quote

cruel's Photo cruel 04.11.2012

Bez fun dziala juz :P jeszcze tylko ps i tg, ale z natychmiastowym zabiciem! a nie 100 obrazen

Jednak nie dziala, ani z fun, ani bez... przetestuj najpierw dawaj....
Quote

Emil29's Photo Emil29 04.11.2012

Mam takie cos na serwerze juz i nie dziala...


Jak może nie działać? :facepalm:

Naboje oficera

#include <amxmodx>
#include <hamsandwich>
#include <codmod>
new const perk_name[] = "Naboje Oficera";
new const perk_desc[] = "Zadajesz LW obrazen wiecej";
new bool:ma_perk[33];
new wartosc_perku[33];
public plugin_init()
{
register_plugin(perk_name, "1.0", "Emil29");
cod_register_perk(perk_name, perk_desc, 15, 15);

RegisterHam(Ham_TakeDamage, "player", "TakeDamage");
}
public cod_perk_enabled(id, wartosc)
{
ma_perk[id] = true;
wartosc_perku[id] = wartosc;
}
public cod_perk_disabled(id)
ma_perk[id] = false;
public TakeDamage(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;

if(ma_perk[idattacker])
cod_inflict_damage(idattacker, this, float(wartosc_perku[idattacker]), 0.0, idinflictor, damagebits);

return HAM_IGNORED;
}
Quote

cruel's Photo cruel 04.11.2012

Oficerki dzialaja i pulki tez, potrzebuje ps, tg, awp i scout bo nie dzialaja. Niech ktos da poprawne .sma aby dzialalo tez u was na serwie. U mnie kilku adminow i graczy testuje i nic....

A moze to przez to, ze klasy maja kamizelki wbudowane? Bo np. komandos tez nie zabija za pierwszym razem
Quote

cruel's Photo cruel 04.11.2012

Ok wszystko już działa oprócz tajemnicy generała i podręczniku szpiega. Ma ktoś działające wersje?
Quote

cruel's Photo cruel 06.11.2012

odświeżam
Quote

Emil29's Photo Emil29 07.11.2012

Te perki co Jotpe dodał działają i to są właśnie działające wersje!
Quote

Gość_21977_* 12.11.2012

Wiadomość wygenerowana automatycznie


Ten temat został zamknięty przez moderatora.

Powód: Autor tematu zbanowany

Jeśli się z tym nie zgadzasz, Posted Image raportuj ten post, a moderator lub administrator rozpatrzy go ponownie.


Z pozdrowieniami,
Zespół AMXX.PL
Quote
Locked