# Author Seq # LuckyBlocks v1.7 # Denizen Script to create LuckyBlock plugin LuckyBlockLoad: type: world events: on server start: - flag server "LuckyBlockStatus:false" LuckyBlocks_Commands: type: command name: luckyblock description: Commands for LuckyBlocks. - usage: /luckyblock + usage: /luckyblock <<>action<>> <<>player<>> <<>Quantity<>> permission: luckyblock.command script: - define arg_size - if %arg_size% == 0 { - run LuckyBlockInfo - determine fulfilled } else { - - if != ver && != help && != give && != stop && != start { + - if != ver && != give && != stop && != start { - narrate 'Unknown Argument(s)!' - determine fulfilled } else if == "stop" { - if == false { - narrate 'LuckyBlocks is already false!' - determine fulfilled } else { - narrate 'Stopping LuckyBlock.' - flag server "LuckyBlockStatus:false" - determine fulfilled } } else if == "start" { - if == true { - narrate 'LuckyBlocks is already true!' - determine fulfilled } else { - narrate 'Starting LuckyBlock.' - flag server "LuckyBlockStatus:true" - run BlockListener - determine fulfilled } } - else if == "help" { - - narrate 'Command Usage:' - - narrate '/luckyblock <<>Arguments<>>' - - narrate '/luckyblock Basic instructions for using LuckyBlocks in game.' - - narrate '/luckyblock ver Diplays current version of dLuckyBlock.' - - narrate '/luckyblock give <<>Player<>> <<>Qty<>> Gives LuckyBlock(s).' - - determine fulfilled - } else if == "ver" { - narrate 'LuckyBlock v1.7 by SeqSEE' - determine fulfilled } else if == "give" { - define Player ]||null> - if == null { - - give i@sponge qty:1 + - give i@sponge quantity:1 - determine fulfilled } else { - if == 0 { - - give i@sponge qty:1 player: + - give i@sponge quantity:1 player: - determine fulfilled } else { - if == null { - - give i@sponge qty:1 player: + - give i@sponge quantity:1 player: - determine fulfilled } else if matches number { - - give i@sponge qty: player: + - give i@sponge quantity: player: - determine fulfilled } else { - narrate " is not a valid quantity!" - determine fulfilled } } } } } LuckyBlockInfo: type: task debug: false script: - narrate "LuckyBlocks Active: " - wait 1 - narrate "Place LuckyBlocks and break them for surprises!" - wait 1 - narrate "Wet LuckyBlocks are more potent, so to speak." BlockListener: type: world debug: false events: on player breaks block: - if == true { - flag "BlockLocation:" - if == m@sponge { - run 'DryBroken' - determine passively "NOTHING" } else if == m@sponge,1 { - run 'WetBroken' - determine passively "NOTHING" } } else if == false { } DryBroken: type: task debug: false script: - random 8 - run Popcorn - - drop i@gold_ingot qty:32 + - drop i@gold_ingot quantity:32 - spawn zombie|zombie|zombie - - drop i@iron_sword|i@iron_chestplate|i@iron_leggings|i@iron_helmet| qty:1 + - drop i@iron_sword|i@iron_chestplate|i@iron_leggings|i@iron_helmet| quantity:1 - run SkeleBats - explode power:5 fire breakblocks - - drop i@iron_ingot qty:64 - - drop i@diamond qty:16 + - drop i@iron_ingot quantity:64 + - drop i@diamond quantity:16 WetBroken: type: task debug: false script: - random 9 - run ZombiesOnChickens - run BombBats - - drop i@diamond_block qty:1 - - drop i@gold_block qty:5 + - drop i@diamond_block quantity:1 + - drop i@gold_block quantity:5 - spawn creeper|creeper|creeper|creeper|creeper persistent - drop i@diamond_sword|i@diamond_chestplate|i@diamond_leggings|i@diamond_helmet| - run SpiderJokeys - run Skelombie - run BurriedAlive GiveLightDamage: type: task debug: false script: # Gives player light damage. - hurt 2.5 GiveMediumDamage: type: task debug: false script: # Gives player medium damage. - hurt 5 GiveHeavyDamage: type: task debug: false script: # Gives player heavy damage. - hurt 10 BombBats: type: task debug: false script: - repeat 6 { - mount e@primed_tnt|bat } SkeleBats: type: task debug: false script: - repeat 6 { - mount e@Skeleton|bat } SpiderJokeys: type: task debug: false script: - repeat 6 { - mount e@Skeleton|Spider } ZombiesOnChickens: type: task debug: false script: - repeat 6 { - mount e@Zombie|chicken } Skelombie: type: task debug: false script: - repeat 6 { - mount e@Skeleton|zombie } Popcorn: type: task debug: false script: - shoot origin: destination: script:GiveMediumDamage - narrate "Popcorn!" BurriedAlive: type: task debug: false script: - teleport - run GiveHeavyDamage - narrate "Burried Alive!" -