Re: Andor Trainig Range
Posted: Mon Nov 12, 2012 9:06 pm
I'm still running the exact same scripts with no crashes
*shrug*
*shrug*
Code: Select all
local function one(ID)
print("targeting: "..ID)
local objectList = CObjectList();
objectList:update();
local objSize = objectList:size()
for i = 0,objSize do
printf("List size:"..objSize)
obj = objectList:getObject(i)
if (obj.Id == ID or ID == 106885) and checkclicked(obj.Address) then
player:target(obj)
RoMScript("UseExtraAction(1)")
yrest(25)
player:target(obj)
RoMScript("UseExtraAction(1)")
if ID == 106883 then
yrest(25)
player:target(obj)
RoMScript("UseExtraAction(1)")
end
yrest(100)
end
end
end
Code: Select all
if (obj.Id == ID or ID == 106885) and checkclicked(obj.Address) then
player:target(obj)
RoMScript("UseExtraAction(1)")
yrest(10)
player:target(obj)
RoMScript("UseExtraAction(1)")
if ID == 106883 then
yrest(10)
player:target(obj)
RoMScript("UseExtraAction(1)")
end
yrest(100)
end
this part determines the order things are killed.Tamyra wrote:Edit: Also is there a way to have it cast on each target based on primary importance, or based on target movement speed, like if the object is moving faster towards the line than others? Like killing all the newts first, then the turtles, then the hares then the armored bug?
Code: Select all
one(106882)
one(106882)
one(106881)
one(106883)
one(106884)
Lisa, why are you attacking 106882 twice?lisa wrote:Ok this function just scored 1900 and got to round 13, I just call it when it says go.
It does do some "casts" to turtles that have already dissappeared but it is fast enough to just keep up. There is probably an indicator that the "mob" has already been cast on and is in the process of dissappearing.Code: Select all
function tort() local function one(ID) local objectList = CObjectList(); objectList:update(); local objSize = objectList:size() for i = 0,objSize do obj = objectList:getObject(i) if obj.Id == ID or ID == 106885 then print(obj.Name) player:target(obj) RoMScript("UseExtraAction(1)") yrest(10) player:target(obj) RoMScript("UseExtraAction(1)") if ID == 106883 then yrest(10) player:target(obj) RoMScript("UseExtraAction(1)") end yrest(20) end end end one(106882) one(106882) one(106881) one(106883) one(106884) end
Code: Select all
tortoiseID = 106881;
newtID = 106882;
armoredbugID = 106883;
rabbitID = 106884;
ammunitionturtleID = 106885;
Original code posted had them all listed, just got deleted at some stage I guess.This is why coding standards ask for meaningful names
ah got it... i noticed the one ending in 5 is missing, is that by design?lisa wrote:Because when I set up a WP it would sometimes try to attack before the blue swirly veil would be out of the way, can't kill them while it is active.
It is also a double check to make sure the newts are all dead, if they are all dead when the second "one" is called it literally takes a few milliseconds, so no great waste of time.
Could probably do all of them twice I guess.
Also sometimes it takes a couple of attacks to kill them, I have had it when manually playing I have had to attack the same mob 4 or 5 times before it died.
Original code posted had them all listed, just got deleted at some stage I guess.This is why coding standards ask for meaningful names
Cindy wrote: ah got it... i noticed the one ending in 5 is missing, is that by design?
Code: Select all
if obj.Id == ID or ID == 106885 then
yupZZZZZ wrote:I got 46 points on an alt earlier and got the best reward i have seen. Got 3 certs and 500 rubies....so rewards are definitely random.
Seems very random to me, you could probably score 500 and still get same loot as scoring 4000.lisa wrote:Ok this function easily scores 4000+ and you don't actually get any exciting items, loot seems same as scoring 1800ish.
Code: Select all
<!-- # 2 --><waypoint x="53" z="411" y="963">
repeat
tort()
printf("Updating...\n")
player:update()
buffed = player:getBuff(622402)
local lvl = 1
if (buffed == nil) then
printf(" Not Buffed ?!?!? \n")
lvl = 3555
player:sleep()
else
local lvl = buffed.Level
end
printf("Level: "..lvl.."\n")
yrest(250)
until (not RoMScript("TimeKeeperFrame:IsVisible()")) or (buffed and lvl >= 3123)
print("Event finished, end score was "..lvl)
</waypoint>
Code: Select all
local function one(ID)
print("targeting: "..ID)
local objectList = CObjectList();
objectList:update();
local objSize = objectList:size()
for i = 0,objSize do
--printf("List size:"..objSize)
obj = objectList:getObject(i)
if (obj.Id ~= 0 and obj.Type ~= -1) then
if (obj.Id == ID or ID == 106885) and checkclicked(obj.Address) then
player:target(obj)
printf(obj.Id.." Obj: "..obj.Name.."\n")
yrest(100)
if obj.Attackable then RoMScript("UseExtraAction(1)") end
yrest(100)
player:target(obj)
yrest(100)
if obj.Attackable then RoMScript("UseExtraAction(1)") end
if ID == 106883 then
yrest(100)
player:target(obj)
yrest(100)
if obj.Attackable then RoMScript("UseExtraAction(1)") end
end
yrest(100)
end
end
end
end