Need to make target selector only select one entity The 2019 Stack Overflow Developer Survey Results Are In Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Is there a way to constantly track one players jumping activityAll Minecraft target selector argumentsDifferent commands select different entities (with the same target selector)Summoning enderpearls on arrows with custom name shot by a playerWhy won't my arrow gain an objective?Is there any way to make scoreboard objectives Universal?Target Selector Argument problemMinecraft 1.13 execute command on all endermen on the outer end islandsHow to make a score be recorded as team?My arrows aren't being executed at by a looping function/command block

Arduino Pro Micro - switch off LEDs

Why can't devices on different VLANs, but on the same subnet, communicate?

He got a vote 80% that of Emmanuel Macron’s

Does Parliament need to approve the new Brexit delay to 31 October 2019?

how can a perfect fourth interval be considered either consonant or dissonant?

The following signatures were invalid: EXPKEYSIG 1397BC53640DB551

Didn't get enough time to take a Coding Test - what to do now?

Scientific Reports - Significant Figures

What information about me do stores get via my credit card?

How is simplicity better than precision and clarity in prose?

Did God make two great lights or did He make the great light two?

Can smartphones with the same camera sensor have different image quality?

How should I replace vector<uint8_t>::const_iterator in an API?

Install many applications using one command

Would an alien lifeform be able to achieve space travel if lacking in vision?

Difference between "generating set" and free product?

In horse breeding, what is the female equivalent of putting a horse out "to stud"?

"... to apply for a visa" or "... and applied for a visa"?

Can the DM override racial traits?

Grover's algorithm - DES circuit as oracle?

How to delete random line from file using Unix command?

ELI5: Why do they say that Israel would have been the fourth country to land a spacecraft on the Moon and why do they call it low cost?

The variadic template constructor of my class cannot modify my class members, why is that so?

How did the audience guess the pentatonic scale in Bobby McFerrin's presentation?



Need to make target selector only select one entity



The 2019 Stack Overflow Developer Survey Results Are In
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Is there a way to constantly track one players jumping activityAll Minecraft target selector argumentsDifferent commands select different entities (with the same target selector)Summoning enderpearls on arrows with custom name shot by a playerWhy won't my arrow gain an objective?Is there any way to make scoreboard objectives Universal?Target Selector Argument problemMinecraft 1.13 execute command on all endermen on the outer end islandsHow to make a score be recorded as team?My arrows aren't being executed at by a looping function/command block



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








-1















I'm writing a function for a datapack in Minecraft. After /reloading, /function couldn't find the function, so I pasted each line into Minecraft to check for syntax and other errors. I found that the problem was in the commands that store the aoecloud's position into a scoreboard, and also in the ones that take those values and place them into the Motion nbt for an arrow. The issue is that according to Minecraft, only one entity is allowed in the target selector while my target selector is selecting multiple. I tried using a customName to fix this problem but it didn't work. How can I get the target selector to select the arrow/aoecloud created at the top of the function and not give me errors?



summon minecraft:arrow ^ ^ ^1 Tags:["sniperbullet"], CustomName:""sniperbullet""
summon minecraft:area_effect_cloud 0 0 0 Tags:["sniperaoecloud"], CustomName:""sniperaoecloud""
execute as @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] at @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] rotated as @a[scores=gunshots=1..,nbt=SelectedItem:tag:display:Name:""text":"Sniper Rifle""] run tp @s ^ ^ ^1

scoreboard objectives add sniperx dummy
scoreboard objectives add snipery dummy
scoreboard objectives add sniperz dummy

execute store result score @s sniperx run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[0] 10000
execute store result score @s snipery run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[1] 10000
execute store result score @s sniperz run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[2] 10000

execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[0] double 0.0001 run scoreboard players get @s sniperx
execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[1] double 0.0001 run scoreboard players get @s snipery
execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[2] double 0.0001 run scoreboard players get @s sniperz

scoreboard objectives remove sniperx
scoreboard objectives remove snipery
scoreboard objectives remove sniperz

scoreboard players set @e gunshots 0
scoreboard players set @s reloadSniper 50


