Advertisement
Guest User

Untitled

a guest
Apr 23rd, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.79 KB | None | 0 0
  1. function shadowMessage(p: player):
  2. send "&2Hajs &3» &fTwoj stan konta: &e%{money::%{_p}%}%&l$" to {_p}
  3.  
  4. function shadowCommand(t: text, p: player):
  5. replace all " " with "" in {_t}
  6. set {_t} to ("%{_t}%" parsed as number)
  7. if {_t} is number:
  8. if {money::%{_p}%} >= {_t}:
  9. remove {_t} from {money::%{_p}%}
  10. give {_p} 1 brick named "&f&lKarta Kredytowa" with lore "&0||&eWartosc: &b%{_t}%$"
  11. stop
  12. send "&cBlad &3» &fNie masz tyle kasy, zmniejsz cene!" to {_p}
  13.  
  14. function shadowDzialanie(p: player):
  15. {_p}'s tool is brick:
  16. amount of item {_p}'s tool = 1:
  17. set {_lore} to "%uncoloured lore of {_p}'s tool%"
  18. replace all " " and "$" and "Wartosc" and ":" and "||" with "" in {_lore}
  19. set {_lore} to ("%{_lore}%" parsed as number)
  20. add {_lore} to {money::%{_p}%}
  21. send "&6Karta &3» &2(&a+%{_lore}%&e&l$&2) &fDodano do twojego konta!" to {_p}
  22. remove {_p}'s tool from {_p}'s inventory
  23. stop
  24. send "&cBlad &3» &fNie mozesz trzymac wiecej niz jedna karte!" to {_p}
  25.  
  26. on rightclick with brick:
  27. set {_p} to player
  28. shadowDzialanie({_p})
  29.  
  30. command /kasa [<text>]:
  31. aliases: money, monety, hajs
  32. trigger:
  33. set {_p} to player
  34. shadowMessage({_p})
  35.  
  36. command /karta [<text>]:
  37. trigger:
  38. arg 1 is set:
  39. set {_number} to ("%arg 1%" parsed as number)
  40. {_number} > 0:
  41. set {_p} to player
  42. set {_t} to arg 1
  43. shadowCommand({_t}, {_p})
  44. stop
  45. {_number} doesn't contain " ":
  46. send "&cBlad &3» &fZa malo posiadasz pieniedzy!"
  47. stop
  48. replace all " " with "" in {_number}
  49. set {_number} to ("%arg 1%" parsed as number)
  50. set {_p} to player
  51. set {_t} to arg 1
  52. shadowCommand({_t}, {_p})
  53. stop
  54. send "&cBlad &3» &7Poprawne uzycie: &f(/karta <liczba, mozna odzielac spacjami, wkrotce bedzie mozliwosc wpisywania: &bk, kk, kkk&f)"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement