Mam tak:
public ShowKlasy(id,lx[]) {
new text2[512]
asked_klass[id]=0
format(text2, 511,"\yKlasy Premium - ^n\w1. \yMefisto \wLevel:%i^n\w2. \yDiablo \wLevel:%i^n\w3. Szaman \w Level:%i^n\w4. Kameleon \wLevel:%i^n\w0.Zwykle Klasy^n",player_class_lvl[id][10],player_class_lvl[id][11],player_class_lvl[id][12],player_class_lvl[id][13])
show_menu(id, KeysKlasy,text2, -1, "Klasy")
}
public PressedKlasy(id, key) {
/* Menu:
* Wybierz klase:
* 1:klasa1
* 2:klasa2
* 3:klasa3
* 0:Wstecz
*/
new lx[14]
g_haskit[id] = 1
switch (key) {
case 0:
{ // 1
if( get_user_flags(id) & ADMIN_LEVEL_
player_class[id] = Mefisco
g_haskit[id] = 1
}
case 1:
{ // 2
if( get_user_flags(id) & ADMIN_LEVEL_C)
player_class[id] = Diablo
}
case 2:
{ // 2
player_class[id] = Szaman
}
case 3:
{ // 2
player_class[id] = Kameleon
}
case 9:
{ // 0
select_class(id,lx)
}
}
LoadXP(id, player_class[id])
CurWeapon(id)
give_knife(id)
return PLUGIN_HANDLED
}
/* ==================================================================================================== */
public check_class()
{
for (new id=0; id < 33; id++)
{
if((player_class[id] == Ninja) && (is_user_connected(id)))
{
if (is_user_alive(id)) set_user_armor(id,100)
}
set_gravitychange(id)
set_renderchange(id)
}
}
/* ==================================================================================================== */
public add_barbarian_bonus(id)
{
if (player_class[id] == Barbarzynca || player_class[id] == Diablo)
{
change_health(id,20,0,"")
}
}
/* ==================================================================================================== */
public add_bonus_necromancer(attacker_id,id)
{
if (player_class[attacker_id] == Nekromanta || player_class[attacker_id] == Mefisco)
{
if (get_user_health(id) - 10 <= 0)
{
set_user_health(id,random_num(1,3))
}
else
{
new dmg = random_num(6,12)
change_health(id,-dmg,0,"")
change_health(attacker_id,1,0,"")
}
}
}
i jak chce skomplikować wyskakuje mi:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright © 1997-2006 ITB CompuPhase, AMX Mod X Team
Warning: Loose indentation on line 1704
Warning: Loose indentation on line 1708
Warning: Nested comment on line 1868
Warning: Loose indentation on line 4661
Warning: Loose indentation on line 4664
Error: Array index out of bounds (variable "player_class_lvl") on line 4944
Warning: Loose indentation on line 4965
1 Error.
Could not locate output file C:\Users\Eryk\Desktop\dbmod_5.9l.amx (compile failed).
Użytkownik Pavulon edytował ten post 22.05.2010 21:59
skomplikować to sobie możesz życie