/ ========== STUFF ==========

ID=sponge@luck=0
ID=tnt,amount=8@luck=1
ID=obsidian,amount=14@luck=1
ID=enchanting_table@luck=2
ID=end_portal_frame,amount=#rand(2,6)@luck=2
ID=dragon_egg,amount=7@luck=1
ID=ender_chest,amount=10@luck=0
ID=beacon,amount=100@luck=2
ID=dropper,amount=80@luck=0
ID=hay_block,amount=80@luck=0
ID=gold_ore,amount=#rand(80,160)@luck=1
ID=iron_ore,amount=#rand(160,320)@luck=1
ID=diamond_ore,amount=#rand(50,100)@luck=1
ID=coal_ore,amount=#rand(320,640)@luck=0
ID=grass,amount=#rand(320,640)@luck=0
ID=cobblestone,amount=#rand(320,640)@luck=0
ID=diamond,amount=#rand(320,640)@luck=0
ID=diamond_boots,amount=#rand(320,640)@luck=0
ID=diamond_chestplate,amount=#rand(320,640)@luck=0
ID=diamond_ore,amount=#rand(320,640)@luck=0
ID=redstone_ore,amount=#rand(320,640)@luck=0
ID=quartz_ore,amount=#rand(320,640)@luck=0
ID=iron_ore,amount=#rand(320,640)@luck=0
ID=writable_book,amount=#rand(320,640)@luck=1
ID=quartz,amount=#rand(320,640)@luck=0
ID=double_stone_slab,amount=#rand(320,640)@luck=-2
ID=lava,amount=#rand(320,640)@luck=2
ID=gold_ore,amount=#rand(320,640)@luck=1
ID=lapis_ore,amount=#rand(320,640)@luck=2
ID=lapis_block,amount=#rand(320,640)@luck=0
ID=web,amount=#rand(320,640)@luck=1
ID=bed,amount=#rand(320,640)@luck=1
ID=emerald_ore,amount=#rand(320,640)@luck=2
ID=emerald,amount=#rand(320,640)@luck=0
ID=emerald_block,amount=#rand(320,640)@luck=2
ID=bone,amount=#rand(16,48)@luck=0
ID=slime_ball,amount=16@luck=0
ID=ink_sack,amount=3@luck=-1
ID=384,amount=64@luck=2
ID=poisonous_potato@luck=-1
ID=name_tag,amount=4@luck=1
ID=gold_ingot,amount=#rand(8,16)@luck=1
ID=stick@luck=-1
ID=painting,amount=4@luck=0
ID=saddle,amount=10@luck=0
ID=cake@luck=0
ID=rotten_flesh@luck=-1
ID=nether_star@luck=2
ID=red_flower,NBTTag=(display=(Name="$aJen's Rose"))@luck=0
ID=pumpkin,amount=#rand(5,7)@luck=1
ID=chest,amount=#rand(5,7)@luck=0
ID=gold,amount=#rand(5,7)@luck=2
ID=piston,amount=#rand(5,7)@luck=1
ID=golden_apple,amount=#rand(10,70)@luck=1

