Page 1 of 1

Autoheal %mode: Unheandled Ex. in parser error...help me!

Posted: 2004-10-31 16:19:22
by Predator di Khars
i need to place a var that represents my HP in percentage...and i script this:

Sub Autobandage()
VAR hp = Uo.GetHP("self") * 100 / Uo.GetMaxHP("self")
If hp < 100 then
Uo.exec('waittargetself')
Uo.exec('usetype 0x0E21')
Wait(200)
Uo.Setglobal("inbandage","ON")
wait_bandage()
End If
End Sub

If i try to run this macro the error appairs: Unheandled exeption in parser or sometthing like that...i don't remember the words exactly...

i tried also to change this line:

VAR hp = Uo.GetHP("self") * 100 / Uo.GetMaxHP("self")
into
VAR hp = (Uo.GetHP("self") * 100) / Uo.GetMaxHP("self")

but it still doesn't work...

i tried to change in this way:
VAR hp = 0
hp = Uo.GetHP("self") * 100 / Uo.GetMaxHP("self")

but it still doesn't work...


HELP ME :P and like ever sorry for my stupid italian/structured english :D

Posted: 2004-11-01 15:35:24
by drcrazy
Insert a delay betwen heal loops..

Posted: 2004-11-02 14:12:55
by AlexeyVorotnikov
Try this:

Code: Select all

VAR chp = Uo.GetHP("self")
VAR mhp = Uo.GetMaxHP("self")
VAR hp = chp / mhp * 100

Posted: 2004-11-02 18:41:09
by Predator di Khars
drcrazy wrote:Insert a delay betwen heal loops..


do u see "wait_bandage()" ? :)
in that sub there are many features that wait the right healing time :)

tnx for the answers, i get it ^_^

Posted: 2004-11-02 23:19:13
by drcrazy
so. I saw call of the sub.. but haven't saw the sub.. ;)