Log in

View Full Version : Break Furniture?



texmex47
12-21-2015, 04:30 AM
Anyone got a break furniture script? People keep blocking off my way sometimes with plants, and troughs, and such.

Need a script that uses my weapon on them.

Also, is it possible to do that with browse field? Cus sometimes they trash the blocking items.
Need a script that browse fields, and breaks the blocking item.

Couldn't find any script for this. I google'd but threads are from 2012 and shit.
It's built in to windbot, idk if xenobot has a such feature tho

xto94
12-21-2015, 09:47 AM
-- Anti-Furniture Trap-- Made by Eion, Credits to FLPSAN for the original
local weaponId = 3297 -- Weapon ID to use to break furniture
local FURNITUREid = {2025, 2029, 2030, 2043, 2044, 2045, 2046, 2047, 2048, 2059, 2060, 2061, 2445, 2446, 2447, 2448, 2449, 2450, 2451, 2452, 2453, 2454, 2465, 2466, 2467, 2468, 2524, 2904, 2959, 2960, 2961, 2962, 2963, 2964, 2975, 2976, 2979, 2982, 2986, 2997, 2998, 2999, 3000, 3484, 3485, 3486, 3487, 3510, 3511, 3512, 3513, 5046, 5055, 5056, 6109, 6110, 6111, 6112, 6367, 6368, 6369, 6370, 7860, 7861, 7862, 7863, 9132, 9141, 10208, 10210, 10211, 10212, 10213, 10214, 10215, 17373}-- Furniture ID's (May need more added)


function hasFurniture(x,y,z)
item = Map.GetTopMoveItem(x,y,z)
if item ~= nil then
return table.contains(FURNITUREid, item.id)
end
return false
end
function doBreak(x,y,z)
local n = 0
setWalkerEnabled(false)
repeat
Self.UseItemWithGround(Self.Weapon().id, x, y, z)
wait(500,900)
n = n + 1
until n>=12 or not hasFurniture(x,y,z)
setWalkerEnabled(true)
end
function MapAntiTrap()
local pos = Self.Position()
local posArr = {
{['x']=pos.x-1,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+5,['z']=pos.z}
}
for i,p in ipairs(posArr) do
if hasFurniture(p.x,p.y,p.z) then
doBreak(p.x,p.y,p.z)
if not(hasFurniture(p.x,p.y,p.z)) then
break
end
end
end
end


while true do -- If stand time is higher than 3-5 seconds the bot will attempt to break furniture if any is around and you are not targetting anything.
local pos = Self.Position()
wait(3000, 5000)
if (Self.DistanceFromPosition(pos.x, pos.y, pos.z) == 0) and (Self.TargetID() == 0) then
MapAntiTrap()
end
end

texmex47
12-21-2015, 03:05 PM
-- Anti-Furniture Trap-- Made by Eion, Credits to FLPSAN for the original
local weaponId = 3297 -- Weapon ID to use to break furniture
local FURNITUREid = {2025, 2029, 2030, 2043, 2044, 2045, 2046, 2047, 2048, 2059, 2060, 2061, 2445, 2446, 2447, 2448, 2449, 2450, 2451, 2452, 2453, 2454, 2465, 2466, 2467, 2468, 2524, 2904, 2959, 2960, 2961, 2962, 2963, 2964, 2975, 2976, 2979, 2982, 2986, 2997, 2998, 2999, 3000, 3484, 3485, 3486, 3487, 3510, 3511, 3512, 3513, 5046, 5055, 5056, 6109, 6110, 6111, 6112, 6367, 6368, 6369, 6370, 7860, 7861, 7862, 7863, 9132, 9141, 10208, 10210, 10211, 10212, 10213, 10214, 10215, 17373}-- Furniture ID's (May need more added)


function hasFurniture(x,y,z)
item = Map.GetTopMoveItem(x,y,z)
if item ~= nil then
return table.contains(FURNITUREid, item.id)
end
return false
end
function doBreak(x,y,z)
local n = 0
setWalkerEnabled(false)
repeat
Self.UseItemWithGround(Self.Weapon().id, x, y, z)
wait(500,900)
n = n + 1
until n>=12 or not hasFurniture(x,y,z)
setWalkerEnabled(true)
end
function MapAntiTrap()
local pos = Self.Position()
local posArr = {
{['x']=pos.x-1,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y,['z']=pos.z},
{['x']=pos.x,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-1,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-2,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-3,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-4,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-5,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+1,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+2,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+3,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+4,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+5,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-6,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+6,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-1,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+1,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-2,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+2,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-3,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+3,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-4,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+4,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y-5,['z']=pos.z},
{['x']=pos.x-7,['y']=pos.y+5,['z']=pos.z},
{['x']=pos.x+7,['y']=pos.y+5,['z']=pos.z}
}
for i,p in ipairs(posArr) do
if hasFurniture(p.x,p.y,p.z) then
doBreak(p.x,p.y,p.z)
if not(hasFurniture(p.x,p.y,p.z)) then
break
end
end
end
end


