Spam
Moderators: Murderator+, Murderator
Spam
Hey
I need help with creat scripts for spam two spell.
Fireball
Magic Arrow
Fireball
...
...
loop.
I use this sub for Fireball and arrow.
sub Fireball()
if not uo.waiting() then
UO.exec("cast 'Fireball' lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
UO.exec("cast 'Fireball' ")
UO.DeleteJournal()
end if
end sub
sub Arrow()
if not uo.waiting() then
UO.exec("cast 'Magic Arrow' lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
UO.exec("cast 'Magic Arrow' ")
UO.DeleteJournal()
end if
end sub
I need to Connect this two scripts with one. To spam one time Sub Fireball and one time Sub Arrow, or creat new scripts what will be use Sub fireball and sub arrow.
I need help with creat scripts for spam two spell.
Fireball
Magic Arrow
Fireball
...
...
loop.
I use this sub for Fireball and arrow.
sub Fireball()
if not uo.waiting() then
UO.exec("cast 'Fireball' lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
UO.exec("cast 'Fireball' ")
UO.DeleteJournal()
end if
end sub
sub Arrow()
if not uo.waiting() then
UO.exec("cast 'Magic Arrow' lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
UO.exec("cast 'Magic Arrow' ")
UO.DeleteJournal()
end if
end sub
I need to Connect this two scripts with one. To spam one time Sub Fireball and one time Sub Arrow, or creat new scripts what will be use Sub fireball and sub arrow.
Re: Spam
If I understand correctly then something like this:
Code: Select all
sub loop()
repeat
Fireball()
wait(500)
Arrow()
wait(500)
until uo.dead()
endsub
Re: Spam
almost like this but without repeat.
Scripts shuold work like this.
When i press one time sub loop()
scripts should cast
Fireball
when I press second time
scripts should cast
Magic Arrow
Not like now when i press sub loop()
scripts cast fireball and arrow.
Scripts should works like this from easyuo.
set %gowienko 0
mainLoop:
onHotKey a
gosub czary
goto mainLoop
sub czary
if %gowienko = 0
{
event macro 15 17
wait 15
set %gowienko 1
return
}
event macro 15 4
wait 5
set %gowienko 0
return
When i press key a
Scripts spam all the time one time fireball and one time arrow.
one push a cast fireball second time push a arrow when i hold key scripts cast loop fireball arrow fireball arrow.
Scripts shuold work like this.
When i press one time sub loop()
scripts should cast
Fireball
when I press second time
scripts should cast
Magic Arrow
Not like now when i press sub loop()
scripts cast fireball and arrow.
Scripts should works like this from easyuo.
set %gowienko 0
mainLoop:
onHotKey a
gosub czary
goto mainLoop
sub czary
if %gowienko = 0
{
event macro 15 17
wait 15
set %gowienko 1
return
}
event macro 15 4
wait 5
set %gowienko 0
return
When i press key a
Scripts spam all the time one time fireball and one time arrow.
one push a cast fireball second time push a arrow when i hold key scripts cast loop fireball arrow fireball arrow.
Re: Spam
Code: Select all
sub lighter()
if uo.getglobal('lighter') == 'arrow' then
uo.setglobal('lighter', 'ball')
Arrow()
else
uo.setglobal('lighter', 'arrow')
Fireball()
endif
endsub
Re: Spam
Staszek wrote:almost perfect, some time scripts spam 3xfireball or arrow, can fix it ?
when you press hotkey once, your character will casts fireball three times?
Re: Spam
It is not necessary to hold the button of the clamped. 

Re: Spam
It necessary becouse.
sub Arrow()
if not uo.waiting() then
UO.exec("cast 'Magic Arrow' lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
UO.exec("cast 'Magic Arrow' ")
UO.DeleteJournal()
end if
end sub
I use this scripts for spell and i can hold key and I can spam Arrow with max speed and without fizzzle.


ImageShack.us
Like in screen, I try to do the same with arrow fireball.
the scripts works almost perfect but when i push faster key it cast 2x the same spell.
I need to hold key i cast with max speed.
sub Arrow()
if not uo.waiting() then
UO.exec("cast 'Magic Arrow' lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
UO.exec("cast 'Magic Arrow' ")
UO.DeleteJournal()
end if
end sub
I use this scripts for spell and i can hold key and I can spam Arrow with max speed and without fizzzle.


ImageShack.us
Like in screen, I try to do the same with arrow fireball.
the scripts works almost perfect but when i push faster key it cast 2x the same spell.
I need to hold key i cast with max speed.
Re: Spam
Code: Select all
sub lighter()
if not uo.waiting() then
if uo.getglobal('lighter') <> 'Fireball' then
uo.setglobal('lighter', 'Fireball')
else
uo.setglobal('lighter', 'Magic Arrow')
endif
UO.exec("cast " + uo.getglobal('lighter') + " lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
if uo.getglobal('lighter') <> 'Fireball' then
uo.setglobal('lighter', 'Fireball')
else
uo.setglobal('lighter', 'Magic Arrow')
endif
UO.exec("cast " + uo.getglobal('lighter'))
UO.DeleteJournal()
end if
end sub
Last edited by ZeroDX on 2012-07-22 17:23:37, edited 1 time in total.
Re: Spam
previous post updated
Re: Spam
try this
Code: Select all
sub lighter()
if not uo.waiting() then
if uo.getglobal('lighter') <> 'Fireball' then
uo.setglobal('lighter', 'Fireball')
else
uo.setglobal('lighter', "'Magic Arrow'")
endif
UO.exec("cast " + uo.getglobal('lighter') + " lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
if uo.getglobal('lighter') <> 'Fireball' then
uo.setglobal('lighter', 'Fireball')
else
uo.setglobal('lighter', "'Magic Arrow'")
endif
UO.exec("cast " + uo.getglobal('lighter'))
UO.DeleteJournal()
end if
end sub
-
- Posts: 820
- Joined: 2011-06-11 19:54:23
Re: Spam
ZeroDX wrote:try thisCode: Select all
sub lighter()
if not uo.waiting() then
if uo.getglobal('lighter') <> 'Fireball' then
uo.setglobal('lighter', 'Fireball')
else
uo.setglobal('lighter', "'Magic Arrow'")
endif
UO.exec("cast " + uo.getglobal('lighter') + " lasttarget")
end if
if (UO.InJournal('cliloc# 0xA3A1') or UO.InJournal('cliloc# 0xAB74')) then
if uo.getglobal('lighter') <> 'Fireball' then
uo.setglobal('lighter', 'Fireball')
else
uo.setglobal('lighter', "'Magic Arrow'")
endif
UO.exec("cast " + uo.getglobal('lighter'))
UO.DeleteJournal()
end if
end sub
А если lasttarget заменить на laststatus?
Code: Select all
UO.exec("cast " + uo.getglobal('lighter') + " laststatus")
Re: Spam
Juicy Fruit wrote:А если lasttarget заменить на laststatus?Code: Select all
UO.exec("cast " + uo.getglobal('lighter') + " laststatus")
Там была проблемма с пробелом в названии спелла. Из-за этого вместо ласттаргет инжа воспринимала Arrow как объект.
Staszek wrote:And second think its possible to add, a repeat spell what was interrupted ??
How will be "the spell fizzles' in cliloc?
Re: Spam
you need to:
1) start cast.
2) interrupt cast
3) do ,showjournal
last string in journal will be the latest in opened text window
1) start cast.
2) interrupt cast
3) do ,showjournal
last string in journal will be the latest in opened text window