%loadEvent block-place; %loadEvent block-break; %loadEvent player-hurt; %loadEvent block-click; %loadEvent player-leave; %setVar mode 1; %setVar no-join true; %setVar no-quest-msg true; %setVars %getQuestLeader;; %setVar p $player-name; %setVar mapname %concat %getPlayerUUID $p; presents;; %getGlobalMap $mapname $mapname; %getGlobalMap allpresents allpresents; %sbadd $p 3 §r; %sbadd $p 2 §aPresents; %sbadd $p 1 §e%getMapSize $mapname;/%getMapSize allpresents;; %command title $p times 20 60 0; %command title $p clear; %command title $p title {"text":"Presents","color":"green"}; %speak $p §aPresents §eFinde alle auf der Map vertgeilten Geschenksköpfe. Um zu pausieren oder etwas anderes zu machen, verwende einfach /leave oder kurz /l. Fröhliche Weihnachten!; %setHealth $p 20; %setHunger $p 20; %setSaturation $p 5; %teleportPlayer $p $spawnloc; %command clear $p; %sgoto 100 loop; @wait %wait; %if $event == block-click && $mode == 1 && $block-type == SKULL then goto foundskull; %if $event == block-place && $mode == 0 && %getItemInMainHand $player-name; == $presentitem then goto setskull; %if $event == block-break || $event == block-place || $event == player-hurt then setVar cancel true; %if $event == player-leave then goto leavegame; %goto wait; @loop %setHunger $player-name 20; %setSaturation $player-name 5; %sgoto 100 loop; %goto wait; @setskull %addGlobalMapElement allpresents $block-loc true; %getGlobalMap allpresents allpresents; %msg $player-name Kopf %getMapSize allpresents; wurde gesetzt.; %goto wait; @foundskull %setVar mapname %concat %getPlayerUUID $player-name; presents;; %getGlobalMap $mapname $mapname; %getGlobalMap allpresents allpresents; %if %checkForMapKey $mapname $block-loc; == true then goto alreadyfound; %addGlobalMapElement $mapname $block-loc true; %addMapElement $mapname $block-loc true; %speak $player-name §aPresents §eDu hast Geschenk §b%getMapSize $mapname; §evon §b%getMapSize allpresents; §egefunden.; %sbadd $p 1 §e%getMapSize $mapname;/%getMapSize allpresents;; %if %getMapSize allpresents; == %getMapSize $mapname; then goto foundall; %goto wait; @alreadyfound %speak $player-name §aPresents §eDu hast dieses Geschenk bereits gefunden.; %goto wait; @foundall %speak $player-name §aPresents §eHerzlichen Glückwunsch, du hast alle Geschenke gefunden.; %addGlobalMapElement presentwinners %getPlayerUUID $player-name; %getMapSize presentwinners;; %getGlobalMap presentwinners presentwinners; %speak $player-name §aPresents §eAnzahl der Spieler, die alle Geschenke gefunden haben: %getMapSize presentwinners;; %goto wait; @giveup %teleportPlayer $player-name $gamesworldloc; @leavegame %setVar p $player-name; %sbreset $p; %setHealth $p 20; %setHunger $p 20; %setSaturation $p 5; %term;