noobsai 0 Posted May 23, 2014 Hi Im really noob in item scripting so i need help. I make a new item called ticket and I want it to have a function that when used it will generate a cashpoint randomly from 20-50 points (cashpoint from @cash command) Thanks in advance Quote Share this post Link to post Share on other sites
0 jaBote 438 Posted May 23, 2014 You should have told me before that, but I think the atcommand method does notify about the user's current cash. If you want to get notified when using the #CASHPOINTS method, use this other code: .@addition = rand(20,50);#CASHPOINTS += .@addition;announce "You've earned " + .@addition + " Cash Points. Your current total is " + #CASHPOINTS + " Cash Points.", bc_self; Quote Share this post Link to post Share on other sites
0 jaBote 438 Posted May 23, 2014 You can simply use this on its code: #CASHPOINTS += rand(20,50); Or if you feel safer by using the atcommand: atcommand "@cash " + rand(20,50); Quote Share this post Link to post Share on other sites
0 noobsai 0 Posted May 23, 2014 Hi Thanks jaBote, how do i add a message of how much he get. message will be seen in the chat box Quote Share this post Link to post Share on other sites
0 noobsai 0 Posted May 24, 2014 Thank you again JaBote Quote Share this post Link to post Share on other sites
0 WalkingBad 0 Posted May 28, 2014 please share. i'm interested ) Quote Share this post Link to post Share on other sites
0 jaBote 438 Posted May 28, 2014 please share. i'm interested ) Just make your own item, and make sure its on use script is like this one: .@addition = rand(20,50);#CASHPOINTS += .@addition;announce "You've earned " + .@addition + " Cash Points. Your current total is " + #CASHPOINTS + " Cash Points.", bc_self; 1 WalkingBad reacted to this Quote Share this post Link to post Share on other sites
0 WalkingBad 0 Posted May 28, 2014 Thank you very much sir jabote... I thought it was part of some script Quote Share this post Link to post Share on other sites
Hi Im really noob in item scripting so i need help.
I make a new item called ticket and I want it to have a function that when used it will generate a cashpoint randomly from 20-50 points
(cashpoint from @cash command)
Thanks in advance
Share this post
Link to post
Share on other sites