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.
121.
122.
123.
124.
125.
126.
127.
128.
129.
130.
131.
132.
133.
134.
135.
136.
137.
138.
139.
140.
141.
142.
143.
144.
145.
146.
147.
148.
149.
150.
151.
152.
153.
154.
155.
156.
157.
158. | public exp_wybierz_2(id, menu_exp_2 , item)
{
new data[6], iName[64]
new acces, callback
menu_item_getinfo(menu_exp_2, item, acces, data,5, iName, 63, callback)
new klawisz = str_to_num(data)
switch(klawisz)
{
case 1: {
if(punkty[id] == 0) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Nie masz wystarczajacej ilosci punktow!");
}
else
{
if(punktychodzenie[id] >= 1) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Masz juz^x04 %i^x01 /^x04 1^x01!", punktychodzenie[id]);
}
else
{
punkty[id] -= 1;
punktychodzenie[id] += 1;
ColorChat(id, GREEN, "[CsStrefa]^x01 Dodawanie^x03 1 ^x01punktu do^x04 Cichego Chodzenia^x01 zakonczone!");
}
}
menu_destroy(menu_exp_2);
menu_xp_2(id);
Zapisz(id);
return PLUGIN_HANDLED;
}
case 2: {
if(punkty[id] == 0) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Nie masz wystarczajacej ilosci punktow!");
}
else
{
if(punktygranat[id] >= 2) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Masz juz^x04 %i^x01 /^x04 2^x01 punktow w tym skillu!", punktygranat[id]);
}
else
{
punkty[id] -= 1;
punktygranat[id] += 1;
ColorChat(id, GREEN, "[CsStrefa]^x01 Dodawanie^x03 1^x01 punktu do^x04 Granatow^x01 zakonczone!");
}
}
menu_destroy(menu_exp_2);
menu_xp_2(id);
Zapisz(id);
return PLUGIN_HANDLED;
}
case 3: {
if(iLvl[id] <= 7) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Aby dodac punkty w^x04 Pistolety^x01 musisz miec^x04 8^x01 level!");
}
else if(punkty[id] == 0) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Nie masz wystarczajacej ilosci punktow!");
}
else
{
if(punktypistolety[id] >= 3) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Masz juz^x04 %i^x01 /^x04 3^x01 punktow w tym skillu!", punktypistolety[id]);
}
else
{
punkty[id] -= 1;
punktypistolety[id] += 1;
ColorChat(id, GREEN, "[CsStrefa]^x01 Dodawanie^x03 1^x01 punktu do^x04 Pistoletow^x01 zakonczone!");
}
}
menu_destroy(menu_exp_2);
menu_xp_2(id);
Zapisz(id);
return PLUGIN_HANDLED;
}
case 4: {
if(iLvl[id] <= 10) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Aby dodac punkty w^x04 Karabiny^x01 musisz miec^x04 11^x01 level!");
}
else if(punkty[id] == 0) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Nie masz wystarczajacej ilosci punktow!");
}
else
{
if(punktykarabiny[id] >= 3) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Masz juz^x04 %i^x01 /^x04 3^x01 punktow w tym skillu!", punktykarabiny[id]);
}
else
{
punkty[id] -= 1;
punktykarabiny[id] += 1;
ColorChat(id, GREEN, "[CsStrefa]^x01 Dodawanie^x03 1^x01 punktu do^x04 Karabinow^x01 zakonczone!");
}
}
menu_destroy(menu_exp_2);
menu_xp_2(id);
Zapisz(id);
return PLUGIN_HANDLED;
}
case 5: {
if(iLvl[id] <= 14) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Aby dodac punkty w^x04 Zestaw^x01 musisz miec^x04 15^x01 level!");
}
else if(punkty[id] == 0) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Nie masz wystarczajacej ilosci punktow!");
}
else
{
if(punktyzestaw[id] >= 3) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Masz juz^x04 %i^x01 /^x04 3^x01 punktow w tym skillu!", punktyzestaw[id]);
}
else
{
punkty[id] -= 1;
punktyzestaw[id] += 1;
ColorChat(id, GREEN, "[CsStrefa]^x01 Dodawanie^x03 1^x01 punktu do^x04 Zestawu^x01 zakonczone!");
}
}
menu_destroy(menu_exp_2);
menu_xp_2(id);
Zapisz(id);
return PLUGIN_HANDLED;
}
case 6: {
if(iLvl[id] <= 14) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Aby dodac punkty w^x04 Podwojny skok^x01 musisz miec^x04 15^x01 level!");
}
else if(punkty[id] <= 0) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Nie masz wystarczajacej ilosci punktow!");
}
else if(skille[id] >= 2) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Mozesz miec maksymalnie^x04 2^x01 skille!");
}
else
{
if(punktymoc1[id] >= 15) {
ColorChat(id, GREEN, "[CsStrefa]^x01 Masz juz^x04 %i^x01 /^x04 15^x01 punktow w tym skillu!", punktymoc4[id]);
}
else
{
punkty[id] -= 1;
punktymoc4[id] += 1;
skille[id] += 1;
ColorChat(id, GREEN, "[CsStrefa]^x01 Dodawanie^x03 1^x01 punktu do^x04 Podwojnego skoku^x01 zakonczone!");
}
menu_destroy(menu_exp_2);
menu_xp_2(id);
Zapisz(id);
return PLUGIN_HANDLED;
}
case 7: {
menu_xp(id);
menu_destroy(menu_exp_2);
}
}
return PLUGIN_CONTINUE;
} |