SHARE
TWEET

Untitled

a guest Feb 25th, 2019 125 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ON join:
  2.     IF {poll::%player's uuid%} is not set:
  3.         WAIT 1 second
  4.         send "&aJe hebt de poll van vandaag nog niet beantwoord!" TO player
  5.         send "&aBeantwoord de poll door &f/poll &ate typen." TO player
  6. options:
  7.     vraag: Ben jij cool?
  8.     antwoord1: Ja
  9.     antwoord2: nee
  10.  
  11. command /poll [<text>]:
  12.     trigger:
  13.         IF arg-1 IS NOT set:
  14.             IF {poll::%player's uuid%} is not set:
  15.                 OPEN chest with 3 rows named "&aPoll" TO player
  16.                 set {menu.%player's uuid%} to "gui"
  17.                 create a gui slot 11 of player with diamond named "{@antwoord1}" TO RUN:
  18.                     set {poll::%player's uuid%} to true
  19.                     add 1 TO {poll.answer.1}
  20.                     send "&aJe hebt de poll beantwoord met: {@antwoord1}"
  21.                     CLOSE inventory of player
  22.                 create a gui slot 13 of player with book named "De vraag van vandaag is:" with lore "&d{@vraag}?"
  23.                 create a gui slot 15 of player with dirt named "{@antwoord2}" TO RUN:
  24.                     set {poll::%player's uuid%} to true
  25.                     add 1 TO {poll.answer.2}
  26.                     send "&aJe hebt de poll beantwoord met: {@antwoord2}"
  27.                     CLOSE inventory of player
  28.             ELSE:
  29.                 send "&cJe hebt de poll al beantwoord!"
  30.         IF arg-1 IS "list":
  31.             IF {poll.answer.1} IS NOT set:
  32.                 set {poll.answer.1} TO 0
  33.             IF {poll.answer.2} IS NOT set:
  34.                 set {poll.answer.2} TO 0
  35.             send ""  TO player
  36.             send "&8&m-------------------------" TO player
  37.             send "&aVraag: &f{@vraag}" TO player
  38.             send "Antwoord 1: %{poll.answer.1}%" TO player
  39.             send "Antwoord 2: %{poll.answer.2}%" TO player
  40.             send "&8&m-------------------------" TO player
  41.         IF arg-1 IS "reset":
  42.             CLEAR {poll::%player's uuid%}
  43.             send "&cJe kan weer &4/poll &cdoen!" TO player
  44.         IF arg-1 IS "reset-all":
  45.             IF player has permission "admin.only":
  46.                 CLEAR {poll::*}
  47.                 send "&cIedereen kan weer &4/poll &cdoen!" TO player
  48.  
  49.  
  50. ON inventory click:
  51.     IF {menu.%player's uuid%} is "gui":
  52.         cancel event
  53. ON inventory CLOSE:
  54.     delete {menu.%player's uuid%}
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top