Guest User

Untitled

a guest
Oct 21st, 2017
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.84 KB | None | 0 0
  1. on *:TEXT:*:#: {
  2. if (Success isin $1) && ($2 == you) && ($3 == bought) {
  3. /writeini bullets.ini $address($nick,2) nick $nick
  4. /writeini bullets.ini $address($nick,2) chan $chan
  5. set %totalprice $remove($8,$chr(44))
  6. set %bulletprice $calc(%totalprice / $4)
  7. if ($round(%bulletprice,0) == %bulletprice) {
  8. msg $chan 10 $+ $nick 14bought7 $4 14bullets for a total amount of7 $ $+ $8 $+ 14! That's7 $ $+ $round(%bulletprice,0) 14per bullet with no hammer set!
  9. /timer 1 60 /bulletbuyreminder $chan $address($nick,2)
  10. }
  11. if ($round(%bulletprice,0) != %bulletprice) {
  12. set %hammerprice $calc(%totalprice / ($4 / 0.99))
  13. msg $chan 10 $+ $nick 14bought7 $4 14bullets for a total amount of7 $ $+ $8 $+ 14! That's7 $ $+ $round(%hammerprice,0) 14per bullet including hammer!
  14. /timer 1 60 /bulletbuyreminder $chan $address($nick,2)
  15. }
  16. }
  17. if (You may buy bullets again in isin $1-) {
  18. msg $chan 10 $+ $nick 14reached the bulletbuylimit! I will remind you in7 $7- $+ 14!
  19. /writeini bullets.ini $address($nick,2) nick $nick
  20. /writeini bullets.ini $address($nick,2) chan $chan
  21. if ($8 == hours) {
  22. set %reminderhrs $calc($7 * 3600)
  23. set %remindermins $calc($9 * 60)
  24. set %remindertime $calc(%reminderhrs + %remindermins + $11)
  25. /timer 1 %remindertime /bulletlimitreminder $chan $address($nick,2)
  26. }
  27. if ($8 == minutes) {
  28. set %remindermins $calc($7 * 60)
  29. set %remindertime $calc(%reminderhrs + %remindermins + $9)
  30. /timer 1 %remindertime /bulletlimitreminder $chan $address($nick,2)
  31. }
  32. if ($8 == seconds) {
  33. /timer 1 $7 /bulletlimitreminder $chan $address($nick,2)
  34. }
  35. }
  36. }
  37.  
  38. on *:nick: {
  39. if ($readini(bullets.ini, $address($nick,2), nick) != $null) {
  40. writeini bullets.ini $address($nick,2) nick $newnick
  41. }
  42. }
Add Comment
Please, Sign In to add comment