BetterCombat API [Forge 1.19.4 - 1.20.1]

Published by MinoBanana on
Supported MCreator versions
2023.4
2024.1
2024.2
Tags / plugin type
API support
Better Combat API Logo
Downloads:
2854
Upvotes: 25
About the plugin

Better Combat API adds support for the Better Combat mod within MCreator

 

--Enabling the Mod / How to Use--

Click "Workspace Settings" at the top right--> Click External API -->
Ensure the following 3 external API's are turned on for everything to work properly

(If you cannot see these options, restart McCreator)

Enable BetterCombat, PlayerAnimator, and ClothConfig

 

--Adding Animations to Weapons--

Method 1 - Simple Way:

Begin by adding a tool element

Add a tool element

 

Within the Tool name / ID MAKE SURE YOU INCLUDE ONE OF THE FOLLOWING PRESETS:

Anchor, Axe, Battlestaff, Claw, Claymore, CoralBlade, Cutlass, Dagger, DoubleAxe, Fist, Glaive, Halberd, Hammer, HeavyAxe, Katana, Lance, Mace, Pickaxe, Rapier, Scythe, Sickle, SoulKnife, Spear, Staff, Sword, Trident, TwinBlade, Wand

Enter tool name

 

It should look something like this

Enter tool name with preset

 

You can the change the in-game name of the item to whatever you like:

Change the in game name to whatever you like

 


 

Method 2 - Complex Way:

Begin by opening the workspace file browser by sliding the bar at the far left, towards the right

Open file manager in mcreator

 

Open the Resources/data/modID folder - if you cannot find the data folder simply create a recipe, save it, then delete it

folder overview

 

Right click on the modID folder and add a folder called weapon_attributes

create a weapon_attributes folder

 

Right Click that folder and click add JSON file

Adding json file

 

Name the JSON file with the weapon ID you'd like to customize - ensure each capital letter/space in the element name is separated by an underscore

json file naming

 

Within the JSON file, type the following, substituting one of the aforementioned presets into the <preset> placeholder:

{
"parent": "bettercombat:<preset>"
}

Save the JSON file, and everything should be ready!

 

--Changing the Size of Weapons--

Begin by locking the code of your chosen weapon

Lock the code of the element

 

Open the associated JSON file

open element json

 

Copy and Paste the Following:

https://pastebin.com/W9cFzZeV

 

Make sure to change the modID, and textureID

You may then edit the rotation, translation, and scale freely

 

--Better Combat Documentation--

GitHub: https://github.com/ZsoltMolnarrr/BetterCombat

Weapon Presets: https://github.com/ZsoltMolnarrr/BetterCombat/tree/1.20.1/common/src/main/resources/data/bettercombat/weapon_attributes

 

License
All Rights Reserved

Plugin downloads
(2023.4) Version 1.0.0 ~ BetterCombatAPI - BetterCombatAPI.zip Uploaded on: 01/21/2024 - 14:11   File size: 2.62 KB
(2024.1) Version 1.0.1 ~ BetterCombatAPI - bettercombatapi.zip Uploaded on: 04/14/2024 - 13:30   File size: 2.65 KB
(2024.2) Version 1.0.2 ~ BetterCombatAPI - bettercombatapi_1.0.2.zip Uploaded on: 07/25/2024 - 11:30   File size: 2.65 KB

Comments

Is there any way to make custom animations for weapons? I watched a lot of tutorials but I don't understand English or other languages ​​of the tutorials or of MCreator itself well, I've tried a lot of things and made my own animations and uploaded them to MCreator but nothing, it only worked by putting the name of the weapon set as katana or dagger, etc. but not with my own animations. Thanks for reading

It would be great to see a separate tab "additional weapon properties", where you could select an item and set it the type of weapon, attack range, etc.

Hi, no matter how hard I try, I can't change the attack distance, could you help me here is the code itself:
{
"parent": "sins:custom/diana_hammer",
"attributes": {
"attack_range": "4"
},
"textures": {
"2": "sins:block/diana",
"particle": "sins:item/diana"
}
}

{
"parent": "sins:custom/diana_hammer",
"attributes": {
"attack_range": 4
},
"textures": {
"2": "sins:block/diana",
"particle": "sins:item/diana"
}
}
I changed the 4 to a digit and it didn't work either

Is there a way to extend reach on items? It looks... slightly strange to have a hammer or such that reaches like 7 blocks a away visually, but only can attack around the couple block directly in front of it.

Hey, I'm having trouble making a weapon with the Double Axe preset using the 'complex method' and i tried using "bettercombat:double_axe", "bettercombat:doubleaxe" and "bettercombat:DoubleAxe" with the element locked and unlocked, what am i doing wrong here?

Won’t naming the item one of those weapon types ruin the name for when you do /give in Minecraft because the name of the registry name isn’t correct.