Sniper rifle in one command
by Duti 1517 5050 1
This command adds a sniper rifle to your world, i reccomend you to watch the video !
VIDEO
How to install
How to import this command into your world
First, you must give yourself a command block (If you are on a server, you must be 'OP'ed, and have access to /gamemode 1)
To get a command block, type
/give @p command_block in the chat.
Once you have a command block, right click it to open it's GUI.
Now, you must copy and paste the command from your browser into the game. Select the entire command from below, then right click and press 'copy'.
Next, go back to your minecraft world, and paste the command you just copied into the command block. There are a few different keys that may be used to do this, depending on your keyboard. The most common ones are 'CTRL + V', 'COMMAND + V', or 'STRG + V'
Finally, you can press done to exit the GUI, and execute the command block by powering it with a redstone block, a lever, or any thing you can get your grubby hands on. Just make sure you don't place it on top of the command block, or the machine will not be installed!
Show source commands
# This user did not upload the source commands!
summon FallingSand ~ ~1 ~ {Block:stone,Time:1,Passengers:[{id:FallingSand,Block:redstone_block,Time:1,Passengers:[{id:FallingSand,Block:activator_rail,Time:1,Passengers:[{id:MinecartCommandBlock,Command:gamerule commandBlockOutput false},{id:MinecartCommandBlock,Command:fill ~2 ~-3 ~-2 ~8 ~1 ~2 stained_hardened_clay 9 hollow},{id:MinecartCommandBlock,Command:fill ~2 ~-2 ~-2 ~8 ~ ~2 stained_glass 11 0 stained_hardened_clay},{id:MinecartCommandBlock,Command:"/tellraw @a [\"\",{\"text\":\"Click here to download the Recourse pack + the structure file !\",\"color\":\"red\",\"bold\":true,\"clickEvent\":{\"action\":\"open_url\",\"value\":\"http://www.mediafire.com/download/6vi62gm6d22uw6d/Guns.zip\"},\"hoverEvent\":{\"action\":\"show_text\",\"value\":{\"text\":\"\",\"extra\":[{\"text\":\"\"}]}}},{\"text\":\" Put the Sniper.nbt in the structure file and the Sniper rifle pack in the recource pack folder !\",\"color\":\"gold\",\"bold\":false}]"},{id:MinecartCommandBlock,Command:"/tellraw @a [\"\",{\"text\":\"Made by Duti !\",\"color\":\"blue\",\"bold\":true,\"clickEvent\":{\"action\":\"open_url\",\"value\":\"https://www.youtube.com/channel/UCQXiuGmB9Cmq1Yt4kLL2Heg\"},\"hoverEvent\":{\"action\":\"show_text\",\"value\":{\"text\":\"\",\"extra\":[{\"text\":\"Click here to go to my YouTube channel !\",\"color\":\"aqua\"}]}}}]"},{id:MinecartCommandBlock,Command:/summon FireworksRocketEntity ~ ~ ~ {LifeTime:20,FireworksItem:{id:fireworks,Count:1,tag:{Fireworks:{Explosions:[{Type:1,Flicker:1,Trail:1,Colors:[4534694],FadeColors:[11842740,6922751]},{Type:0,Flicker:1,Trail:1,Colors:[4934911],FadeColors:[4938495]},{Type:2,Flicker:1,Trail:1,Colors:[16777215],FadeColors:[10132122]},{Type:3,Flicker:1,Trail:1,Colors:[7721727],FadeColors:[16777215]}]}}}}},{id:MinecartCommandBlock,Command:"/give @p minecraft:spawn_egg 1 94 {display:{Name:\"CmdMarker\",Lore:[Place to spawn all the command blocks !]},EntityTag:{id:\"Squid\"}}"},{id:MinecartCommandBlock,Command:setblock ~1 ~-2 ~ wall_sign 4 0 {Text1:"{\\\"text\\\":\\\"Created by \\\",\\\"color\\\":\\\"blue\\\",\\\"clickEvent\\\":{\\\"action\\\":\\\"run_command\\\",\\\"value\\\":\\\"/summon FireworksRocketEntity ~ ~ ~ {LifeTime:20,FireworksItem:{id:fireworks,Count:1,tag:{Fireworks:{Explosions:[{Type:1,Flicker:1,Trail:1,Colors:[4534694],FadeColors:[11842740,6922751]},{Type:0,Flicker:1,Trail:1,Colors:[4934911],FadeColors:[4938495]},{Type:2,Flicker:1,Trail:1,Colors:[16777215],FadeColors:[10132122]},{Type:3,Flicker:1,Trail:1,Colors:[7721727],FadeColors:[16777215]}]}}}}\\\"},\\\"bold\\\":true}",Text2:"{\\\"text\\\":\\\"Duti\\\",\\\"color\\\":\\\"dark_blue\\\",\\\"clickEvent\\\":{\\\"action\\\":\\\"run_command\\\",\\\"value\\\":\\\"/tellraw @a [\\\\\\\"\\\\\\\",{\\\\\\\"text\\\\\\\":\\\\\\\"Made by Duti !\\\\\\\",\\\\\\\"color\\\\\\\":\\\\\\\"blue\\\\\\\",\\\\\\\"bold\\\\\\\":true,\\\\\\\"clickEvent\\\\\\\":{\\\\\\\"action\\\\\\\":\\\\\\\"open_url\\\\\\\",\\\\\\\"value\\\\\\\":\\\\\\\"https://www.youtube.com/channel/UCQXiuGmB9Cmq1Yt4kLL2Heg\\\\\\\"},\\\\\\\"hoverEvent\\\\\\\":{\\\\\\\"action\\\\\\\":\\\\\\\"show_text\\\\\\\",\\\\\\\"value\\\\\\\":{\\\\\\\"text\\\\\\\":\\\\\\\"\\\\\\\",\\\\\\\"extra\\\\\\\":[{\\\\\\\"text\\\\\\\":\\\\\\\"Click here to go to my YouTube channel !\\\\\\\",\\\\\\\"color\\\\\\\":\\\\\\\"aqua\\\\\\\"}]}}}]\\\"}}",Text3:"{\\\"text\\\":\\\"========================================\\\",\\\"color\\\":\\\"gray\\\"}",Text4:"{\\\"text\\\":\\\"\\\"}"}},{id:MinecartCommandBlock,Command:setblock ~1 ~-1 ~ wall_sign 4 0 {Text1:"{\\\"text\\\":\\\"Destroy \\\",\\\"color\\\":\\\"dark_red\\\",\\\"clickEvent\\\":{\\\"action\\\":\\\"run_command\\\",\\\"value\\\":\\\"/tellraw @a [\\\\\\\"\\\\\\\",{\\\\\\\"text\\\\\\\":\\\\\\\"Made by Duti !\\\\\\\",\\\\\\\"color\\\\\\\":\\\\\\\"blue\\\\\\\",\\\\\\\"bold\\\\\\\":true,\\\\\\\"clickEvent\\\\\\\":{\\\\\\\"action\\\\\\\":\\\\\\\"open_url\\\\\\\",\\\\\\\"value\\\\\\\":\\\\\\\"https://www.youtube.com/channel/UCQXiuGmB9Cmq1Yt4kLL2Heg\\\\\\\"},\\\\\\\"hoverEvent\\\\\\\":{\\\\\\\"action\\\\\\\":\\\\\\\"show_text\\\\\\\",\\\\\\\"value\\\\\\\":{\\\\\\\"text\\\\\\\":\\\\\\\"\\\\\\\",\\\\\\\"extra\\\\\\\":[{\\\\\\\"text\\\\\\\":\\\\\\\"Click here to go to my YouTube channel !\\\\\\\",\\\\\\\"color\\\\\\\":\\\\\\\"aqua\\\\\\\"}]}}},{\\\\\\\"text\\\\\\\":\\\\\\\" Thanks for using my command !\\\\\\\",\\\\\\\"color\\\\\\\":\\\\\\\"red\\\\\\\",\\\\\\\"bold\\\\\\\":true}]\\\"},\\\"bold\\\":true}",Text2:"{\\\"text\\\":\\\"Machine !\\\",\\\"color\\\":\\\"red\\\",\\\"clickEvent\\\":{\\\"action\\\":\\\"run_command\\\",\\\"value\\\":\\\"/summon FireworksRocketEntity ~ ~ ~ {LifeTime:20,FireworksItem:{id:fireworks,Count:1,tag:{Fireworks:{Explosions:[{Type:0,Flicker:1,Trail:1,Colors:[16745347],FadeColors:[16770634]},{Type:1,Flicker:1,Trail:1,Colors:[16738379],FadeColors:[11697210]},{Type:3,Flicker:1,Trail:1,Colors:[11026229],FadeColors:[16747599]},{Type:2,Flicker:1,Trail:1,Colors:[16731229],FadeColors:[16731241]}]}}}}\\\"}}",Text3:"{\\\"text\\\":\\\"===================================\\\"}",Text4:"{\\\"text\\\":\\\"\\\",\\\"clickEvent\\\":{\\\"action\\\":\\\"run_command\\\",\\\"value\\\":\\\"fill ~ ~-2 ~-2 ~7 ~2 ~2 air\\\"}}"}},{id:MinecartCommandBlock,Command:fill ~3 ~-2 ~-1 ~7 ~ ~1 chain_command_block 5},{id:MinecartCommandBlock,Command:setblock ~3 ~ ~1 repeating_command_block 5},{id:MinecartCommandBlock,Command:setblock ~3 ~ ~ chain_command_block 3},{id:MinecartCommandBlock,Command:fill ~7 ~ ~ ~4 ~ ~ chain_command_block 4},{id:MinecartCommandBlock,Command:setblock ~7 ~ ~-1 chain_command_block 3},{id:MinecartCommandBlock,Command:setblock ~3 ~-1 ~-1 chain_command_block 1},{id:MinecartCommandBlock,Command:setblock ~4 ~-1 ~-1 repeating_command_block 4},{id:MinecartCommandBlock,Command:fill ~7 ~-1 ~-1 ~5 ~-1 ~-1 chain_command_block 4},{id:MinecartCommandBlock,Command:setblock ~7 ~-1 ~ chain_command_block 2},{id:MinecartCommandBlock,Command:setblock ~4 ~-1 ~ repeating_command_block 5},{id:MinecartCommandBlock,Command:setblock ~3 ~-1 ~1 chain_command_block 2},{id:MinecartCommandBlock,Command:setblock ~4 ~-1 ~1 chain_command_block 12},{id:MinecartCommandBlock,Command:setblock ~5 ~-1 ~1 chain_command_block 4},{id:MinecartCommandBlock,Command:setblock ~6 ~-1 ~1 repeating_command_block 4},{id:MinecartCommandBlock,Command:setblock ~7 ~-1 ~1 chain_command_block 4},{id:MinecartCommandBlock,Command:setblock ~7 ~-2 ~1 chain_command_block 1},{id:MinecartCommandBlock,Command:setblock ~3 ~-2 ~ chain_command_block 3},{id:MinecartCommandBlock,Command:fill ~7 ~-2 ~ ~4 ~-2 ~ chain_command_block 4},{id:MinecartCommandBlock,Command:setblock ~7 ~-2 ~-1 chain_command_block 3},{id:MinecartCommandBlock,Command:setblock ~3 ~-2 ~-1 repeating_command_block 5},{id:MinecartCommandBlock,Command:blockdata ~4 ~ ~1 {auto:1,Command:/tp @e[type=Squid,name=CmdMarker] ~ ~-500 ~}},{id:MinecartCommandBlock,Command:blockdata ~3 ~ ~1 {auto:1,Command:"/execute @e[type=Squid,name=CmdMarker] ~ ~ ~ /setblock ~ ~ ~ structure_block 0 0 {metadata:\\\"\\\",mirror:\\\"NONE\\\",ignoreEntities:1b,powered:0b,seed:0L,author:\\\"Duti_YT\\\",rotation:\\\"NONE\\\",posX:0,mode:\\\"LOAD\\\",posY:0,sizeX:19,posZ:0,integrity:1.0f,showair:0b,name:\\\"Sniper\\\",id:\\\"Structure\\\",sizeY:5,sizeZ:19,showboundingbox:1b}"}},{id:MinecartCommandBlock,Command:blockdata ~3 ~ ~ {auto:1,Command:/scoreboard players reset @a GIKill}},{id:MinecartCommandBlock,Command:blockdata ~4 ~ ~ {auto:1,Command:/execute @a[score_GIKill_min=1] ~ ~ ~ /kill @e[tag=GunR]}},{id:MinecartCommandBlock,Command:blockdata ~5 ~ ~ {auto:1,Command:/execute @a[score_GIKill_min=1] ~ ~ ~ /kill @e[tag=GunP]}},{id:MinecartCommandBlock,Command:blockdata ~6 ~ ~ {auto:1,Command:/execute @a[score_GIKill_min=1] ~ ~ ~ /kill @e[tag=GunII]}},{id:MinecartCommandBlock,Command:blockdata ~7 ~ ~ {auto:1,Command:/execute @e[tag=GunP] ~ ~ ~ /execute @e[tag=GunR,r=1] ~ ~ ~ /execute @e[tag=GunII,r=1] ~ ~ ~ /scoreboard players set @a GIKill 1}},{id:MinecartCommandBlock,Command:blockdata ~7 ~ ~-1 {auto:1,Command:/scoreboard objectives add GIKill dummy}},{id:MinecartCommandBlock,Command:blockdata ~6 ~ ~-1 {auto:1,Command:"/execute @e[tag=GunP] ~ ~ ~ /execute @e[tag=GunR,r=1] ~ ~ ~ /execute @e[tag=GunII,r=1] ~ ~ ~ give @p minecraft:stone_pressure_plate 64 0 {display:{Name:\\\"Sniper Rifle Bullet\\\"}}"}},{id:MinecartCommandBlock,Command:blockdata ~5 ~ ~-1 {auto:1,Command:"/execute @e[tag=GunP] ~ ~ ~ /execute @e[tag=GunR,r=1] ~ ~ ~ /execute @e[tag=GunII,r=1] ~ ~ ~ give @p minecraft:carrot_on_a_stick 1 0 {Unbreakable:1,display:{Name:\\\"Sniper Rifle\\\"}}"}},{id:MinecartCommandBlock,Command:blockdata ~4 ~ ~-1 {auto:1,Command:/execute @e[tag=GunP] ~ ~ ~ /execute @e[tag=GunR,r=1] ~ ~ ~ /execute @e[tag=GunII,r=1] ~ ~ ~ /particle endRod ~ ~0.3 ~ 0.3 0.3 0.3 0.001 10 force}},{id:MinecartCommandBlock,Command:blockdata ~3 ~ ~-1 {auto:1,Command:"/scoreboard players tag @e[type=Item] add GunII {Item:{id:\\\"minecraft:iron_ingot\\\",Count:16b}}"}},{id:MinecartCommandBlock,Command:blockdata ~3 ~-1 ~-1 {auto:1,Command:"/scoreboard players tag @e[type=Item] add GunR {Item:{id:\\\"minecraft:redstone\\\",Count:6b}}"}},{id:MinecartCommandBlock,Command:blockdata ~4 ~-1 ~-1 {auto:1,Command:"/scoreboard players tag @e[type=Item] add GunP {Item:{id:\\\"minecraft:gunpowder\\\",Count:10b}}"}},{id:MinecartCommandBlock,Command:blockdata ~5 ~-1 ~-1 {auto:1,Command:/entitydata @e[type=Snowball,tag=GUN_Bullet] {NoGravity:1}}},{id:MinecartCommandBlock,Command:blockdata ~6 ~-1 ~-1 {auto:1,Command:execute @e[type=Snowball,tag=GUN_Bullet] ~ ~ ~ effect @e[r=3] minecraft:instant_damage 1 6 true}},{id:MinecartCommandBlock,Command:blockdata ~7 ~-1 ~-1 {auto:1,Command:scoreboard players tag @a[tag=fireGUN] remove fireGUN}},{id:MinecartCommandBlock,Command:blockdata ~7 ~-1 ~ {auto:1,Command:"clear @a[tag=fireGun] minecraft:stone_pressure_plate 1 {display:{Name:\\\"Sniper Rifle Bullet\\\"}}"}},{id:MinecartCommandBlock,Command:blockdata ~6 ~-1 ~ {auto:1,Command:scoreboard players set @a[tag=fireGUN] GUNCooldown 40}},{id:MinecartCommandBlock,Command:blockdata ~5 ~-1 ~ {auto:1,Command:tp @a[tag=fireGUN] ~ ~ ~ ~ ~-20}},{id:MinecartCommandBlock,Command:blockdata ~4 ~-1 ~ {auto:1,Command:/execute @a[tag=fireGUN] ~ ~ ~ playsound minecraft:block.anvil.land player @a}},{id:MinecartCommandBlock,Command:blockdata ~3 ~-1 ~ {auto:1,Command:scoreboard players set @a[score_fireGUN_min=1] fireGUN 0}},{id:MinecartCommandBlock,Command:blockdata ~3 ~-1 ~1 {auto:1,Command:scoreboard players remove @a[score_GUNCooldown_min=1] GUNCooldown 1}},{id:MinecartCommandBlock,Command:blockdata ~4 ~-1 ~1 {auto:1,Command:/execute @e[type=ArmorStand,name=FireGUN] ~ ~ ~ blockdata ~ ~-1 ~ {auto:1} }},{id:MinecartCommandBlock,Command:blockdata ~5 ~-1 ~1 {auto:1,Command:execute @a[score_fireGUN_min=1,tag=holdingGUN] ~ ~ ~ scoreboard players tag @a[tag=hasGUNBullet,score_GUNCooldown=0,r=0,c=1] add fireGUN}},{id:MinecartCommandBlock,Command:blockdata ~6 ~-1 ~1 {auto:1,Command:/scoreboard players add @a[tag=holdingGUN] GUNCooldown 0}},{id:MinecartCommandBlock,Command:blockdata ~7 ~-1 ~1 {auto:1,Command:scoreboard players set @a[score_reloadGUN_min=60] reloadGUN 0}},{id:MinecartCommandBlock,Command:blockdata ~7 ~-2 ~1 {auto:1,Command:"give @a[score_reloadGUN_min=60] minecraft:stone_pressure_plate 3 0 {display:{Name:\\\"Sniper Rifle Bullet\\\"}}"}},{id:MinecartCommandBlock,Command:blockdata ~6 ~-2 ~1 {auto:1,Command:"clear @a[score_reloadGUN_min=60] minecraft:iron_ingot 1 0 {display:{Name:\\\"Sniper Rifle Magazine\\\"}}"}},{id:MinecartCommandBlock,Command:blockdata ~5 ~-2 ~1 {auto:1,Command:scoreboard players add @a[score_reloadGUN_min=1] reloadGUN 1}},{id:MinecartCommandBlock,Command:blockdata ~4 ~-2 ~1 {auto:1,Command:execute @a[score_reloadGUN_min=1,score_reloadGUN=1] ~ ~ ~ playsound minecraft:block.note.hat @a}},{id:MinecartCommandBlock,Command:blockdata ~3 ~-2 ~1 {auto:1,Command:execute @a[tag=holdingGUN] ~ ~ ~ execute @a[tag=!hasGUNBullet,r=0,c=1] ~ ~ ~ scoreboard players set @a[tag=hasGUNMagazine,score_reloadGUN=0,r=0,c=1] reloadGUN 1}},{id:MinecartCommandBlock,Command:blockdata ~3 ~-2 ~ {auto:1,Command:scoreboard players add @a[tag=holdingGUN] reloadGUN 0}},{id:MinecartCommandBlock,Command:blockdata ~4 ~-2 ~ {auto:1,Command:"scoreboard players tag @a add holdingGUN {SelectedItem:{id:\\\"minecraft:carrot_on_a_stick\\\",tag:{display:{Name:\\\"Sniper Rifle\\\"}}}}"}},{id:MinecartCommandBlock,Command:blockdata ~5 ~-2 ~ {auto:1,Command:scoreboard players tag @a[tag=holdingGUN] remove holdingGUN}},{id:MinecartCommandBlock,Command:blockdata ~6 ~-2 ~ {auto:1,Command:"scoreboard players tag @a add hasGUNBullet {Inventory:[{id:\\\"minecraft:stone_pressure_plate\\\",Damage:0s,tag:{display:{Name:\\\"Sniper Rifle Bullet\\\"}}}]}"}},{id:MinecartCommandBlock,Command:blockdata ~7 ~-2 ~ {auto:1,Command:scoreboard players tag @a[tag=hasGUNBullet] remove hasGUNBullet}},{id:MinecartCommandBlock,Command:blockdata ~7 ~-2 ~-1 {auto:1,Command:"scoreboard players tag @a add hasGUNMagazine {Inventory:[{id:\\\"minecraft:iron_ingot\\\",Damage:0s,tag:{display:{Name:\\\"Sniper Rifle Magazine\\\"}}}]}"}},{id:MinecartCommandBlock,Command:blockdata ~6 ~-2 ~-1 {auto:1,Command:scoreboard players tag @a[tag=hasGUNMagazine] remove hasGUNMagazine}},{id:MinecartCommandBlock,Command:blockdata ~5 ~-2 ~-1 {auto:1,Command:scoreboard objectives add GUNCooldown dummy}},{id:MinecartCommandBlock,Command:blockdata ~4 ~-2 ~-1 {auto:1,Command:scoreboard objectives add reloadGUN dummy}},{id:MinecartCommandBlock,Command:blockdata ~3 ~-2 ~-1 {auto:1,Command:scoreboard objectives add fireGUN stat.useItem.minecraft.carrot_on_a_stick}},{id:MinecartCommandBlock,Command:setblock ~ ~ ~1 command_block 0 0 {Command:fill ~ ~-3 ~-1 ~ ~ ~ air}},{id:MinecartCommandBlock,Command:setblock ~ ~-1 ~1 redstone_block},{id:MinecartCommandBlock,Command:kill @e[type=MinecartCommandBlock,r=1]}]}]}]}