/ chests
type=block,ID=chest,tileEntity=(Items=#chestVillageBlacksmith)@luck=0
type=block,ID=chest,tileEntity=(Items=#chestBonusChest)@luck=1
type=block,ID=chest,tileEntity=(Items=#chestDungeonChest)@luck=1
type=block,ID=chest,tileEntity=(Items=#chest(contents=[(id=iron_ingot,maxAmount=8,weight=10),(id=gold_ingot,maxAmount=4,weight=10),(id=diamond,maxAmount=4,weight=10),(id=emerald,maxAmount=4,weight=10),(id=dye,Damage=4,maxAmount=4,weight=10),(id=lucky:lucky_block_rainbow,maxAmount=2,weight=10),(id=golden_apple,maxAmount=2,weight=10),(id=golden_apple,Damage=1,maxAmount=2,weight=10)],maxTotalAmount=12))@luck=2

/ ========== BLOCK ==========

/ores
group(ID=coal_ore,amount=#rand(320,640);ID=quartz_ore,amount=#rand(160,320);ID=diamond_ore,amount=#rand(80,160);ID=emerald_ore,amount=#rand(80,160);ID=redstone_ore,amount=#rand(8,16);ID=lapis_ore,amount=#rand(8,16);type=entity,ID=FireworksRocketEntity,NBTTag=(LifeTime=20,FireworksItem=(id=fireworks,tag=#randFireworksRocket)),amount=5,posOffset=#circleOffset(0,2))@luck=2

/explosion and evil
type=explosion,radius=10,fire=false
type=explosion,radius=20,fire=true
type=explosion,radius=15,fire=true
/ ========= ITEMS ==========


/ bookshelves and books
group(ID=bookshelf,amount=#rand(6,12);ID=book,amount=#rand(8,16))@luck=0
/ pumpkins and jack o'lanterns
group(ID=pumpkin,amount=#rand(8,16);ID=lit_pumpkin,amount=#rand(8,16))@luck=0
/ golden apples
group(ID=golden_apple,amount=#rand(2,4);ID=golden_apple,amount=#rand(1,2),damage=1)@luck=2
/ buckets
group(ID=bucket,amount=#rand(1,2);ID=water_bucket,amount=#rand(1,2);ID=lava_bucket,amount=#rand(1,2);ID=milk_bucket,amount=#rand(1,2))@luck=0

type=block,ID=diamond_block,damage=#rand(0,8),posOffset=#circleOffset(0,5),amount=64,reinitialize=true@luck=0
type=block,ID=emerald_block_block,damage=#rand(0,8),posOffset=#circleOffset(0,5),amount=64,reinitialize=true@luck=0
type=block,ID=beacon,damage=#rand(0,8),posOffset=#circleOffset(0,5),amount=64,reinitialize=true@luck=0
type=block,ID=dragon_egg,damage=#rand(0,8),posOffset=#circleOffset(0,5),amount=64,reinitialize=true@luck=0
type=block,ID=lava,damage=#rand(0,8),posOffset=#circleOffset(0,5),amount=64,reinitialize=true@luck=0
type=block,ID=gravel,damage=#rand(0,8),posOffset=#circleOffset(0,5),amount=64,reinitialize=true@luck=0

/lucky potion
ID=potion,damage=8195,NBTTag=(CustomPotionEffects=#luckyPotionEffects,display=(Name="$e$lSuper++ OverPowered Lucky Potion"))@luck=2
/unlucky potion
ID=potion,damage=16428,NBTTag=(CustomPotionEffects=#unluckyPotionEffects,display=(Name="$e$lSuper++ OverUnPoweres Potion"))@luck=1

/lucky and unlucky potions (slightly less overpowered)
ID=potion,amount=#rand(1,3),damage=8193,reinitialize=true,NBTTag=(CustomPotionEffects=[(Id=6,Amplifier=#rand(0,1),Duration=1),(Id=#randList(12,13,14,16),Amplifier=0,Duration=#rand(1200,2400)),(Id=#randList(1,3,5,10),Amplifier=#rand(0,1),Duration=#rand(1200,2400)),(Id=#randList(8,11,22,23),Amplifier=#rand(0,1),Duration=#rand(1200,2400))],display=(Name="$e$lLess OP Lucky Potion"))@luck=1
ID=potion,amount=#rand(1,3),damage=16457,reinitialize=true,NBTTag=(CustomPotionEffects=[(Id=7,Amplifier=#rand(0,1),Duration=1),(Id=#randList(9,15),Amplifier=0,Duration=#rand(600,1800)),(Id=#randList(2,17,19),Amplifier=#rand(0,1),Duration=#rand(600,1800)),(Id=#randList(4,18,20),Amplifier=#rand(0,1),Duration=#rand(600,1800))],display=(Name="$e$lLess OP Unlucky Potion"))@luck=1


ID=diamond_axe,NBTTag=(ench=[(id=32,lvl=200),(id=33,lvl=100)],Unbreakable=true,display=(Name="Hello!!!",Lore=["Give it to me!"]))@luck=2
ID=diamond_hoe,NBTTag=(Unbreakable=false,display=(Name="$9Come On",Lore=["Lets go farminng!"]))@luck=2

/ jukebox
group(type=block,ID=jukebox;type=entity,ID=Item,posOffsetY=1,NBTTag=(Item=(Count=1,id=#randList(record_cat,record_blocks,record_chirp,record_far,record_mall,record_mellohi,record_stal,record_strad,record_ward,record_wait))))@luck=0

/ golden apples
group(ID=golden_apple,amount=#rand(30,40);ID=golden_apple,amount=#rand(10,20),damage=1)@luck=2

/ ========== ENTITIES ==========
/ thrown exp bottles
type=entity,ID=ThrownExpBottle,NBTTag=(Motion=#randLaunchMotion),amount=#rand(320,640)@luck=2

/ pet wolves
group(type=entity,ID=Wolf,amount=#rand(5,10),posOffset=#circleOffset(3),NBTTag=(CollarColor=#rand(0,14),Owner=#pName,Sitting=1,CustomName="#pName's Wolf");type=particle,ID="heart",size=(2,0,2),particleAmount=20)@luck=1
/ pet cats
group(type=entity,ID=Ozelot,amount=#rand(5,10),posOffset=#circleOffset(3),NBTTag=(CatType=#rand(0,3),Owner=#pName,Sitting=1,CustomName="#pName's Kitty");type=particle,ID="heart",size=(2,0,2),particleAmount=20)@luck=1
/ pet rabbits
group(type=entity,ID=Rabbit,amount=#rand(5,10),posOffset=#circleOffset(3),NBTTag=(RabbitType=#rand(0,5),Owner=#pName,Sitting=1);type=particle,ID="heart",size=(2,0,2),particleAmount=20)@luck=1


/ lightning creeper
group(type=difficulty,ID=hard;type=entity,ID=Creeper;type=entity,ID=LightningBolt)@luck=-2
/ giant
group(type=difficulty,ID=hard;type=entity,ID=Giant)@luck=-2
/ wither
group(type=difficulty,ID=hard;type=entity,ID=WitherBoss)@chance=0.1@luck=-2
/ ghast
group(type=difficulty,ID=hard;type=entity,ID=Ghast)@chance=0.2@luck=-2
/ elder guardian
group(type=difficulty,ID=hard;type=entity,ID=Guardian,NBTTag=(Elder=1))@luck=-2
/ killer rabbit
group(type=difficulty,ID=hard;type=entity,ID=Rabbit,NBTTag=(RabbitType=99))@luck=-1
/ lightning creeper
group(type=difficulty,ID=hard;type=entity,ID=Creeper;type=entity,ID=LightningBolt)@luck=-2
/ bob zombie
group(type=difficulty,ID=hard;type=entity,ID=Zombie,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lBob",CustomNameVisible=true))@luck=-2

type=entity,ID=LavaSlime,NBTTag=(Size=#rand(6,7),Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lSally",CustomNameVisible=true);type=entity,ID=PigZombie,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lPeter",CustomNameVisible=true); \
type=entity,ID=Slime,NBTTag=(Size=#rand(2,3),Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lMolly",CustomNameVisible=true);type=entity,ID=Witch,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lDinnerbone",CustomNameVisible=true); \
type=entity,ID=Giant,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lCharles",CustomNameVisible=true);type=entity,ID=Skeleton,NBTTag=(Equipment=[(id=bow,Count=1,tag=(ench=#luckyBowEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lBob's Mom",CustomNameVisible=true);  \
type=entity,ID=Zombie,NBTTag=(Equipment=[(id=bow,Count=1,tag=(ench=#luckyBowEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lSmith",CustomNameVisible=true);type=entity,ID=Spider,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lLink",CustomNameVisible=true);  \
type=entity,ID=Blaze,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lBilly",CustomNameVisible=true);type=entity,ID=Ghast,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lLily",CustomNameVisible=true);  \
type=entity,ID=Skeleton,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lBilly",CustomNameVisible=true);type=entity,ID=Ghast,NBTTag=(Equipment=[(id=diamond_sword,Count=1,tag=(ench=#luckySwordEnchantments)),(id=diamond_helmet,Count=1,tag=(ench=#luckyHelmetEnchantments)),(id=diamond_chestplate,Count=1,tag=(ench=#luckyChestplateEnchantments)),(id=diamond_leggings,Count=1,tag=(ench=#luckyLeggingsEnchantments)),(id=diamond_boots,Count=1,tag=(ench=#luckyBootsEnchantments))],DropChances=[#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f,#randList(0,2)f],CustomName="$e$lLily",CustomNameVisible=true);  \

/ ========== STRUCTURES ==========

/ traps
type=structure,ID=anvil_trap,pos=#pPos,rotation=#pDirect@luck=-2
type=structure,ID=lava_trap,pos=#pPos,rotation=#pDirect@luck=-2
type=structure,ID=water_trap,pos=#pPos@luck=-2  
type=structure,ID=pit_trap,pos=#pPos@luck=-2

/ explosion
group(type=difficulty,ID=hard;type=explosion,radius=6)@chance=0.5@luck=-2

/ wishing wells
group(type=structure,ID=spiral_well;type=message,ID="A wishing well? Maybe you should throw in a coin...";type=command,ID="/gamerule commandBlockOutput false";type=command,ID="/give #pName lootplusplus:spiral.gold_coin 1 0 {display:{Name:\"$6Coin\"}}";type=block,ID=lucky:lucky_block_spiral,posY=#bPosY-3,NBTTag=(Drops=["group(type=message,ID=\"$bYour wish came true!\";type=block,ID=air,posY='#'bPosY+3;type=block,ID=beacon,posY='#'bPosY+2;type=entity,ID=FireworksRocketEntity,NBTTag=(LifeTime=20,FireworksItem=(id=fireworks,tag='#'randFireworksRocket)),amount=20,posY='#'bPosY+3,posOffset='#'circleOffset(2);ID=gold_ingot,amount=#rand(20,30),posY='#'bPosY+10,posOffset='#'circleOffset(2);ID=diamond,amount=#rand(20,30),posY='#'bPosY+10,posOffset='#'circleOffset(2);ID=emerald,amount=#rand(20,30),posY='#'bPosY+10,posOffset='#'circleOffset(2);ID=dye,damage=4,amount=#rand(20,30),posY='#'bPosY+10,posOffset='#'circleOffset(2);ID=redstone,amount=#rand(32,64),posY='#'bPosY+10,posOffset='#'circleOffset(2))"]))@luck=2
group(type=structure,ID=spiral_well;type=message,ID="A wishing well? Maybe you should throw in a coin...";type=command,ID="/gamerule commandBlockOutput false";type=command,ID="/give #pName lootplusplus:spiral.gold_coin 1 0 {display:{Name:\"$6Coin\"}}";type=block,ID=lucky:lucky_block_spiral,posY=#bPosY-3,NBTTag=(Drops=["group(type=message,ID=\"$4Your death wish came true!\";type=block,ID=air,posY='#'bPosY+3;type=block,ID=beacon,posY='#'bPosY+2;type=sound,ID=game.tnt.primed;type=entity,ID=PrimedTnt,NBTTag=(Fuse=50b,Motion='#'randLaunchMotion),posY='#'bPosY+7,amount=20)"]))@luck=-2

/ bouncy castle
group(type=command,ID="/gamerule commandBlockOutput false";type=command,ID="/playsound mob.slime.big #pName ~ ~ ~ 1.0 0.6";type=structure,ID=bouncing_castle,pos=#pPos,rotation=#pDirect)
