Paper Posted January 5, 2012 Share Posted January 5, 2012 (edited) Hello guys, Today i'm here for release my new script, it's pretty simple but i think it can be very useful. When i started my scripter career i always tryed to make a fully working pointsystem for my server.Now i want help who want do this for his own server. For now you can store just points, but in future releases i will implement other stuffs, like cash and others. This script have 4 simple exported functions: getPlayerPoints(thePlayer)setPlayerPoints(thePlayer)takePlayerPoints(thePlayer)givePlayerPoints(thePlayer) And here are the arguments for use these functions: int getPlayerPoints(element player ) bool setPlayerPoints(element player, int amount) bool takePlayerPoints(element player, int amount) bool givePlayerPoints(element player, int amount) And you have 2 methods for store the datas: On accountsOn SQL database For select the method you have to change the resource setting in the admin panel: 'accounts' or 'database' You can download it here: https://community.multitheftauto.com/index.php?p=resources&s=details&id=3478 Edited January 5, 2012 by Guest Link to comment
FatalTerror Posted January 5, 2012 Share Posted January 5, 2012 Great, keep it up getPlayerPoints(thePlayer) setPlayerPoints(thePlayer) takePlayerPoints(thePlayer) givePlayerPoints(thePlayer) Where are arguments ? ^^ int getPlayerPoints(element player ) bool setPlayerPoints(element player, int amount) bool takePlayerPoints(element player, int amount) bool givePlayerPoints(element player, int amount) Link to comment
CapY Posted January 5, 2012 Share Posted January 5, 2012 Yes, where are the arguments ? EDIT: I found them, FatalTerror take a look in the script. Link to comment
Paper Posted January 5, 2012 Author Share Posted January 5, 2012 Oh, my bad, inserted in the main post ^^ Any feedback? Link to comment
Orange Posted January 5, 2012 Share Posted January 5, 2012 Why do you call it "classes"? It's not OOP Link to comment
Paper Posted January 5, 2012 Author Share Posted January 5, 2012 OOP? Explain what is it D: Link to comment
12p Posted January 5, 2012 Share Posted January 5, 2012 Object Oriented Programming The point is, "Why do you call it classes?" Just wanna make it sound cool? lol Link to comment
Paper Posted January 5, 2012 Author Share Posted January 5, 2012 Yes, i wanted make it sound cool... lol And anyway nobody cares if it's OOP or not Link to comment
12p Posted January 5, 2012 Share Posted January 5, 2012 And anyway nobody cares if it's OOP or not Unexperienced scripters don't. People like Orange do. Link to comment
Paper Posted January 5, 2012 Author Share Posted January 5, 2012 So wait, if i treat my script like OOP but it is not will cause errors whit the code? I don't think, so i don't care about the name Don't be so fiscal Link to comment
Orange Posted January 6, 2012 Share Posted January 6, 2012 And anyway nobody cares if it's OOP or not Unexperienced scripters don't. People like Orange do. I #care. 24/7 on that channel So wait, if i treat my script like OOP but it is not will cause errors whit the code? I don't think, so i don't care about the name Don't be so fiscal It won't cause errors, but it will make people miss the point of the name "classes" Check out GUI Classes by 50p and compare it with your resource. It's something totally else. But whatever, good job - lazy people will use it Link to comment
Paper Posted January 6, 2012 Author Share Posted January 6, 2012 Oh cmon, i want you as friend. I named my resource in a wrong method, i'll take care of it in my next releases Thanks 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