options: ver: 0.9b #------------- Prefix i swiat gdzie ma dzialac -------------- prefix: [Spioch] world: Swiat #------------- Kod skryptu -------------- on disconnect: player's world is {@world}: spawn an armor stand at location (player's x-coordinate, player's y-coordinate-1.2, player's z-coordinate) set {_a} to last spawned entity spawn an armor stand at location (player's x-coordinate, player's y-coordinate-0.6, player's z-coordinate-0.5) set {_b} to last spawned entity set custom name of {_a} to "{@prefix}%player's name%" set custom name of {_b} to "{@prefix}%player's name%" set armor stand helmet of {_a} to player's skull set armor stand chestplate of {_a} to leather chestplate set armor stand leggings of {_b} to leather leggings set armor stand boots of {_b} to leather boots add "{Invisible:1}" to nbt of {_a} add "{CustomNameVisible:0}" to nbt of {_a} add "{NoBasePlate:1}" to nbt of {_a} add "{NoGravity:1}" to nbt of {_a} add "{ShowArms:0}" to nbt of {_a} add "{DisabledSlots:2039583}" to nbt of {_a} add "{Pose:{Body:[90f,0f,180f],LeftArm:[90f,32f,219f],RightArm:[129f,0f,280f],LeftLeg:[0f,0f,0f],RightLeg:[0f,0f,0f],Head:[90f,0f,170f]}}" to nbt of {_a} add "{Invulnerable:0}" to nbt of {_b} add "{CustomNameVisible:0}" to nbt of {_b} add "{Invisible:1}" to nbt of {_b} add "{NoBasePlate:1}" to nbt of {_b} add "{NoGravity:1}" to nbt of {_b} add "{DisabledSlots:2039583}" to nbt of {_b} add "{Pose:{Body:[0f,0f,0f],LeftArm:[0f,0f,0f],RightArm:[0f,0f,0f],LeftLeg:[90f,10f,0f],RightLeg:[90f,300f,0f],Head:[0f,0f,0f]}}" to nbt of {_b} set {sleeper::%player%::*} to all items in player's inventory set {_count} to 0 loop 36 times: set {sleeper::%player%::%{_count}%} to slot {_count} of player's inventory add 1 to {_count} set {sleeper::%player%::46} to player's helmet set {sleeper::%player%::47} to player's chestplate set {sleeper::%player%::48} to player's leggings set {sleeper::%player%::49} to player's shoes set {sleeper::%player%::45} to player's offhand stop on join: player's world is {@world}: wait a tick loop all entities: if uncolored loop-entity's display name is "{@prefix}%player's display name%": kill loop-entity clear player's inventory set {_slot} to 0 loop 36 times: set slot {_slot} of player's inventory to {sleeper::%player%::%{_slot}%} add 1 to {_slot} set {_slot} to 45 loop 5 times: if {sleeper::%player%::%{_slot}%} is helmet: if player is not wearing helmet: set player's helmet to {sleeper::%player%::%{_slot}%} else: set player's offhand to {sleeper::%player%::%{_slot}%} else if {sleeper::%player%::%{_slot}%} is chestplate: if player is not wearing chestplate: set player's chestplate to {sleeper::%player%::%{_slot}%} else: set player's offhand to {sleeper::%player%::%{_slot}%} else if {sleeper::%player%::%{_slot}%} is leggings: if player is not wearing leggings: set player's leggings to {sleeper::%player%::%{_slot}%} else: set player's offhand to {sleeper::%player%::%{_slot}%} else if {sleeper::%player%::%{_slot}%} is boots: if player is not wearing boots: set player's shoes to {sleeper::%player%::%{_slot}%} else: set player's offhand to {sleeper::%player%::%{_slot}%} add 1 to {_slot} stop on right click on armor stand: player's world is {@world}: if uncolored clicked entity's display name contains "{@prefix}": cancel event set {_player} to "%clicked entity's name%" replace all "{@prefix}" with "" in {_player} set {_player} to {_player} parsed as offline player create a gui with virtual chest with size 6 named "{@prefix}%{_player}%": open last created gui to player wait a tick set {_slot} to 0 loop 36 times: set slot {_slot} of player's current inventory to {sleeper::%{_player}%::%{_slot}%} add 1 to {_slot} create a gui slot 36 of player with black stained glass pane named "" to do nothing create a gui slot 37 of player with black stained glass pane named "" to do nothing create a gui slot 38 of player with black stained glass pane named "" to do nothing create a gui slot 39 of player with black stained glass pane named "" to do nothing create a gui slot 40 of player with black stained glass pane named "" to do nothing create a gui slot 41 of player with black stained glass pane named "" to do nothing create a gui slot 42 of player with black stained glass pane named "" to do nothing create a gui slot 43 of player with black stained glass pane named "" to do nothing create a gui slot 44 of player with black stained glass pane named "" to do nothing create a gui slot 50 of player with black stained glass pane named "" to do nothing create a gui slot 51 of player with black stained glass pane named "" to do nothing create a gui slot 52 of player with black stained glass pane named "" to do nothing create a gui slot 53 of player with black stained glass pane named "" to do nothing set {_slot} to 45 loop 5 times: set slot {_slot} of player's current inventory to {sleeper::%{_player}%::%{_slot}%} add 1 to {_slot} run when close: set {_count} to 0 loop 36 times: set {sleeper::%{_player}%::%{_count}%} to slot {_count} of player's current inventory add 1 to {_count} set {sleeper::%{_player}%::46} to slot 46 of player's current inventory set {sleeper::%{_player}%::47} to slot 47 of player's current inventory set {sleeper::%{_player}%::48} to slot 48 of player's current inventory set {sleeper::%{_player}%::49} to slot 49 of player's current inventory set {sleeper::%{_player}%::45} to slot 45 of player's current inventory stop on damage of armor stand: event-world is {@world}: if uncolored victim's display name contains "{@prefix}": attacker is player: loop entities in radius 0.8 around victim's location: loop-entity is armor stand: uncolored loop-entity's display name contains "%victim's name%": kill loop-entity set {_player} to "%victim's name%" replace all "{@prefix}" with "" in {_player} set {_player} to {_player} parsed as offline player set {_slot} to 0 loop 36 times: drop {sleeper::%{_player}%::%{_slot}%} at victim add 1 to {_slot} drop {sleeper::%{_player}%::45} at victim drop {sleeper::%{_player}%::46} at victim drop {sleeper::%{_player}%::47} at victim drop {sleeper::%{_player}%::48} at victim drop {sleeper::%{_player}%::49} at victim delete {sleeper::%{_player}%::*} kill victim stop command /Spioch: trigger: spawn an armor stand at location (player's x-coordinate, player's y-coordinate-1.2, player's z-coordinate) set {_a} to last spawned entity spawn an armor stand at location (player's x-coordinate, player's y-coordinate-0.6, player's z-coordinate-0.5) set {_b} to last spawned entity set custom name of {_a} to "{@prefix}%player's name%" set custom name of {_b} to "{@prefix}%player's name%" set armor stand helmet of {_a} to player's skull set armor stand chestplate of {_a} to leather chestplate set armor stand leggings of {_b} to leather leggings set armor stand boots of {_b} to leather boots add "{Invisible:1}" to nbt of {_a} add "{CustomNameVisible:0}" to nbt of {_a} add "{NoBasePlate:1}" to nbt of {_a} add "{NoGravity:1}" to nbt of {_a} add "{ShowArms:0}" to nbt of {_a} add "{DisabledSlots:2039583}" to nbt of {_a} add "{Pose:{Body:[90f,0f,180f],LeftArm:[90f,32f,219f],RightArm:[129f,0f,280f],LeftLeg:[0f,0f,0f],RightLeg:[0f,0f,0f],Head:[90f,0f,170f]}}" to nbt of {_a} add "{Invulnerable:0}" to nbt of {_b} add "{CustomNameVisible:0}" to nbt of {_b} add "{Invisible:1}" to nbt of {_b} add "{NoBasePlate:1}" to nbt of {_b} add "{NoGravity:1}" to nbt of {_b} add "{DisabledSlots:2039583}" to nbt of {_b} add "{Pose:{Body:[0f,0f,0f],LeftArm:[0f,0f,0f],RightArm:[0f,0f,0f],LeftLeg:[90f,10f,0f],RightLeg:[90f,300f,0f],Head:[0f,0f,0f]}}" to nbt of {_b} set {sleeper::%player%::*} to all items in player's inventory set {_count} to 0 loop 36 times: set {sleeper::%player%::%{_count}%} to slot {_count} of player's inventory add 1 to {_count} set {sleeper::%player%::46} to player's helmet set {sleeper::%player%::47} to player's chestplate set {sleeper::%player%::48} to player's leggings set {sleeper::%player%::49} to player's shoes set {sleeper::%player%::45} to player's offhand stop