while true do -- If stand time is higher than 3-5 seconds the bot will attempt to break furniture if any is around and you are not targetting anything.
local pos = Self.Position()
wait(3000, 5000)
if (Self.DistanceFromPosition(pos.x, pos.y, pos.z) == 0) and (Self.TargetID() == 0) then
MapAntiTrap()
end
end

Nice!

Any idea if it's possible to add a browse field feature to it, for traps that are trashed?

xto94
12-21-2015, 03:26 PM
texmex47 i don't know how to do it

anoyn
12-21-2015, 04:48 PM
Anyone got a break furniture script? People keep blocking off my way sometimes with plants, and troughs, and such.

Need a script that uses my weapon on them.

Also, is it possible to do that with browse field? Cus sometimes they trash the blocking items.
Need a script that browse fields, and breaks the blocking item.

Couldn't find any script for this. I google'd but threads are from 2012 and shit.
It's built in to windbot, idk if xenobot has a such feature tho

Its not feasible,

If the walker is stuck you would need to check every square on the screen with browse field since xenobot's lua functions only allows us to see the top item.

shadowart
12-21-2015, 05:06 PM
I have a furniture destroyer that checks all squares, that are both reachable and unwalkable, using browse field for hidden furniture.

Edit: Download the script from my thread instead: http://forums.xenobot.net/showthread.php?39301-shAdOwArt-s-Lua-Scripts That way you can make sure to get the latest version.

Disclaimer: This is a bit of a work in progress, it works well in artificial testing but it hasn't seen much real world use while I've been watching it.

texmex47
12-21-2015, 10:10 PM
I have a furniture destroyer that checks all squares, that are both reachable and unwalkable, using browse field for hidden furniture.

Disclaimer: This is a bit of a work in progress, it works well in artificial testing but it hasn't seen much real world use while I've been watching it.


Thanks, I'll try it!
Also, if anyone got time, maybe try convert windbot's anti furniture to xenobot? Was using it before on wb and it worked flawlessly.


function antifurnituretrap(weapon, stand)
weapon = weapon or 'Machete'
stand = (stand or 0) * 1000

if clientitemhotkey(weapon, 'crosshair') == 'not found' and itemcount(weapon) == 0 then
return "AntiFurniture[Issue1]: 'Weapon' given not found on hotkeys and not visible."
end

if $standtime > stand then
local Furniture = {}

for x, y, z in screentiles(ORDER_RADIAL, 7) do
if tilereachable(x, y, z, false) and not LIB_CACHE.antifurniture[ground(x, y, z)] then
local tile = gettile(x, y, z)

for k = tile.itemcount, 1, -1 do
local info = iteminfo(tile.item[k].id)

if info.isunpass and not info.isunmove then
table.insert(Furniture, {x = x, y = y, z = z, id = info.id, top = k == tile.itemcount})
break
end
end
end
end

if #Furniture > 0 then
for _, item in ipairs(Furniture) do
local x, y, z, id, top = item.x, item.y, item.z, item.id, item.top

pausewalking(10000) reachlocation(x, y, z)

foreach newmessage m do
if m.content:match("You are not invited") then
LIB_CACHE.antifurniture[ground(x, y, z)] = true
return "AntiFurniture[Issue4]: Cancelling routine due to an item inside a house. (top item)"
end
end

if top then
while id == topitem(x, y, z).id and tilereachable(x, y, z, false) do
useitemon(weapon, id, ground(x, y, z)) waitping()

foreach newmessage m do
if m.content:match("You are not invited") then
LIB_CACHE.antifurniture[ground(x, y, z)] = true
return "AntiFurniture[Issue4]: Cancelling routine due to an item inside a house. (top item)"
end
end
end
else
browsefield(x, y, z) waitcontainer("browse field", true)
local cont = getcontainer('Browse Field')

for j = 1, cont.lastpage do
for i = 1, cont.itemcount do
local info = iteminfo(cont.item[i].id)

if info.isunpass and not info.isunmove then
while itemcount(cont.item[i].id, 'Browse Field') > 0 and tilereachable(x, y, z, false) do
useitemon(weapon, info.id, "Browse Field") waitping()

foreach newmessage m do
if m.content:match("You are not invited") then
LIB_CACHE.antifurniture[ground(x, y, z)] = true
return "AntiFurniture[Issue3]: Cancelling routine due to an item inside a house. (browsing field)"
end
end
end
end
end

changepage('browse field', math.min(j + 1, cont.lastpage))
end
end

pausewalking(0)
end
else
return "AntiFurniture[Issue5]: Character is standing still without furnitures to break."
end
else
return "AntiFurniture[Issue2]: Current standtime less than the required time."
end

return "AntiFurniture[No Issue]"
end

shadowart
12-21-2015, 10:19 PM
That cannot be converted to xb, xb's lua api only reveals the id of the top item on each square.

viser14
12-22-2015, 01:00 AM
well isn't this fancy

shadowart
12-22-2015, 08:59 AM
I gave my furniture destroyer a new home here (http://forums.xenobot.net/showthread.php?39301-shAdOwArt-s-Lua-Scripts&p=464620#post464620). I also made two huge improvements so if you grabbed the version I posted here I recommend that you redownload.