Thank you again. My goal for this script is to automate the farming of the merits. The reason for this is that I have noticed that a number of small guilds that siege, about 0-5 players, routinely use alt-characters for farming. Also this seem to be a area not covered, so I could contribute something to a community that has saved me $1,000 in carpel tunnel treatments;-)
so indeed, the script must be able to trade with anyone who asks, mutable times in a row, while farming merits. It also must only select the merits.
Anywho, this is the script as it stands after last night.
Code: Select all
<?xml version="1.0" encoding="utf-8"?><waypoints>
<onLoad>
changeProfileOption("ANTI_KS", false)
changeProfileOption("PATH_TYPE", "wander")
changeProfileOption("WANDER_RADIUS", 0)
changeProfileOption("AUTO_TARGET", false)
changeProfileOption("USE_SLEEP_AFTER_RESUME", true)
while (true) do
yrest(2000)
RecipientName = RoMScript("GetTradeRecipientName();") --checks to see if anyone wants to trade with us
if RecipientName == nil then
elseif RecipientName == "" then
else
RoMScript("AgreeTrade();") --agree to trade
yrest(500)
RoMScript("PickupBagItem("..inventory.BagSlot[61].BagId..");") --pickup item in bag slot 1
yrest(500)
RoMScript("ClickTradeItem(1);") --place item in tradeing slot 1
yrest(800)
RoMScript("AcceptTrade('..RecipientName..');") --click the ok buttion
yrest(500)
while RoMScript("GetTradeRecipientName();") ~= "" do
RoMScript("AcceptTrade('..RecipientName..');") --loops clicking the trade buttion untill the trade is completed
yrest(500)
end
yrest(5000)
keyboardPress(key.VK_ESCAPE); --clears the screen of the so and so wants to trade window
end
end
</onLoad>
</waypoints>
I will implement your suggestion for the next version Rock5, thank you. Also I need to add a check to see if the merits are in slot one or two. What happens if you trade while collecting the merits, the ones being traded, still reserve the slot in the back pack when you pick them up, so the newly collected merits go to the next available slot. so I’m thinking I’ll set it up to see if there is anything in slot one or two and trade that, and if nothing is in either slot to cancel the trade.