FYI the goal of this function is to spawn an arrow in front of a player and get it to fly in the direction they are looking. Also, if you catch any other errors with my code please point them out to me.










share|improve this question







New contributor




Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.


























    -1















    I'm writing a function for a datapack in Minecraft. After /reloading, /function couldn't find the function, so I pasted each line into Minecraft to check for syntax and other errors. I found that the problem was in the commands that store the aoecloud's position into a scoreboard, and also in the ones that take those values and place them into the Motion nbt for an arrow. The issue is that according to Minecraft, only one entity is allowed in the target selector while my target selector is selecting multiple. I tried using a customName to fix this problem but it didn't work. How can I get the target selector to select the arrow/aoecloud created at the top of the function and not give me errors?



    summon minecraft:arrow ^ ^ ^1 Tags:["sniperbullet"], CustomName:""sniperbullet""
    summon minecraft:area_effect_cloud 0 0 0 Tags:["sniperaoecloud"], CustomName:""sniperaoecloud""
    execute as @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] at @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] rotated as @a[scores=gunshots=1..,nbt=SelectedItem:tag:display:Name:""text":"Sniper Rifle""] run tp @s ^ ^ ^1

    scoreboard objectives add sniperx dummy
    scoreboard objectives add snipery dummy
    scoreboard objectives add sniperz dummy

    execute store result score @s sniperx run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[0] 10000
    execute store result score @s snipery run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[1] 10000
    execute store result score @s sniperz run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[2] 10000

    execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[0] double 0.0001 run scoreboard players get @s sniperx
    execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[1] double 0.0001 run scoreboard players get @s snipery
    execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[2] double 0.0001 run scoreboard players get @s sniperz

    scoreboard objectives remove sniperx
    scoreboard objectives remove snipery
    scoreboard objectives remove sniperz

    scoreboard players set @e gunshots 0
    scoreboard players set @s reloadSniper 50


    FYI the goal of this function is to spawn an arrow in front of a player and get it to fly in the direction they are looking. Also, if you catch any other errors with my code please point them out to me.










    share|improve this question







    New contributor




    Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.






















      -1












      -1








      -1








      I'm writing a function for a datapack in Minecraft. After /reloading, /function couldn't find the function, so I pasted each line into Minecraft to check for syntax and other errors. I found that the problem was in the commands that store the aoecloud's position into a scoreboard, and also in the ones that take those values and place them into the Motion nbt for an arrow. The issue is that according to Minecraft, only one entity is allowed in the target selector while my target selector is selecting multiple. I tried using a customName to fix this problem but it didn't work. How can I get the target selector to select the arrow/aoecloud created at the top of the function and not give me errors?



      summon minecraft:arrow ^ ^ ^1 Tags:["sniperbullet"], CustomName:""sniperbullet""
      summon minecraft:area_effect_cloud 0 0 0 Tags:["sniperaoecloud"], CustomName:""sniperaoecloud""
      execute as @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] at @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] rotated as @a[scores=gunshots=1..,nbt=SelectedItem:tag:display:Name:""text":"Sniper Rifle""] run tp @s ^ ^ ^1

      scoreboard objectives add sniperx dummy
      scoreboard objectives add snipery dummy
      scoreboard objectives add sniperz dummy

      execute store result score @s sniperx run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[0] 10000
      execute store result score @s snipery run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[1] 10000
      execute store result score @s sniperz run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[2] 10000

      execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[0] double 0.0001 run scoreboard players get @s sniperx
      execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[1] double 0.0001 run scoreboard players get @s snipery
      execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[2] double 0.0001 run scoreboard players get @s sniperz

      scoreboard objectives remove sniperx
      scoreboard objectives remove snipery
      scoreboard objectives remove sniperz

      scoreboard players set @e gunshots 0
      scoreboard players set @s reloadSniper 50


      FYI the goal of this function is to spawn an arrow in front of a player and get it to fly in the direction they are looking. Also, if you catch any other errors with my code please point them out to me.










      share|improve this question







      New contributor




      Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.












      I'm writing a function for a datapack in Minecraft. After /reloading, /function couldn't find the function, so I pasted each line into Minecraft to check for syntax and other errors. I found that the problem was in the commands that store the aoecloud's position into a scoreboard, and also in the ones that take those values and place them into the Motion nbt for an arrow. The issue is that according to Minecraft, only one entity is allowed in the target selector while my target selector is selecting multiple. I tried using a customName to fix this problem but it didn't work. How can I get the target selector to select the arrow/aoecloud created at the top of the function and not give me errors?



      summon minecraft:arrow ^ ^ ^1 Tags:["sniperbullet"], CustomName:""sniperbullet""
      summon minecraft:area_effect_cloud 0 0 0 Tags:["sniperaoecloud"], CustomName:""sniperaoecloud""
      execute as @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] at @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud] rotated as @a[scores=gunshots=1..,nbt=SelectedItem:tag:display:Name:""text":"Sniper Rifle""] run tp @s ^ ^ ^1

      scoreboard objectives add sniperx dummy
      scoreboard objectives add snipery dummy
      scoreboard objectives add sniperz dummy

      execute store result score @s sniperx run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[0] 10000
      execute store result score @s snipery run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[1] 10000
      execute store result score @s sniperz run data get entity @e[type=minecraft:area_effect_cloud, tag=sniperaoecloud, name=sniperaoecloud] Pos[2] 10000

      execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[0] double 0.0001 run scoreboard players get @s sniperx
      execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[1] double 0.0001 run scoreboard players get @s snipery
      execute store result entity @e[type=minecraft:arrow, tag=sniperbullet, name=sniperbullet] Motion[2] double 0.0001 run scoreboard players get @s sniperz

      scoreboard objectives remove sniperx
      scoreboard objectives remove snipery
      scoreboard objectives remove sniperz

      scoreboard players set @e gunshots 0
      scoreboard players set @s reloadSniper 50


      FYI the goal of this function is to spawn an arrow in front of a player and get it to fly in the direction they are looking. Also, if you catch any other errors with my code please point them out to me.







      minecraft minecraft-commands






      share|improve this question







      New contributor




      Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      share|improve this question







      New contributor




      Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      share|improve this question




      share|improve this question






      New contributor




      Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked 21 mins ago









      Nik3141Nik3141

      235




      235




      New contributor




      Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Nik3141 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.




















          0






          active

          oldest

          votes












          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "41"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          noCode: true, onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );






          Nik3141 is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgaming.stackexchange.com%2fquestions%2f348970%2fneed-to-make-target-selector-only-select-one-entity%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          Nik3141 is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          Nik3141 is a new contributor. Be nice, and check out our Code of Conduct.












          Nik3141 is a new contributor. Be nice, and check out our Code of Conduct.











          Nik3141 is a new contributor. Be nice, and check out our Code of Conduct.














          Thanks for contributing an answer to Arqade!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgaming.stackexchange.com%2fquestions%2f348970%2fneed-to-make-target-selector-only-select-one-entity%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Sahara Skak | Bilen | Luke uk diar | NawigatsjuunCommonskategorii: SaharaWikivoyage raisfeerer: Sahara26° N, 13° O

          The fall designs the understood secretary. Looking glass Science Shock Discovery Hot Everybody Loves Raymond Smile 곳 서비스 성실하다 Defas Kaloolon Definition: To combine or impregnate with sulphur or any of its compounds as to sulphurize caoutchouc in vulcanizing Flame colored Reason Useful Thin Help 갖다 유명하다 낙엽 장례식 Country Iron Definition: A fencer a gladiator one who exhibits his skill in the use of the sword Definition: The American black throated bunting Spiza Americana Nostalgic Needy Method to my madness 시키다 평가되다 전부 소설가 우아하다 Argument Tin Feeling Representative Gym Music Gaur Chicken 일쑤 코치 편 학생증 The harbor values the sugar. Vasagle Yammoe Enstatite Definition: Capable of being limited Road Neighborly Five Refer Built Kangaroo 비비다 Degree Release Bargain Horse 하루 형님 유교 석 동부 괴롭히다 경제력

          19. јануар Садржај Догађаји Рођења Смрти Празници и дани сећања Види још Референце Мени за навигацијуу