Signup Now
Page 7 of 14 FirstFirst ... 56789 ... LastLast
Results 61 to 70 of 131

Thread: Kill Counter

  1. #61
    Free User ash katchup's Avatar
    Join Date
    Dec 2013
    Location
    Brazil
    Posts
    144
    Reputation
    15
    Rep Power
    24
    Quote Originally Posted by obscureterror View Post
    =((((

    same no work, they dont go to the correct label =(
    Post a screenshot of your waypoints.

  2. #62
    Free User
    Join Date
    Jan 2015
    Posts
    13
    Reputation
    10
    Rep Power
    0
    Quote Originally Posted by ash katchup View Post
    Post a screenshot of your waypoints.
    Captura de tela 2015-02-21 07.04.15.jpg
    Captura de tela 2015-02-21 07.05.58.jpg

  3. #63
    Free User ash katchup's Avatar
    Join Date
    Dec 2013
    Location
    Brazil
    Posts
    144
    Reputation
    15
    Rep Power
    24
    The function gotolabel has the following params:

    gotolabel ( string  labelname ,  optional string  waypointsection)


    So, you should use it as:

    gotolabel('indo', 'Task')

  4. #64
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,437
    Reputation
    309
    Rep Power
    31
    Quote Originally Posted by ash katchup View Post
    That is why you're a Mod and i'm a humble user.
    Sorry, I didn't mean to be offensive.

  5. #65
    Free User ash katchup's Avatar
    Join Date
    Dec 2013
    Location
    Brazil
    Posts
    144
    Reputation
    15
    Rep Power
    24
    Quote Originally Posted by Raphael View Post
    Sorry, I didn't mean to be offensive.
    You weren't. I'm just saying that you know functions that i don't and i recognize your knowledge.

  6. #66
    Free User
    Join Date
    Apr 2014
    Posts
    24
    Reputation
    10
    Rep Power
    0
    What i need to make this work?, i added this action to scripter / persistent:
    init start
    -- local SCRIPT_VERSION = '1.1.1'

    -- If set to true, will save kill count to $chardb so that it is persisted
    -- throughout different sessions.
    local saveToDB = true

    -- DO NOT EDIT BELOW THIS LINE --

    -- We don't want to override the object because that'd delete all data in
    -- killCount.creatures
    if killCount == nil then
    killCount = {
    creatures = {},
    lastRan = $timems
    }

    killCount.set = function(count, ...)
    local names = table.each({...}, string.lower)

    for _, v in ipairs(names) do
    killCount.creatures[v] = count

    if killCount.saveToDB then
    $chardb:setvalue('killCount', v, count)
    end
    end
    end

    killCount.add = function(addAmount, ...)
    local names = table.each({...}, string.lower)

    for _, v in ipairs(names) do
    killCount.set(killCount.get(v) + addAmount, v)
    end
    end

    killCount.reset = function(...)
    killCount.set(0, ...)
    end

    killCount.get = function(...)
    local names = table.each({...}, string.lower)

    local count = 0
    for _, v in ipairs(names) do
    local cCount = killCount.creatures[v]

    if cCount == nil then
    cCount = 0
    killCount.set(cCount, v)
    end

    count = count + cCount
    end

    return count
    end

    if saveToDB then
    -- Thanks to [MENTION=1]Lucas Terra[/MENTION] for implementing database iterators for the
    -- sole purpose of making this script better. Lucas, you rock!
    foreach $chardb:sectionvalue v 'killCount' do
    killCount.set(v.value, v.name)
    end
    end
    end

    -- We only set saveToDB now because else it would cause unnecessary updates
    -- queried to the database when we first read it.
    killCount.saveToDB = saveToDB
    init end

    auto(100)
    foreach newmessage m do
    if m.type == MSG_INFO then
    local creature = m.content:match(REGEX_LOOT)

    if creature then
    killCount.add(1, creature)
    end
    end
    end

    -- You're welcome, Leonardo
    killCount.lastRan = $timems


    And added this action to leave from respawn to city:


    if killCount.get('Hydra') >= 650 then
    gotolabel("Leave", 'BackToCity')
    end


    And this to reset hydras after killing the boss, but didn't work, what am i missing? do i need to add something else?:

    npctalk('hi', 'task', 'task', 'hydra', 'yes')
    killCount.reset('Hydra')
    Last edited by krokzie; 03-09-2015 at 09:08 AM.

  7. #67
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,437
    Reputation
    309
    Rep Power
    31
    Quote Originally Posted by krokzie View Post
    What i need to make this work?, i added this action to scripter / persistent:
    ...


    And added this action to leave from respawn to city:


    if killCount.get('Hydra') >= 650 then
    gotolabel("Leave", 'BackToCity')
    end


    And this to reset hydras after killing the boss, but didn't work, what am i missing? do i need to add something else?:

    npctalk('hi', 'task', 'task', 'hydra', 'yes')
    killCount.reset('Hydra')


    Could you be a little more specific about what didn't work?

  8. #68
    Free User
    Join Date
    Apr 2014
    Posts
    24
    Reputation
    10
    Rep Power
    0
    Quote Originally Posted by Raphael View Post
    Could you be a little more specific about what didn't work?
    Well i added this action at an "x" waypoint at my hunt waypoints and the char didn't leaved the cave, also when i was at dp before going to resp i added the action again as a checker to go to grizzly adams in case it needs to, and didn't work, my char had 680 hydras killed and didn't get the action i mean he didn't go to grizzly adams because it didn't recognized the 650 hydras
    if killCount.get('Hydra') >= 650 then
    gotolabel("Leave", 'BackToCity')
    end


    if killCount.get('Hydra') >= 650 then
    gotolabel("Grizzly", 'ToHunt')
    end

  9. #69
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,437
    Reputation
    309
    Rep Power
    31
    Quote Originally Posted by krokzie View Post
    Well i added this action at an "x" waypoint at my hunt waypoints and the char didn't leaved the cave, also when i was at dp before going to resp i added the action again as a checker to go to grizzly adams in case it needs to, and didn't work, my char had 680 hydras killed and didn't get the action i mean he didn't go to grizzly adams because it didn't recognized the 650 hydras
    if killCount.get('Hydra') >= 650 then
    gotolabel("Leave", 'BackToCity')
    end


    if killCount.get('Hydra') >= 650 then
    gotolabel("Grizzly", 'ToHunt')
    end
    You do know it doesn't read your quest log to check the starting amount, right? It assumes it's 0. You have to programmatically set it.

  10. #70
    Free User
    Join Date
    Apr 2014
    Posts
    24
    Reputation
    10
    Rep Power
    0
    Quote Originally Posted by Raphael View Post
    You do know it doesn't read your quest log to check the starting amount, right? It assumes it's 0. You have to programmatically set it.
    And how do i set it?, can u please tell me? , sorry for my ignorance

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •