View Single Post
Old 08.02.2006, 01:50   #1
Kirikups
Архивный участник
 
Join Date: Oct 2005
Posts: 175
Default AI and level controls

Hello,

i have a little problem compiling a part of a code:

Code:
class MyClass : ParentClass
{
parameter:
	float MyVar = 50;


handler:
	EventHandler SPELLED(speller, skill_name_id) 
	{ 
		if ((myself.sm.level / speller.level) < 1) {
			MyVar = MyVar * (myself.sm.level / speller.level);
		}
	
	}			
}
i get an error on the line:

Code:
MyVar = MyVar * (myself.sm.level / speller.level);
wtf, i want to decrease MyVar is PC is higher level than NPC... Impossible ?? Ty for any help
Kirikups is offline