Jump to content

scoreboard column data


xTravax

Recommended Posts

Posted

hi i am new with scoreboard functions and i barely know them,

i looked into wiki ,im using dxscoreboard resource which i renamed to scoreboard

and im using this code

exports.scoreboard:scoreboardAddColumn( "Player Level" ) 
function dxScore() 
setTimer(function() 
local gData = getElementData(source,"LV") 
setElementData ( source, "Player Level", gData ) 
end,1500,0) 
end 
addEventHandler("onPlayerLogin",root,dxScore) 

this makes column on scoreboard with value 0,but i can't change it

pls help

Posted

You have to send the source with the timer, because setTimer doesn't have a source.

exports.scoreboard:scoreboardAddColumn( "Player Level" ) 
function dxScore() 
setTimer(function(tPlayer) 
local gData = getElementData(tPlayer,"LV") 
setElementData ( tPlayer, "Player Level", gData ) 
end,1500,0, source) 
end 
addEventHandler("onPlayerLogin",root,dxScore) 

Posted

thanks,just one more question related to scoreboard:

what function do i need to use to draw an image left of the that Level tab on scoreboard?

Posted

You mean like 2 element Datas in one column?

If you're looking for a cheap paid scripter, don't hesitate to contact me.

Great minds discuss ideas, Average minds discuss events and small minds discuss people.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...