Advertisement
Guest User

Donnie64

a guest
Jul 7th, 2015
185
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.58 KB | None | 0 0
  1. alias -l addPoints {
  2. if ($1 !isnum) { echo 2 -st $1 is not a number. It needs to be a number. | halt }
  3. var %topic $+($chan,.,$nick)
  4. var %points $calc($readini(Points.ini,%topic,Points) + $1)
  5. writeini -n Points.ini %topic Points %points
  6. return %points
  7. }
  8.  
  9. alias -l lookUpPoints {
  10. var %topic $+($chan,.,$nick)
  11. var %points $readini(Points.ini,%topic,Points)
  12. return %points
  13. }
  14. alias doaddpoints {
  15. if ($3 !isnum) { echo 2 -st $3 is not a number. It needs to be a number. | halt }
  16. var %topic $+($1,.,$2)
  17. var %points $calc($readini(Points.ini,%topic,Points) + $3)
  18. writeini -n Points.ini %topic Points %points
  19. echo -a Added points for %topic
  20. }
  21.  
  22. alias dorempoints {
  23. var %topic $+($1,.,$2)
  24. remini -n Points.ini %topic Points
  25. echo -a Removed points for %topic
  26. }
  27.  
  28. on *:text:!Gold:#:{
  29. msg # $nick has $readini(Points.ini,$+(#,.,$nick),Points) Gold.
  30. }
  31.  
  32. on $*:text:/!Gold (add|remove)/Si:#:{
  33. if ($nick isop #) {
  34. if ($0 < 3) { msg # Insufficient parameters: Use !points <add|remove> <user> [number] | return }
  35. writeini -n Points.ini $+(#,.,$3) Points $calc($readini(Points.ini,$+(#,.,$3),Points) $iif($2 == add,+,-) $iif($4 isnum,$4,1))
  36. { msg $chan $3 now has $readini(Points.ini,$+(#,.,$3),Points) Gold. }
  37. }
  38. else { msg $chan This command is only available to the Elite Dragon Gaurd. }
  39. }
  40.  
  41. alias addpts {
  42. .writeini -n Points.ini $1 Points $calc($readini(Points.ini,$1,Points) + 2)
  43.  
  44. }
  45.  
  46. on !*:join:#:{
  47. $+(.timerpoints.,#,.,$nick) 1 10 addpts $+(#,.,$nick)
  48. addpts $+(#,.,$nick)
  49. }
  50.  
  51. on !*:part:#:$+{.timerpoints.,#,.,$nick) off
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement