1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21.
22.
23.
24.
25.
26.
27.
28.
29.
30.
31.
32.
33.
34.
35.
36.
37.
38.
39.
40.
41.
42.
43.
44.
45.
46.
47.
48.
49.
50.
51.
52.
53.
54.
55.
56.
57.
58.
59.
60.
61.
62.
63.
64.
65.
66.
67.
68.
69.
70.
71.
72.
73.
74.
75.
76.
77.
78.
79.
80.
81.
82.
83.
84.
85.
86.
87.
88.
89.
90.
91.
92.
93.
94.
95.
96.
97.
98.
99.
100.
101.
102.
103.
104.
105.
106.
107.
108.
109.
110.
111.
112.
113.
114.
115.
116.
117.
118.
119.
120. | /* Edited for BloodMan for Player Milioner */
#include <amxmodx>
#include <codmod>
#include <hamsandwich>
#include <engine>
#define DMG_BULLET (1<<1)
#define DMG_HEGRENADE (1<<24)
new const nazwa[] = "Determinator [Mega premium 25zl]";
new const opis[] = "1/1 kosa, 1/1 AWP, 1/2 he oraz niewidzialnosc na nozu w 80%";
new const bronie = 1<<CSW_M4A1 | 1<<CSW_MP5NAVY | 1<<CSW_SCOUT | 1<<CSW_HEGRENADE;
new const zdrowie = 40;
new const kondycja = 60;
new const inteligencja = 5;
new const wytrzymalosc = 45;
new bool:ma_klase[33];
public plugin_init()
{
register_plugin(nazwa, "1.0", "BloodMan");
cod_register_class(nazwa, opis, bronie, zdrowie, kondycja, inteligencja, wytrzymalosc);
RegisterHam(Ham_TakeDamage, "player", "ZabijZnoza");
RegisterHam(Ham_TakeDamage, "player", "ZabijZhe");
RegisterHam(Ham_TakeDamage, "player", "ZabijZawp");
register_event("CurWeapon", "NaNozu_Niewidzialnosc", "be", "1=1");
}
public cod_class_enabled(id)
{
if(!(get_user_flags(id) & ADMIN_LEVEL_E))
{
client_print(id, print_chat, "Determinator [Mega premium 25zl] Nie masz uprawnien, aby uzywac tej klasy.")
return COD_STOP;
}
ma_klase[id] = true;
return COD_CONTINUE;
}
public cod_class_disabled(id)
{
set_rendering(id,kRenderFxNone, 0, 0, 0, kRenderTransAlpha, 255);
ma_klase[id] = false;
}
public ZabijZnoza(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;
if(!ma_klase[idattacker])
return HAM_IGNORED;
if(get_user_weapon(idattacker) == CSW_KNIFE && damagebits & DMG_BULLET && damage > 20.0)
cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);
return HAM_IGNORED;
}
public ZabijZhe(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;
if(!ma_klase[idattacker])
return HAM_IGNORED;
if(damagebits & DMG_HEGRENADE && random_num(1, 2) == 1)
{
cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);
}
return HAM_IGNORED;
}
public ZabijZawp(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;
if(!ma_klase[idattacker])
return HAM_IGNORED;
if(damagebits & DMG_BULLET)
{
new weapon = get_user_weapon(idattacker);
if(weapon == CSW_AWP && damage > 20.0)
cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);
}
return HAM_IGNORED;
}
public NaNozu_Niewidzialnosc(id)
{
if(!ma_klase[id])
return;
if( read_data(2) == CSW_KNIFE )
{
set_rendering(id,kRenderFxNone, 0, 0, 0, kRenderTransAlpha, 30);
}
else
{
set_rendering(id,kRenderFxNone, 0, 0, 0, kRenderTransAlpha, 255);
}
}
|