How to create sword's keybinded abilities?

Started by Maslek on

Topic category: Help with modding (Java Edition)

Last seen on 04:06, 15. Jun 2022
Joined Dec 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to create sword's keybinded abilities?

I am going to create a mode with tons of swords and melee weapons and im looking for to make them a keybinded ability or even two.
I tried taking a look on procedures but they don't seem to have keybinding stuff.
Any advice on it?

Last seen on 01:41, 8. Jan 2024
Joined May 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Make a "Key binding" element…
Wed, 11/24/2021 - 18:20

Make a "Key binding" element, choose the key to press while holding a specific weapon, and then for the "On key pressed" procedure, use the structure shown in the screenshot. https://imgur.com/a/yJr1zPB

Have a great day!

Last seen on 07:18, 29. Mar 2024
Joined Mar 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How will you able to make it…
Wed, 11/24/2021 - 21:17

How will you able to make it have multiple abilities.

Let's say if I press the keybind it will set the first skill Then I need to right click to activate that skill, if I press the keybind a second time it set to the 2nd skill and so on

Last seen on 01:41, 8. Jan 2024
Joined May 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
First, make a global…
Thu, 11/25/2021 - 02:56

First, make a global variable.

Second, make a keybind with this procedure for when button pressed.

FInally, make the item/tool/whatever with this procedure for when right-clicked in air.

 

It wont let me put three image links in one post, so I'll put them in their own separate replies.

Last seen on 07:18, 29. Mar 2024
Joined Mar 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Thanks I've been looking for…
Thu, 11/25/2021 - 08:54

Thanks I've been looking for this. Who knew it would that simple, thanks 😊

Last seen on 04:06, 15. Jun 2022
Joined Dec 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Humongous thanks good sir!…
Thu, 11/25/2021 - 17:31

Humongous thanks good sir! However I find the ability a bit challenging.
I'll set the entire ability and how I want to make it really simple.
On pressing the key with the item in hand the space infront of the player will be struck with lightining and 3 blocks ahead with it (so 3 blocks infront of the player will be thunderstruck) 
I just don't really get how to "explain" to the program how to strike exactly the 3 blocks infront of the player and not exact coordinates or random direction instead of front.
Sorry if it takes your time, I'll be really happy if you did it.

Last seen on 01:41, 8. Jan 2024
Joined May 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
To ClOud1076, you're welcome…
Thu, 11/25/2021 - 19:21

To ClOud1076, you're welcome. To Maslek, all you have to do is grab a [Strike lightning at x: y: z: effect only:] block from "World management," grab two "Look position with raytrace distance" blocks, one for X and one for Z, and replace the X and Z blocks in the strike lightning block with these look raytrace ones. You can do the same for the Y block, but that just affects how high/low the lightning spawns, and it is completely optional. Here's a screenshot. https://imgur.com/CAs19QZ

Last seen on 11:10, 21. Jun 2022
Joined Jun 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
could you not just get…
Wed, 06/08/2022 - 04:16

could you not just get player loc and get players "facing" direction then 123 the blocks with lightning starting with an offset of one from their position?

 

Last seen on 11:10, 21. Jun 2022
Joined Jun 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
sorry, that question isnt…
Wed, 06/08/2022 - 04:20

sorry, that question isnt really important to me, i was searching for answers to my textures mis-aligning after export from Blockbench and import to MCreator. They are high res and I only have the helm made so far with it's own texture.

 

Last seen on 16:44, 2. Mar 2024
Joined Aug 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Doesn't let me use the…
Mon, 09/05/2022 - 22:46

Doesn't let me use the procedure, says "missing dependencies"