Signup Now
Page 1 of 2 12 LastLast
Results 1 to 10 of 14

Thread: [HUD] Spell Bar

  1. #1
    Free User
    Join Date
    Dec 2014
    Posts
    12
    Reputation
    17
    Rep Power
    0

    Post [HUD] Spell Bar

    SPELL BAR

    Old Version:



    New Version
    About:

    • Auto Detecte spell configured in your tibia client
    • You can move HUD with middle mouse button. Thanks to @sirmate.
    • For the powers in which the icon does not appear , I added the gray button.(Does not appear in the tibia client are not sprites that power
    • Cooldown time Added
    • Working for all VOC
    • New version: Have been added all icons of powers. Get errors with the powers they have ("" For example Exura Sio "Player"), if any can help me.

    Importan Note: For the new version to work properly you need to download here unzip and copy the icons on the Windbot / images folder.

    Version and Changelog:

    • v1.0 - 24/02/2015 - Beta version.
    • v1.1 - 26/02/2015 - Beta version.


    NEW Code:

     
    --- SPELL HOTKEYS
    init start
    local poder = {
    { icon ="Annihilation.png", name ="Annihilation", spell ="exori gran ico" },
    { icon ="Apprentices_Strike.png", name ="Apprentice's Strike", spell ="exori min flam" },
    { icon ="Arrow_Call.png", name ="Arrow Call", spell ="exevo infir con" },
    { icon ="Berserk.png", name ="Berserk", spell ="exori" },
    { icon ="Blood_Rage.png", name ="Blood Rage", spell ="utito tempo" },
    { icon ="Bruise_Bane.png", name ="Bruise Bane", spell ="exura infir ico" },
    { icon ="Brutal_Strike.png", name ="Brutal Strike", spell ="exori ico" },
    { icon ="Buzz.png", name ="Buzz", spell ="exori infir vis" },
    { icon ="Cancel_Invisibility.png", name ="Cancel Invisibility", spell ="exana ina" },
    { icon ="Challenge.png", name ="Challenge", spell ="exeta res" },
    { icon ="Charge.png", name ="Charge", spell ="utani tempo hur" },
    { icon ="Chill_Out.png", name ="Chill Out", spell ="exevo infir frigo hur" },
    { icon ="Conjure_Arrow.png", name ="Conjure Arrow", spell ="exevo con" },
    { icon ="Conjure_Bolt.png", name ="Conjure Bolt", spell ="exevo con mort" },
    { icon ="Conjure_Explosive_Arrow.png", name ="Conjure Explosive Arrow", spell ="exevo con flam" },
    { icon ="Conjure_Piercing_Bolt.png", name ="Conjure Piercing Bolt", spell ="exevo con grav" },
    { icon ="Conjure_Poisoned_Arrow.png", name ="Conjure Poisoned Arrow", spell ="exevo con pox" },
    { icon ="Conjure_Power_Bolt.png", name ="Conjure Power Bolt", spell ="exevo con vis" },
    { icon ="Conjure_Sniper_Arrow.png", name ="Conjure Sniper Arrow", spell ="exevo con hur" },
    { icon ="Creature_Illusion.png", name ="Creature Illusion", spell ="utevo res ina \"creature\"" },
    { icon ="Cure_Bleeding.png", name ="Cure Bleeding", spell ="exana kor" },
    { icon ="Cure_Burning.png", name ="Cure Burning", spell ="exana flam" },
    { icon ="Cure_Curse.png", name ="Cure Curse", spell ="exana mort" },
    { icon ="Cure_Electrification.png", name ="Cure Electrification", spell ="exana vis" },
    { icon ="Cure_Poison.png", name ="Cure Poison", spell ="exana pox" },
    { icon ="Curse.png", name ="Curse", spell ="utori mort" },
    { icon ="Death_Strike.png", name ="Death Strike", spell ="exori mort" },
    { icon ="Divine_Caldera.png", name ="Divine Caldera", spell ="exevo mas san" },
    { icon ="Divine_Healing.png", name ="Divine Healing", spell ="exura san" },
    { icon ="Divine_Missile.png", name ="Divine Missile", spell ="exori san" },
    { icon ="Electrify.png", name ="Electrify", spell ="utori vis" },
    { icon ="Enchant_Party.png", name ="Enchant Party", spell ="utori mas sio" },
    { icon ="Enchant_Spear.png", name ="Enchant Spear", spell ="exeta con" },
    { icon ="Enchant_Staff.png", name ="Enchant Staff", spell ="exeta vis" },
    { icon ="Energy_Beam.png", name ="Energy Beam", spell ="exevo vis lux" },
    { icon ="Energy_Strike.png", name ="Energy Strike", spell ="exori vis" },
    { icon ="Energy_Wave.png", name ="Energy Wave", spell ="exevo vis hur" },
    { icon ="Envenom.png", name ="Envenom", spell ="utori pox" },
    { icon ="Eternal_Winter.png", name ="Eternal Winter", spell ="exevo gran mas frigo" },
    { icon ="Ethereal_Spear.png", name ="Ethereal Spear", spell ="exori con" },
    { icon ="Fierce_Berserk.png", name ="Fierce Berserk", spell ="exori gran" },
    { icon ="Find_Person.png", name ="Find Person", spell ="exiva \"NAME\"" },
    { icon ="Fire_Wave.png", name ="Fire Wave", spell ="exevo flam hur" },
    { icon ="Flame_Strike.png", name ="Flame Strike", spell ="exori flam" },
    { icon ="Food_%28Spell%29.png", name ="Food (Spell)", spell ="exevo pan" },
    { icon ="Front_Sweep.png", name ="Front Sweep", spell ="exori min" },
    { icon ="Great_Energy_Beam.png", name ="Great Energy Beam", spell ="exevo gran vis lux" },
    { icon ="Great_Light.png", name ="Great Light", spell ="utevo gran lux" },
    { icon ="Groundshaker.png", name ="Groundshaker", spell ="exori mas" },
    { icon ="Haste.png", name ="Haste", spell ="utani hur" },
    { icon ="Heal_Friend.png", name ="Heal Friend", spell ="exura sio \"name\"" },
    { icon ="Heal_Party.png", name ="Heal Party", spell ="utura mas sio" },
    { icon ="Hells_Core.png", name ="Hell's Core", spell ="exevo gran mas flam" },
    { icon ="Holy_Flash.png", name ="Holy Flash", spell ="utori san" },
    { icon ="Ice_Strike.png", name ="Ice Strike", spell ="exori frigo" },
    { icon ="Ice_Wave.png", name ="Ice Wave", spell ="exevo frigo hur" },
    { icon ="Ignite.png", name ="Ignite", spell ="utori flam" },
    { icon ="Inflict_Wound.png", name ="Inflict Wound", spell ="utori kor" },
    { icon ="Intense_Healing.png", name ="Intense Healing", spell ="exura gran" },
    { icon ="Intense_Recovery.png", name ="Intense Recovery", spell ="utura gran" },
    { icon ="Intense_Wound_Cleansing.png", name ="Intense Wound Cleansing", spell ="exura gran ico" },
    { icon ="Invisible.png", name ="Invisible", spell ="utana vid" },
    { icon ="Levitate.png", name ="Levitate", spell ="exani hur up" },
    { icon ="Levitate.png", name ="Levitate", spell ="exani hur down" },
    { icon ="Light.png", name ="Light", spell ="utevo lux" },
    { icon ="Light_Healing.png", name ="Light Healing", spell ="exura" },
    { icon ="Lightning.png", name ="Lightning", spell ="exori amp vis" },
    { icon ="Magic_Patch.png", name ="Magic Patch", spell ="exura infir" },
    { icon ="Magic_Rope.png", name ="Magic Rope", spell ="exani tera" },
    { icon ="Magic_Shield.png", name ="Magic Shield", spell ="utamo vita" },
    { icon ="Mass_Healing.png", name ="Mass Healing", spell ="exura gran mas res" },
    { icon ="Mud_Attack.png", name ="Mud Attack", spell ="exori infir tera" },
    { icon ="Physical_Strike.png", name ="Physical Strike", spell ="exori moe ico" },
    { icon ="Practise_Fire_Wave.png", name ="Practise Fire Wave", spell ="exevo dis flam hur" },
    { icon ="Practise_Healing.png", name ="Practise Healing", spell ="exura dis" },
    { icon ="Protect_Party.png", name ="Protect Party", spell ="utamo mas sio" },
    { icon ="Protector.png", name ="Protector", spell ="utamo tempo" },
    { icon ="Rage_of_the_Skies.png", name ="Rage of the Skies", spell ="exevo gran mas vis" },
    { icon ="Recovery.png", name ="Recovery", spell ="utura" },
    { icon ="Salvation.png", name ="Salvation", spell ="exura gran san" },
    { icon ="Scorch.png", name ="Scorch", spell ="exevo infir flam hur" },
    { icon ="Sharpshooter.png", name ="Sharpshooter", spell ="utito tempo san" },
    { icon ="Strong_Energy_Strike.png", name ="Strong Energy Strike", spell ="exori gran vis" },
    { icon ="Strong_Ethereal_Spear.png", name ="Strong Ethereal Spear", spell ="exori gran con" },
    { icon ="Strong_Flame_Strike.png", name ="Strong Flame Strike", spell ="exori gran flam" },
    { icon ="Strong_Haste.png", name ="Strong Haste", spell ="utani gran hur" },
    { icon ="Strong_Ice_Strike.png", name ="Strong Ice Strike", spell ="exori gran frigo" },
    { icon ="Strong_Ice_Wave.png", name ="Strong Ice Wave", spell ="exevo gran frigo hur" },
    { icon ="Strong_Terra_Strike.png", name ="Strong Terra Strike", spell ="exori gran tera" },
    { icon ="Summon_Creature.png", name ="Summon Creature", spell ="utevo res \"creature name\"" },
    { icon ="Swift_Foot.png", name ="Swift Foot", spell ="utamo tempo san" },
    { icon ="Terra_Strike.png", name ="Terra Strike", spell ="exori tera" },
    { icon ="Terra_Wave.png", name ="Terra Wave", spell ="exevo tera hur" },
    { icon ="Train_Party.png", name ="Train Party", spell ="utito mas sio" },
    { icon ="Ultimate_Energy_Strike.png", name ="Ultimate Energy Strike", spell ="exori max vis" },
    { icon ="Ultimate_Flame_Strike.png", name ="Ultimate Flame Strike", spell ="exori max flam" },
    { icon ="Ultimate_Healing.png", name ="Ultimate Healing", spell ="exura vita" },
    { icon ="Ultimate_Ice_Strike.png", name ="Ultimate Ice Strike", spell ="exori max frigo" },
    { icon ="Ultimate_Light.png", name ="Ultimate Light", spell ="utevo vis lux" },
    { icon ="Ultimate_Terra_Strike.png", name ="Ultimate Terra Strike", spell ="exori max tera" },
    { icon ="Whirlwind_Throw.png", name ="Whirlwind Throw", spell ="exori hur" },
    { icon ="Wound_Cleansing.png", name ="Wound Cleansing", spell ="exura ico" },
    { icon ="Wrath_of_Nature.png", name ="Wrath of Nature", spell ="exevo gran mas tera" },
    { icon ="Avalanche.png", name ="Avalanche", spell ="adori mas frigo" },
    { icon ="Chameleon.png", name ="Chameleon", spell ="adevo ina" },
    { icon ="Convince_Creature.png", name ="Convince Creature", spell ="adeta sio" },
    { icon ="Cure_Poison_Rune.png", name ="Cure Poison Rune", spell ="adana pox" },
    { icon ="Destroy_Field.png", name ="Destroy Field", spell ="adito grav" },
    { icon ="Disintegrate.png", name ="Disintegrate", spell ="adito tera" },
    { icon ="Energy_Bomb.png", name ="Energy Bomb", spell ="adevo mas vis" },
    { icon ="Energy_Field.png", name ="Energy Field", spell ="adevo grav vis" },
    { icon ="Energy_Wall.png", name ="Energy Wall", spell ="adevo mas grav vis" },
    { icon ="Explosion.png", name ="Explosion", spell ="adevo mas hur" },
    { icon ="Fire_Bomb.png", name ="Fire Bomb", spell ="adevo mas flam" },
    { icon ="Fire_Field.png", name ="Fire Field", spell ="adevo grav flam" },
    { icon ="Fire_Wall.png", name ="Fire Wall", spell ="adevo mas grav flam" },
    { icon ="Fireball.png", name ="Fireball", spell ="adori flam" },
    { icon ="Great_Fireball.png", name ="Great Fireball", spell ="adori mas flam" },
    { icon ="Heavy_Magic_Missile.png", name ="Heavy Magic Missile", spell ="adori vis" },
    { icon ="Holy_Missile.png", name ="Holy Missile", spell ="adori san" },
    { icon ="Icicle.png", name ="Icicle", spell ="adori frigo" },
    { icon ="Intense_Healing_Rune.png", name ="Intense Healing Rune", spell ="adura gran" },
    { icon ="Light_Magic_Missile.png", name ="Light Magic Missile", spell ="adori min vis" },
    { icon ="Magic_Wall.png", name ="Magic Wall", spell ="adevo grav tera" },
    { icon ="Paralyse.png", name ="Paralyse", spell ="adana ani" },
    { icon ="Poison_Bomb.png", name ="Poison Bomb", spell ="adevo mas pox" },
    { icon ="Poison_Field.png", name ="Poison Field", spell ="adevo grav pox" },
    { icon ="Poison_Wall.png", name ="Poison Wall", spell ="adevo mas grav pox" },
    { icon ="Practise_Magic_Missile.png", name ="Practise Magic Missile", spell ="adori dis min vis" },
    { icon ="Soulfire.png", name ="Soulfire", spell ="adevo res flam" },
    { icon ="Stalagmite.png", name ="Stalagmite", spell ="adori tera" },
    { icon ="Stone_Shower.png", name ="Stone Shower", spell ="adori mas tera" },
    { icon ="Sudden_Death.png", name ="Sudden Death", spell ="adori gran mort" },
    { icon ="Thunderstorm.png", name ="Thunderstorm", spell ="adori mas vis" },
    { icon ="Ultimate_Healing_Rune.png", name ="Ultimate Healing Rune", spell ="adura vita" },
    { icon ="Wild_Growth.png", name ="Wild Growth", spell ="adevo grav vita" }
    }



    auto(200)
    hotkey = {}
    local i = 1
    local j = 1
    while i <= #poder do
    if clientspellhotkey(poder[i].spell) == 'not found' then
    else
    hotkey[j]={}
    hotkey[j].key = clientspellhotkey(poder[i].spell)
    hotkey[j].action = function() keyevent(hotkey[j].key) end
    hotkey[j].spell = poder[i].spell
    hotkey[j].icon = poder[i].icon
    j=j+1
    end

    i=i+1
    end
    print(hotkey)

    -- Locale
    local lastPressed = {id = -1, time = $timems}
    local rectHeight, rectWidth = 200, 140
    setposition($clientwin.left, $clientwin.bottom)



    -- Moving window
    filterinput(false, true, false, false)
    local Moving, Temp, Moved = false, {0, 0}, {0, 0}

    function inputevents(e)
    if (e.type == IEVENT_LMOUSEDOWN) then
    for _, button in ipairs(hotkey) do
    if (e.elementid == button.id) then
    lastPressed = {id = button.id, time = $timems}
    keyevent(button.key)
    end
    end
    end
    if (e.type == IEVENT_MMOUSEDOWN) then
    Moving, Temp = true, {$cursor.x - Moved[1], $cursor.y - Moved[2]}
    end

    if (e.type == IEVENT_MMOUSEUP) then
    Moving = false
    if math.abs(Moved[1]) <= 15 then
    Moved[1] = 0
    end
    if math.abs(Moved[2]) <= 15 then
    Moved[2] = 0
    elseif math.abs(($worldwin.bottom-20) - Moved[2]) <= 15 then
    Moved[2] = $worldwin.bottom-20
    end
    end
    end
    init end


    if (Moving) then
    auto(10)
    Moved = {$cursor.x - Temp[1], $cursor.y - Temp[2]}
    end

    setposition($clientwin.left + 200+ Moved[1], $clientwin.bottom - 150 + Moved[2])


    ---- Engine ----
    -- Button layout
    setfontsize(10)
    spacing = 0
    for i = 1, #hotkey do
    setfillstyle('gradient', 'linear', 2, 0, 0, 0, 22)
    addgradcolors(0.0, color(80, 80, 80, 0))
    if hotkey then
    hotkey[i].id = drawimage(hotkey[i].icon, i + spacing , 10,0,0,90,90)
    drawtext(hotkey[i].spell, i + spacing , 7)
    setfontsize(16)
    drawtext(math.round(cooldown(hotkey[i].spell)/1000), i + 12 + spacing, 25)
    setfontsize(10)
    end
    if i == i then
    spacing = spacing +70
    end
    end


    -- clickable action
    if $timems - lastPressed.time > 100 then
    lastPressed.id = -1
    end



    OLD Code:

    --- SPELL BAR
    init start
    local poder = {'exori gran ico', 'exori min flam', 'exevo infir con', 'exori', 'utito tempo', 'exura infir ico', 'exori ico', 'exori infir vis',
    'exana ina', 'exeta res', 'utani tempo hur', 'exevo infir frigo hur', 'exevo con', 'exevo con mort', 'exevo con flam', 'exevo con grav',
    'exevo con pox', 'exevo con vis', 'exevo con hur', 'exana kor', 'exana flam', 'exana mort', 'exana vis', 'exana pox', 'utori mort', 'exori mort',
    'exevo mas san', 'exura san', 'exori san', 'utori vis', 'utori mas sio', 'exeta con', 'exeta vis', 'exevo vis lux', 'exori vis', 'exevo vis hur',
    'utori pox', 'exevo gran mas frigo', 'exori con', 'exori gran', 'exiva "NAME"', 'exevo flam hur', 'exori flam', 'exevo pan', 'exori min', 'exevo gran vis lux',
    'utevo gran lux', 'exori mas', 'utani hur', 'exura sio "name"', 'utura mas sio', 'exevo gran mas flam', 'utori san', 'exori frigo', 'exevo frigo hur',
    'utori flam', 'utori kor', 'exura gran', 'utura gran', 'exura gran ico', 'utana vid', 'exani hur up', 'utevo lux', 'exura', 'exori amp vis',
    'exura infir', 'exani tera', 'utamo vita', 'exura gran mas res', 'exori infir tera', 'exori moe ico', 'exevo dis flam hur', 'exura dis',
    'utamo mas sio', 'utamo tempo', 'exevo gran mas vis', 'utura', 'exura gran san', 'exevo infir flam hur', 'utito tempo san', 'exori gran vis',
    'exori gran con', 'exori gran flam', 'utani gran hur', 'exori gran frigo', 'exevo gran frigo hur', 'exori gran tera', 'utamo tempo san', 'exori tera',
    'exevo tera hur', 'utito mas sio', 'exori max vis', 'exori max flam', 'exura vita', 'exori max frigo', 'utevo vis lux', 'exori max tera', 'exura ico',
    'exevo gran mas tera'}

    auto(200)
    hotkey = {}
    local i = 1
    local j = 1
    while i <= #poder do
    if clientspellhotkey(poder[i]) == 'not found' then
    else
    hotkey[j]={}
    hotkey[j].key = clientspellhotkey(poder[i])
    hotkey[j].action = function() keyevent(hotkey[j].key) end
    hotkey[j].spell = poder[i]
    j=j+1
    end
    i=i+1
    end

    -- Locale
    local lastPressed = {id = -1, time = $timems}
    local rectHeight, rectWidth = 200, 140
    setposition($clientwin.left, $clientwin.bottom)


    -- Moving window
    filterinput(false, true, false, false)
    local Moving, Temp, Moved = false, {0, 0}, {0, 0}

    function inputevents(e)
    if (e.type == IEVENT_LMOUSEDOWN) then
    for _, button in ipairs(hotkey) do
    if (e.elementid == button.id) then
    lastPressed = {id = button.id, time = $timems}
    keyevent(button.key)
    end
    end
    end
    if (e.type == IEVENT_MMOUSEDOWN) then
    Moving, Temp = true, {$cursor.x - Moved[1], $cursor.y - Moved[2]}
    end

    if (e.type == IEVENT_MMOUSEUP) then
    Moving = false
    if math.abs(Moved[1]) <= 15 then
    Moved[1] = 0
    end
    if math.abs(Moved[2]) <= 15 then
    Moved[2] = 0
    elseif math.abs(($worldwin.bottom-20) - Moved[2]) <= 15 then
    Moved[2] = $worldwin.bottom-20
    end
    end
    end
    init end

    if (Moving) then
    auto(10)
    Moved = {$cursor.x - Temp[1], $cursor.y - Temp[2]}
    end

    setposition($clientwin.left + 200+ Moved[1], $clientwin.bottom - 150 + Moved[2])

    ---- Engine ----
    -- Button layout
    setfontsize(10)
    spacing = 0
    for i = 1, #hotkey do
    setfillstyle('gradient', 'linear', 2, 0, 0, 0, 22)
    addgradcolors(0.0, color(80, 80, 80, 0))
    if hotkey then
    hotkey[i].id = drawrect(i + spacing -2, 9, 36, 35)
    hotkey[i].id = drawspellicon(spellinfo(hotkey[i].spell).iconid, i + spacing , 10, 180)
    drawtext(hotkey[i].spell, i + spacing , 7)
    setfontsize(16)
    drawtext(math.round(cooldown(hotkey[i].spell) /1000), i + 12 + spacing, 25)
    setfontsize(10)
    end
    if i == i then
    spacing = spacing +70
    end
    end

    -- clickable action
    if $timems - lastPressed.time > 100 then
    lastPressed.id = -1
    end

    Im W8 for ur feedback and your captures.

    Im inspired by Turc
    Attached Images Attached Images
    Last edited by ozzix; 09-14-2015 at 05:46 PM. Reason: Upload images to imgur.com

  2. #2
    Free User pvzin's Avatar
    Join Date
    Dec 2013
    Location
    USA
    Posts
    974
    Reputation
    48
    Rep Power
    22
    Nice work, bro!
    Will test it later.
    Yours,
    pvzin

  3. #3
    Free User Mrozu's Avatar
    Join Date
    Oct 2014
    Location
    Lukow/Siedlce/Poland
    Posts
    140
    Reputation
    18
    Rep Power
    19
    Tested it and look really nice!
    + for u Xd
    If I Helped, REP +


    ---------------------------------------------------------------------------------------------------------------------------

  4. #4
    Free User
    Join Date
    Dec 2014
    Posts
    12
    Reputation
    17
    Rep Power
    0
    Thk friends

  5. #5
    Free User
    Join Date
    Dec 2014
    Posts
    12
    Reputation
    17
    Rep Power
    0
    New Version Al Icons Add

  6. #6
    Free User Orimorfus's Avatar
    Join Date
    Dec 2013
    Location
    Way to Deletera
    Posts
    314
    Reputation
    92
    Rep Power
    21
    why you decided to use your own icons when you can use drawspellicon() ?

    edit: ok , I tested it myself and it drawspellicon() looks shitty as hell
    Last edited by Orimorfus; 02-26-2015 at 05:24 PM.

  7. #7
    Free User
    Join Date
    Dec 2014
    Posts
    12
    Reputation
    17
    Rep Power
    0
    I use in first versión, but drawspellicon() ho have all icons for example " untani hur"

  8. #8
    Free User
    Join Date
    Mar 2014
    Posts
    3
    Reputation
    10
    Rep Power
    0
    can you do it to only show spells used not all the hotkeys

  9. #9
    Free User breuz's Avatar
    Join Date
    May 2014
    Posts
    60
    Reputation
    25
    Rep Power
    20
    Really awesome.
    Can you add potions as well ?

  10. #10
    Free User
    Join Date
    Sep 2014
    Posts
    87
    Reputation
    10
    Rep Power
    20
    Link broken?

 

 

Tags for this Thread

Posting Permissions

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