Results 1 to 3 of 3

Thread: [RELEASE] Creature HUD and Rashid HUD

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

    [RELEASE] Creature HUD and Rashid HUD

    Rashid HUD (Highlights with green text the day and location where Rashid is at);
    Code:
    -- Rashid HUD
    setfontstyle(fontfamily, headfontsize, headfontcolor)
    setfontcolor(rgbcolor(30, 144, 255))
    addtext("  - Rashid HUD -", startposx, startposy+160)
    
    -- Monday
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    if os.date("%A") == "Monday" then
    setfontcolor(rgbcolor(0, 255, 0))
    addtext("Monday	- Svargrond", startposx,startposy+175)
    else
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    addtext("Monday	- Svargrond", startposx,startposy+175)
    end
    
    -- Tuesday
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    if os.date("%A") == "Tuesday" then
    setfontcolor(rgbcolor(0, 255, 0))
    addtext("Tuesday 	- Liberty Bay", startposx,startposy+190)
    else
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    addtext("Tuesday 	- Liberty Bay", startposx,startposy+190)
    end
    
    -- Wednesday
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    if os.date("%A") == "Wednesday" then
    setfontcolor(rgbcolor(0, 255, 0))
    addtext("Wednesday	- Port Hope", startposx,startposy+205)
    else
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    addtext("Wednesday	- Port Hope", startposx,startposy+205)
    end
    
    -- Thursday
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    if os.date("%A") == "Thursday" then
    setfontcolor(rgbcolor(0, 255, 0))
    addtext("Thursday	- Ankrahmun", startposx,startposy+220)
    else
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    addtext("Thursday	- Ankrahmun", startposx,startposy+220)
    end
    
    -- Friday
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    if os.date("%A") == "Friday" then
    setfontcolor(rgbcolor(0, 255, 0))
    addtext("Friday		- Darashia", startposx,startposy+235)
    else
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    addtext("Friday		- Darashia", startposx,startposy+235)
    end
    
    -- Saturday
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    if os.date("%A") == "Saturday" then
    setfontcolor(rgbcolor(0, 255, 0))
    addtext("Saturday	- Edron", startposx,startposy+250)
    else
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    addtext("Saturday	- Edron", startposx,startposy+250)
    end
    
    -- Sunday
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    if os.date("%A") == "Sunday" then
    setfontcolor(rgbcolor(0, 255, 0))
    addtext("Sunday		- Carlin", startposx,startposy+265)
    else
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    addtext("Sunday		- Carlin", startposx,startposy+265)
    end
    Creature HUD (Gets an approx. level of the creatures in the screen, since its based on their speed) ;
    Code:
    -- Players HUD
    setfontstyle(fontfamily, headfontsize, headfontcolor)
    setfontcolor(rgbcolor(30, 144, 255))
    addtext("  - Players HUD -", startposx, startposy+295)
    
    local pgot = getcreatures("ps")
    local ptable = {}
    local pqtd = pgot.count
    
    setfontstyle(fontfamily, fontsize, fontcolor)
    setfontcolor(rgbcolor(205, 200, 177))
    for i=0,pqtd-1 do
    	local eq = 15 * i
    	local total = 310 + eq
    	local estlvl1 = pgot[i].speed - 220 
    	local estlvl2 = estlvl1/2
    	local estlvl3 = estlvl2 + 1
    	table.insert(ptable, pgot[i].name)
    	addtext(pgot[i].name .. " - Level: " .. estlvl3, startposx, startposy+total)
    end
    Credits to Nosekim for the base script that stores players in a table.
    Last edited by ErickLua; 10-13-2012 at 04:45 PM.

  2. #2
    Normal User
    Join Date
    Jun 2012
    Location
    Sweden
    Posts
    1,671
    Mentioned
    18 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    8 Post(s)
    Reputation
    132
    Rep Power
    9
    Good job! Thanks for relaseing :-)

  3. #3
    Normal User
    Join Date
    Aug 2012
    Location
    venezuela
    Posts
    127
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    6
    Rep Power
    0
    copy all and pase not work

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
  •