Auto follow player
This script uses game-client's follow (green square) when there are no monsters from specific list on screen and not targeting anything.
This script walks by iself, not using follow (green square), trying to keep at least X sqms when there are no monsters from specific list on screen and not targeting anything.
This script uses game-client's follow (green square) when there are no monsters from specific list on screen and not targeting anything.
But also walks by iself, not using follow (green square), trying to keep at least X sqms when THERE ARE monsters from specific list on screen OR targeting anything.
That means: If no monsters = follow using game-client (green square); If there monsters, walk by itself sqm by sqm.
This script uses game-client's follow (green square) when there are no monsters from specific list on screen and not targeting anything.
local Player = 'Player name'
local Monsters = { 'Demon', 'Demon Skeleton', 'Ghoul' }
if maround(0, table.unpack(Monsters)) == 0 and target().id == 0 then
local follow_creature = followed()
if (follow_creature.id == 0 or (follow_creature.id > 0 and follow_creature.name:lower() ~= Player:lower())) and paround(0, Player) > 0 then
follow(Player)
wait(1000)
end
endThis script walks by iself, not using follow (green square), trying to keep at least X sqms when there are no monsters from specific list on screen and not targeting anything.
local Player = 'Player name'
local PlayerDistance = 3 -- Distance to stay away from player.
local Monsters = { 'Demon', 'Demon Skeleton', 'Ghoul' }
local monsters_around = maroundreachable(0, table.unpack(Monsters))
if monsters_around == 0 and target().id == 0 then
local creature = getcreature(Player)
if creature.id > 0 and creature.dist > PlayerDistance then
reachcreature(Player, PlayerDistance)
end
endThis script uses game-client's follow (green square) when there are no monsters from specific list on screen and not targeting anything.
But also walks by iself, not using follow (green square), trying to keep at least X sqms when THERE ARE monsters from specific list on screen OR targeting anything.
That means: If no monsters = follow using game-client (green square); If there monsters, walk by itself sqm by sqm.
local Player = 'Player name'
local Monsters = { 'Demon', 'Demon Skeleton', 'Ghoul' }
if maround(0, table.unpack(Monsters)) == 0 and target().id == 0 then
local follow_creature = followed()
if (follow_creature.id == 0 or (follow_creature.id > 0 and follow_creature.name:lower() ~= Player:lower())) and paround(0, Player) > 0 then
follow(Player)
wait(1000)
end
else
local creature = getcreature(Player)
if creature.id > 0 and creature.dist > PlayerDistance then
reachcreature(Player, PlayerDistance)
end
end
