how do you make a command with arguments?

Started by Yutaken on

Topic category: Help with modding (Java Edition)

Last seen on 23:51, 22. Jun 2021
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
how do you make a command with arguments?

how do you make a command with arguments?

for example, I'm making a mod all on food. and I want to make a command called "/hunger". and the arguments are:<mob> <add/remove/set> <integer>.add to add hunger bar,remove to remove hunger bar,and set to set hunger.

maybe my grammar is wrong.

Last seen on 16:23, 18. Mar 2024
Joined Dec 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
im not sure.  
Thu, 04/02/2020 - 14:35

im not sure.

 

Last seen on 23:51, 22. Jun 2021
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
maybe I can use "hunger <a…
Thu, 04/02/2020 - 23:48

maybe I can use "hunger <a code to represent @p,@e,@s,@a,and player name> <add|set|remove> <int or num>"

even if it works,how do you do the "add is add hunger,remove is remove hunger,and set to set hunger" problem.

Last seen on 23:55, 15. Mar 2023
Joined Oct 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I'll see if I can come up…
Fri, 04/03/2020 - 00:47

I'll see if I can come up with something for you. If I don't send another reply, then I couldn't think of anything.

Last seen on 23:51, 22. Jun 2021
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
thanks qsided.
Fri, 04/03/2020 - 13:25

thanks qsided.

Last seen on 23:51, 22. Jun 2021
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
command parameter with index…
Sun, 06/21/2020 - 19:15

command parameter with index [command parameter index 0 is first parameter]

Last seen on 23:51, 22. Jun 2021
Joined Mar 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
in advanced section  
Sun, 06/21/2020 - 19:15

in advanced section