Attempt to perform an Arithmetic on Global
Posted: Tue Nov 16, 2010 7:26 am
Hi, Im begining scripting with MicroMacro and i have a mistake that i can't solve.
This is the extraction of the code.
The error i got its attempt to perform an Arithmetic on Global HPCurrent a nil value. I see the Hp Current and HP max results correctly.
Anyone can tell me a clue?
Thanks in advance.
This is the extraction of the code.
Code: Select all
HPPercent = 75;
HPCurrent = memoryReadInt( MyProcess, HPCurrentAddress);
HPMax = memoryReadInt( MyProcess, HPMaxAddress);
printf("Found HP Current [%d] \n", HPCurrent);
printf("Found HP Max [%d] \n", HPMax);
if( HPPercent > ((HpCurrent*100)/HPMax) ) then
keyboardPress(key.VK_8);
end
Anyone can tell me a clue?
Thanks in advance.