InFerNo_01 Posted June 26, 2012 Share Posted June 26, 2012 Hello, I'm looking for a script which add a 'Score' column in the scoreboard which show the score of the player (when he wins a race, he become points and they are visible in the scoreboard). + the scores are saved with the account. I can't find this resources anywhere, can someone help me please? Thank's Link to comment
Wei Posted June 26, 2012 Share Posted June 26, 2012 Script it your self. Or pay someone to script for you. Link to comment
InFerNo_01 Posted June 26, 2012 Author Share Posted June 26, 2012 Script it your self.Or pay someone to script for you. utility of your message? I can't do it by myself and I can't pay someone for it, I just ask if someone have/know this script and it's the good section for it so.. Link to comment
Wei Posted June 26, 2012 Share Posted June 26, 2012 try. I didn't test it so it's not 100% that will work... exports [ 'scoreboard' ]:addScoreboardColumn ( "Points" ) function onRaceFinish( rank ) local acc = getPlayerAccount( source ) local ptzData = getAccountData( acc, "Points" ) if rank == 1 then if ptzData then setAccountData( acc, "Points", ptzData + 1 ) else setAccountData( acc, "Points", 1 ) end end end addEventHandler("onPlayerFinish", getRootElement(), onRaceFinish) function refreshData() for k, v in ipairs (getElementsByType("player")) do local data = getAccountData(getPlayerAccount( v ), "Points" ) if data then setElementData( v, "Points", data ) end end end setTimer( refreshData, 1000, 0 ) Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now