Andre
(Junior Member)
**

Registration Date: 09-10-2020
Date of Birth: Not Specified
Local Time: 02-25-2021 at 04:53 AM
Status: Offline

Andre's Forum Info
Joined: 09-10-2020
Last Visit: 02-11-2021, 01:47 PM
Total Posts: 18 (0.11 posts per day | 1.13 percent of total posts)
(Find All Posts)
Total Threads: 9 (0.05 threads per day | 1.62 percent of total threads)
(Find All Threads)
Time Spent Online: 4 Hours, 4 Minutes, 5 Seconds
Members Referred: 0
Total Likes Received: 1 (0.01 per day | 0.23 percent of total 434)
(Find All Threads Liked ForFind All Posts Liked For)
Total Likes Given: 3 (0.02 per day | 0.69 percent of total 434)
(Find All Liked ThreadsFind All Liked Posts)
Reputation: 1 [Details]
  
Andre's Most Liked Post
Post Subject Numbers of Likes
RE: script that following target name 1
Thread Subject Forum Name
script that following target name Requests
Post Message
(09-11-2020, 05:02 PM)Packov Wrote: Hello guys, i have this script:

Code:
local toFollow = "Keisam"
local toFollowPos = {}

local followMacro = macro(20, "follow Keisam", function()
local target = getCreatureByName(toFollow)
  if target then
    local tpos = target:getPosition()
    toFollowPos[tpos.z] = tpos
  end
  if player:isWalking() then return end
  local p = toFollowPos[posz()]
  if not p then return end
  if autoWalk(p, 20, {ignoreNonPathable=true, precision=1}) then
    delay(100)
  end
end)

onCreaturePositionChange(function(creature, oldPos, newPos)
  if creature:getName() == toFollow then
    toFollowPos[newPos.z] = newPos
  end
end)


and i would like to add an option that i can add the player name from the client it self, something like this : 

Code:
addTextEdit("ExetaText", storage.ExetaText or "Exeta mas res", function(widget, text)

but for following a player..
thanks alot !
macro(50, "Follow Friend", function()
if g_game.isFollowing() then
return
end
local getFollowCreature = getCreatureByName(storage.followFriend)
if getFollowCreature then
g_game.follow(getFollowCreature)
end
end)

addLabel("leadertext", "Follow :")
addTextEdit("followfriend", storage.followFriend or "Player", function(widget, text)
storage.followFriend = text
end)