Results 1 to 6 of 6

Thread: Toardz Hud arrows used.

  1. #1
    Normal User
    Join Date
    Sep 2012
    Posts
    131
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    18
    Rep Power
    5

    Toardz Hud arrows used.

    I need to get Toadz HUD counting arrows used as "waste" but i cant figure out how to do that.
    I know how to get it to count mana pots but arrows seems to be differant.

    How do i get this to count arrows/bolts aswell?

    I dont know how to edit this properly;
    -- [[ Supplies Wasted ]]
    local showSuppliesWasted = true
    local suppliesitems = {'Strong mana potion'}
    local suppsvalue = {80}


    Code:
    -- [[ General Info HUD by RevoltZ v0.3 ]] 
    
    -- [[ Settings ]] 
    local RaphaelLibrary = false 
    
    -- [[ General and Botting Status by PV! ]] 
    local showGeneral = false 
    local showBotting = true 
    
    -- [[ Position ]] 
    local showPosition = false 
    
    -- [[ Supplies Counter ]] 
    local showSupplies = false
    local item1 = {name = "Strong Mana Potion", buy = 1200, min = 100} 
    local item2 = {name = "Onyx Arrow", buy = 1400, min = 100} 
    local item3 = {name = "Assassin Star", buy = 50, min = 0} 
    local items = {item1, item2, item3} 
    
    -- [[ Supplies Wasted ]] 
    local showSuppliesWasted = true 
    local suppliesitems = {'Strong mana potion'}
    local suppsvalue = {80} 
    
    -- [[ Items looted ]] 
    local showLoots = true 
    local lootitems = {"Gold Coin", "Platinum coin", "Bony Tail", "Bonebeast Trophy", "Bat Wing", "Mutated Bat Ear", "Black Pearl", "Small Amethyst", "Mercenary Sword", "Batwing Hat", "Hair of a Banshee", "Petrified Scream", "White Pearl", "Stone Skin Amulet", "Blue Robe", "Terra Mantle", "Red Robe", "Sweet Smelling Bait", "Piece of Dead Brain", "Bonelord Eye", "Haunted Blade", "Bonelord Helmet", "Bonelord Shield", "Spiked Squelcher", "Spider Silk", "Knight Legs", "Knight Armor", "Platinum Amulet", "Lightning Headband", "Small Topaz", "Small Emerald", "Yellow Gem", "Castle Shield", "Lightning Boots", "Maxilla Maximus"}
    local lootsvalue = {"1", "100", "210", "6000", "50", "420", "280", "200", "12000", "8000", "350", "250", "160", "1000", "10000", "11000", "25000", "200000", "420", "5000", "8000", "7500", "1200", "5000", "3000", "5000", "5000", "2500", "2500", "200", "250", "6000", "1000", "5000", "2500", "200000"}
    
    local myname = true -- DO NOT DISABLE, make your char stop healing :P 
    
    local fontsize = 10 
    local fontspacing = fontsize+2 
    
    -- [[ ENGINE ]] -- do not change it below 
    
    local cont = 0 
    local x = 5 
    local y = 0 
    local z = 0 
    local totals = 0 
    local totall = 0 
    local total = 0 
    local sub = 17 
    
    -- [[ General ]] 
    
    if clientwin.x ~= nil or clientwin.y ~= nil then 
    setposition(clientwin.x+5, clientwin.y+20) 
    else 
    setposition(5, 20) 
    end 
    setfontstyle("Tahoma", fontsize, "white") 
    if showGeneral then 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("yellow") 
    y = y + 10 
    addtext(' [ General ]', 5, y)  
    setfontcolor("white") 
    y = y + 10 
    addtext('-----------------------------------------', 0, y)  
    setfontcolor("white") 
    y = y + 10 
    addtext('Level', x, y) 
    addtext('- '..level, 120, 30) 
    y = y + 15 
    addtext('Experience', x, y) 
    addtext('- '..exp, 120, y) 
    y = y + 15 
    addtext('Health', x, y) 
    if hppc < 25 then 
    setfontcolor("red") 
    else if hppc < 50 then 
    setfontcolor("yellow") 
    else 
    setfontcolor("white") 
    end 
    end 
    addtext('- '..hp..' ('..hppc..'%)', 120, y) 
    y = y + 15 
    setfontcolor("white") 
    addtext('Mana', x, y) 
    if mppc < 25 then 
    setfontcolor("red") 
    else if mppc < 50 then 
    setfontcolor("yellow") 
    else 
    setfontcolor("white") 
    end 
    end 
    addtext('- '..mp..' ('..mppc..'%)', 120, y) 
    y = y + 15 
    setfontcolor("white") 
    addtext('Magic Level', x, y)  
    addtext('- '..mlevel..' ('..100-mlevelpc.. '%)', 120, y) 
    y = y + 10  
    end 
    
    -- [[ Botting ]] 
    
    if showBotting then 
    setfontcolor("white")  
    addtext('-----------------------------------------', 0, y)  
    setfontcolor("yellow") 
    y = y + 10 
    addtext(' [ Botting ]', 15, y)  
    setfontcolor("white")  
    y = y + 10 
    addtext('-----------------------------------------', 0, y)  
    setfontcolor("white")  
    y = y + 10 
    addtext('Exp Per Hour', x, y) 
    addtext('- ' .. exphour, 120, y)  
    y = y + 15 
    addtext('Exp Left', x, y) 
    addtext('- ' .. exptolevel(), 120, y)  
    y = y + 15 
    addtext('Exp Gained', x, y) 
    addtext('- ' .. expgained, 120, y) 
    y = y + 15 
    addtext('Time To Next Level', x, y) 
    addtext('- ' .. timetolevel, 120, y) 
    y = y + 15 
    addtext('Stamina', x, y) 
    addtext('- ', 120, y)  
    if stamina >= 2400 then 
    setfontcolor("green")  
    else if stamina < 2400 and (stamina > 840) then 
    setfontcolor("orange") 
    else if stamina <= 840 then 
    setfontcolor("red") 
    end 
    end 
    end 
    if RaphaelLibrary then 
    addtext(time(stamina), 130, y) 
    else 
    addtext(stamina, 130, y) 
    end  
    y = y + 15 
    setfontcolor("white") 
    addtext('Time Played', x, y) 
    addtext('- ' .. timehunt, 120, y) 
    y = y + 15 
    addtext('Cavebot', x, y) 
    addtext('- ', 120, y) 
    if cavebot then 
    setfontcolor("green") 
    addtext('ON', 130, y) 
    else 
    setfontcolor("red") 
    addtext('OFF', 130, y) 
    end 
    y = y + 15 
    setfontcolor("white") 
    addtext('- ', 120, y) 
    addtext('Targeting', x, y) 
    if targeting then 
    setfontcolor("green") 
    addtext('ON', 130, y) 
    else 
    setfontcolor("red") 
    addtext('OFF', 130, y) 
    end  
    y = y + 15 
    setfontcolor("white") 
    addtext('Looting', x, y) 
    addtext('- ', 120, y) 
    if looting then 
    setfontcolor("green") 
    addtext('ON', 130, y)  
    else  
    setfontcolor("red") 
    addtext('OFF', 130, y)  
    end 
    y = y + 15 
    setfontcolor("white") 
    addtext('Walk Through', x, y) 
    addtext('- ', 120, y) 
    if getsettings("Settings/CaveBot/Pathfinding/WalkThroughPlayers") == 'yes' then 
    setfontcolor("green") 
    addtext('ON', 130, y)  
    elseif getsettings("Settings/CaveBot/Pathfinding/WalkThroughPlayers") == 'no' then 
    setfontcolor("red") 
    addtext('OFF', 130, y) 
    else 
    setfontcolor("yellow") 
    addtext('???', 130, y) 
    end 
    y = y + 15 
    setfontcolor("white") 
    addtext('Balance', x, y) 
    addtext('- ', 120, y) 
    if balance == -1 then 
    addtext('?', 130, y) 
    else 
    addtext(balance, 130, y) 
    end 
    y = y + 10 
    end 
    
    -- [[ Position ]] 
    
    if showPosition then 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("yellow") 
    y = y + 10 
    addtext(' [ Position ]', 15, y) 
    y = y + 10 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("white") 
    y = y + 10 
    addtext("Position X ", x, y) 
    addtext("- "..posx, 120, y) 
    y = y + 15 
    addtext("Position Y ", x, y) 
    addtext("- "..posy, 120, y) 
    y = y + 15 
    addtext("Position Z ", x, y) 
    addtext("- "..posz, 120, y) 
    y = y + 15 
    addtext("Cursor ID", x, y) 
    addtext('- '..cursorinfo().id, 120, y) 
    y = y + 10 
    end 
    
    -- [[ Supplies ]] 
    
    if showSupplies then 
    setfontcolor("white")  
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("yellow") 
    y = y + 10 
    addtext(' [ Supplies ]', 15, y) 
    y = y + 10 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("white") 
    y = y + 10 
    for i, j in pairs(items) do 
    if itemid(items[i].name) == ammo then 
    cont = itemcount(items[i].name) + ammoamount 
    elseif itemid(items[i].name) == weapon then 
    cont = itemcount(items[i].name) + weaponamount 
    else 
    cont = itemcount(items[i].name) 
    end 
    addtext(items[i].name, x, y) 
    addtext('-', 120, y) 
    if cont <= items[i].min then 
    setfontcolor("red") 
    elseif cont <= (items[i].buy/2) then 
    setfontcolor("yellow") 
    elseif cont < items[i].buy then 
    setfontcolor("white") 
    else 
    setfontcolor("green") 
    end 
    if itemid(items[i].name) == ammo then 
    addtext(cont, 130, y) 
    elseif itemid(items[i].name) == weapon then 
    addtext(cont, 130, y) 
    else 
    addtext(cont, 130, y) 
    end 
    setfontcolor("white") 
    y = y + 15 
    end 
    y = y - 5 
    end 
    
    -- [[ Supplies Wasted ]] 
    
    if showSuppliesWasted then 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("yellow") 
    y = y + 10 
    addtext(' [ Supplies wasted ]', 15, y) 
    y = y + 10 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("white") 
    y = y + 10 
    local supps = getitems(unpack(suppliesitems)) 
    local qtds = supps.count-1 
    for i=0,qtds do 
    if string.len(supps[i].name) > 17 then 
    addtext(string.sub((supps[i].name), 1, sub).."...", x, y) 
    else 
    addtext(supps[i].name, x, y) 
    end 
    addtext("- "..supps[i].usage.." ("..(math.floor(supps[i].usage*suppsvalue[i+1] / 100)/10).."k)", 120, y) 
    totals = totals + supps[i].usage*suppsvalue[i+1] 
    y = y + 15 
    end 
    addtext("Total", x, y) 
    addtext("-", 120, y) 
    addtext(totals.." GPs", 130, y) 
    y = y + 10 
    end 
    
    -- [[ Loots ]] 
    
    if showLoots then 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("yellow") 
    y = y + 10 
    addtext(' [ Items looted ]', 15, y) 
    y = y + 10 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    setfontcolor("white") 
    y = y + 10 
    local loots = getitems(unpack(lootitems)) 
    local qtdl = loots.count-1 
    for i=0,qtdl do 
    if loots[i].loot > 0 then 
    if string.len(loots[i].name) > 17 then 
    addtext(string.sub((loots[i].name), 1, sub).."...", x, y) 
    else 
    addtext(loots[i].name, x, y) 
    end 
    addtext("- "..loots[i].loot.." ("..(math.floor(loots[i].loot*lootsvalue[i+1] / 100)/10).."k)", 120, y) 
    totall = totall + loots[i].loot*lootsvalue[i+1] 
    y = y + 15 
    end 
    end 
    addtext("Total", x, y) 
    addtext("-", 120, y) 
    addtext(totall.." GPs", 130, y) 
    y = y + 10 
    end 
    
    if showSuppliesWasted and showLoots then 
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    y = y + 10 
    total = totall - totals 
    if totall-totals > 0 then 
    setfontcolor("green") 
    addtext("PROFIT:", x, y) 
    else 
    setfontcolor("red") 
    addtext("WASTE:", x, y) 
    end 
    setfontcolor("white") 
    addtext(total.." GPs ("..(math.floor((total/(tosec(timehunt)/3600))/100)/10).."k/h)", x + 50, y) 
    y = y + 10 
    end 
    
    setfontcolor("white") 
    addtext('-----------------------------------------', 0, y) 
    
    if myname then 
    setfontcolor("yellow") 
    y = y + 10 
    addtext(' [ HUD by RevoltZ ]', 5, y) 
    setfontcolor("white") 
    y = y + 10 
    addtext('-----------------------------------------', 0, y) 
    end

  2. #2
    iBot User pink_panther's Avatar
    Join Date
    May 2012
    Location
    Australia
    Posts
    4,075
    Mentioned
    49 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    178 Post(s)
    Reputation
    309
    Rep Power
    10

  3. #3
    Normal User
    Join Date
    Sep 2012
    Posts
    131
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    18
    Rep Power
    5
    Damn that was a nice HUD!

    Btw, how do i change the loot value of things ?
    Such as Beholder eye, its worth 80 GP according to the but which is NPC price.
    On my server they are about 5k ea so i'd like to edit that if its possible.
    Last edited by Xudam; 02-11-2014 at 09:33 AM.

  4. #4
    iBot User
    Join Date
    Aug 2012
    Posts
    805
    Mentioned
    18 Post(s)
    Tagged
    2 Thread(s)
    Quoted
    38 Post(s)
    Reputation
    180
    Rep Power
    7
    you can change default values with

    PHP Code:
    setcustomvalue("bonelord eye"5000
    it will change this value in items.txt

  5. #5
    Normal User
    Join Date
    Sep 2012
    Posts
    131
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    18
    Rep Power
    5
    Got one more problem, When you got the HUD 'Enabled: no' it stop counting arrows,
    i always got it disabled because if i don't it pops up all the time and its really annoying even if i got it on "only when focued".

    Is this possible to fix maybe ?
    Last edited by Xudam; 02-12-2014 at 04:06 AM.

  6. #6
    iBot User pink_panther's Avatar
    Join Date
    May 2012
    Location
    Australia
    Posts
    4,075
    Mentioned
    49 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    178 Post(s)
    Reputation
    309
    Rep Power
    10
    No.

Posting Permissions

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