Numinex97 Posted March 23, 2014 Share Posted March 23, 2014 Hello, I want to make some script like when I kill another player I will get some score, and I can buy some things (weapons, heal...) with that score... Is possible to save that score for every player after thay log off and log in... If somebody can help me i will be very happy... Sorry for my bad English. Link to comment
justn Posted March 23, 2014 Share Posted March 23, 2014 Well, if you wanna create the "Score" column on scoreboard, you can use exports [ "scoreboard" ]:addScoreboardColumn ( "Score" ) and If you wanna save the scores on the account You must use setAccountData getAccountData If you wanna use 'scores' to buy ammo etc, i think you'll need to create your own functions like getPlayerScore etc. Link to comment
Numinex97 Posted March 23, 2014 Author Share Posted March 23, 2014 Is it complicated to do? Link to comment
.:HyPeX:. Posted March 23, 2014 Share Posted March 23, 2014 Well, if you wanna create the "Score" column on scoreboard, you can use exports [ "scoreboard" ]:addScoreboardColumn ( "Score" ) and If you wanna save the scores on the account You must use setAccountData getAccountData If you wanna use 'scores' to buy ammo etc, i think you'll need to create your own functions like getPlayerScore etc. You're missing that scoreboard will only display Element Data "Score", it will not get the account data. Link to comment
justn Posted March 23, 2014 Share Posted March 23, 2014 He wanted to save the scores when player leaves/joins. setAccountData for him to store it into his account. Link to comment
.:HyPeX:. Posted March 23, 2014 Share Posted March 23, 2014 He wanted to save the scores when player leaves/joins. setAccountData for him to store it into his account. And make the scoreboard thingy. That will only add it, not set any value in it to any player. Link to comment
justn Posted March 24, 2014 Share Posted March 24, 2014 Ah my bad, i forgot to add setElementData To: Numinex97 You can use setElementData to set a value for the scores. setElementData 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