Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $${
- IF(@&randomchest = "true")
- UnSet(@&randomchest)
- ECHO(/particle largeexplode %@#rcx% %@#rcy% %@#rcz% 1 1 1 0.01 100)
- ECHO(/setblock %@#rcx% %@#rcy% %@#rcz% air 0)
- Log(&cDisabled random chest.)
- Stop("APOSTROPHE")
- ENDIF
- Set(@&randomchest,"true")
- PROMPT(&location,$$?,"Location of the event?")
- IF(&location = "")
- Stop()
- ENDIF
- ECHO(/tellraw @a [""\,{"text":"> Random chest event happening at %&location%!"\,"color":"yellow"\,bold:true}])
- Log(&aEnabled random chest.)
- @#rcx1 = %XPOS%
- @#rcx2 = %XPOS%
- @#rcy1 = %YPOS%
- @#rcy2 = %YPOS%
- @#rcz1 = %ZPOS%
- @#rcz2 = %ZPOS%
- Inc(@#rcx1,5)
- Dec(@#rcx2,5)
- Inc(@#rcy1,5)
- Inc(@#rcz1,5)
- Dec(@#rcz2,5)
- UnSet(&on)
- DO
- Wait(5)
- IF(&on = "yes")
- ECHO(/setblock %@#rcx% %@#rcy% %@#rcz% air 0)
- ECHO(/particle explode %@#rcx% %@#rcy% %@#rcz% 1 1 1 0.01 100)
- ENDIF
- RANDOM(@#rcx,%@#rcx1%,%@#rcx2%)
- RANDOM(@#rcy,%@#rcy1%,%@#rcy2%)
- RANDOM(@#rcz,%@#rcz1%,%@#rcz2%)
- RANDOM(#slot,0,26)
- RANDOM(#count,1,5)
- RANDOM(#id)
- DO
- RANDOM(#pick,1,2)
- IF(#pick = 1)
- RANDOM(#id,1,197)
- ELSE
- RANDOM(#id,256,431)
- ENDIF
- IFMATCHES(%#id%,^7$|^8$|^9$|^10$|^11$|^19$|^31$|^32$|^34$|^43$|^51$|^52$|^55$|^59$|^62$|^63$|^68$|^75$|^83$|^90$|^94$|^97$|^104$|^105$|^119$|^120$|^122$|^124$|^132$|^137$|^138$|^141$|^142$|^150$|^166$|^175$|^177$|^373$|^383$|^399$|^401$|^403$|^422$|^426)
- Set(&allow,"false")
- ELSE
- Set(&allow,"true")
- ENDIF
- WHILE(&allow = "false")
- Set(&on,"yes")
- ECHO(/setblock %@#rcx% %@#rcy% %@#rcz% chest 0 replace {Items:[{id:%#id%\,Slot:%#slot%\,Count:%#count%}]})
- WHILE(true)
- }$$
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement