[TUTORIAL] Making a flying armor 2022.x - Forge 1.18.2 - Look at the comments for updates up to 2023.x 1.20.1

Started by __SK__ on

Topic category: User side tutorials

Active 1 month ago
Joined May 2021
Points:
836

User statistics:

  • Modifications: 4
  • Forum topics: 11
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 353
[TUTORIAL] Making a flying armor 2022.x - Forge 1.18.2 - Look at the comments for updates up to 2023.x 1.20.1
Sat, 05/04/2024 - 01:18 (edited)

I tried to make it as simple as possible, it does require to lock the code.

  1. Create your default or custom 3d armor
  2. Modify the desired settings
  3. Save
  4. Now lock the code
  5. Copy the following and paste it right before the last "}" in the code

 

    

   @Override
   public boolean canElytraFly(ItemStack stack, net.minecraft.world.entity.LivingEntity entity) {
      return true;
   }

   @Override
   public boolean elytraFlightTick(ItemStack stack, net.minecraft.world.entity.LivingEntity entity, int flightTicks) {
      if (!entity.level.isClientSide) {
         int nextFlightTick = flightTicks + 1;
         if (nextFlightTick % 10 == 0) {
            if (nextFlightTick % 20 == 0) {
               stack.hurtAndBreak(1, entity, e -> e.broadcastBreakEvent(net.minecraft.world.entity.EquipmentSlot.CHEST));
            }
            entity.gameEvent(net.minecraft.world.level.gameevent.GameEvent.ELYTRA_FREE_FALL);
         }
      }
      return true;
   }

=============SPECIAL NOTE================

    If needed set stack.hurtAndBreak from 1 (default value - breakable) to 0 (unbreakable)

=============SPECIAL NOTE================

 

Congratulations, now your armor (chestplate) will act just like an elytra ... and still have armor properties.

If you still have doubts, watch the following ...

NOTE: Apologies for the image hosting issues, one of my server admins decided to rearrange the content in it causing mapping issues.

Please ... (right click and save for future reference)

Results ...

Take off

Landing

With some creativity you could add a tick to the chestplate ... adding an additional chestplate that will switch while in air for a winged model, making it cool and more enjoyable to watch.

 

I would gladly like to see screenshots of your creations.

Have fun

Edited by __SK__ on Sat, 05/04/2024 - 01:18
Active 1 month ago
Joined May 2021
Points:
836

User statistics:

  • Modifications: 4
  • Forum topics: 11
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 353
Unfortunately, I have not…
Thu, 11/24/2022 - 16:54

Unfortunately, I have not seen any site where you can download premade 3d elytra models. Mostly I google search for wings images and/or robot wings characters to find inspiration for my wing models. 

Active 4 days ago
Joined Mar 2020
Points:
1183

User statistics:

  • Modifications: 6
  • Forum topics: 71
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 264
Hey, is it possible to use…
Sun, 01/22/2023 - 17:09

Hey, is it possible to use it without armor, im making a mod where the player can fly in survival(not using creative fly cuz its wack), i already have the procedure, i just want the player to use the elytra flying animation. 

Active 1 month ago
Joined May 2021
Points:
836

User statistics:

  • Modifications: 4
  • Forum topics: 11
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 353
Sorry for the delayed answer…
Wed, 02/15/2023 - 22:39

Sorry for the delayed answer, initially I tried with an item in main hand ... but it did not work. Will take a look into it.

Active 4 days ago
Joined Mar 2020
Points:
1183

User statistics:

  • Modifications: 6
  • Forum topics: 71
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 264
Alright, sorry for the late…
Wed, 03/08/2023 - 21:22

Alright, sorry for the late reply too

Active 4 months ago
Joined Oct 2022
Points:
443

User statistics:

  • Modifications: 1
  • Forum topics: 7
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 76
Hi, it doesn't work well, I…
Thu, 03/23/2023 - 15:47

Hi, it doesn't work well, I don't know why, could you help me?

Active 4 months ago
Joined Oct 2022
Points:
443

User statistics:

  • Modifications: 1
  • Forum topics: 7
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 76
Nothing, I fixed it, forgot…
Thu, 03/23/2023 - 15:55

Nothing, I fixed it, forgot it

 

Active 4 weeks ago
Joined Jan 2023
Points:
353

User statistics:

  • Modifications: 0
  • Forum topics: 9
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 16
Can you make the armor code…
Thu, 07/06/2023 - 19:28

Can you make the armor code doesn't need fireworks? I mean can fly itself?

Just asking 😁

Active 2 months ago
Joined Jul 2021
Points:
601

User statistics:

  • Modifications: 0
  • Forum topics: 8
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 13
I'm making an armor right…
Sat, 07/29/2023 - 15:46

I'm making an armor right now, but I don't want to use fireworks all the time on that armor, do you have a chance to make a model that goes at the same speed all the time?

Active 2 years ago
Joined Aug 2023
Points:
193

User statistics:

  • Modifications: 0
  • Forum topics: 0
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 3
Hey! I've found your code,…
Mon, 08/21/2023 - 22:50

Hey! I've found your code, and I have a question. Do you need the whole armor set for your code to work? I'm trying to do it with just a chestplate, and there's no errors, but when I try to fly like with an elytra, I don't fly, I just fall.

Active 2 years ago
Joined Aug 2023
Points:
193

User statistics:

  • Modifications: 0
  • Forum topics: 0
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 3
Hello again, so I found the…
Tue, 08/22/2023 - 14:35

Hello again, so I found the issue. It won't save the code everytime I enter the code and save it.

Active 1 month ago
Joined May 2021
Points:
836

User statistics:

  • Modifications: 4
  • Forum topics: 11
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 353
@JaBaconator - you need to…
Wed, 08/23/2023 - 00:50

@JaBaconator - you need to lock the code for that class.

Active 1 month ago
Joined May 2021
Points:
836

User statistics:

  • Modifications: 4
  • Forum topics: 11
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 353
Hey! I've found your code,…
Wed, 08/23/2023 - 00:53

Hey! I've found your code, and I have a question. Do you need the whole armor set for your code to work? I'm trying to do it with just a chestplate, and there's no errors, but when I try to fly like with an elytra, I don't fly, I just fall.

 

Sorry ... It has been a long time without working with this type of elytra armor. I will have to recreate/test it in order to figure out the issue.

Active 2 years ago
Joined Aug 2023
Points:
193

User statistics:

  • Modifications: 0
  • Forum topics: 0
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 3
I got it to work! I used the…
Thu, 08/24/2023 - 19:48

I got it to work! I used the newer one. The other one had given me an error, hence why it wouldn't save! TYSM!!!

Active 1 month ago
Joined May 2021
Points:
836

User statistics:

  • Modifications: 4
  • Forum topics: 11
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 353
@JaBaconator - Awesome,…
Sat, 08/26/2023 - 20:02

@JaBaconator - Awesome, great news.