HUPacks: Superpowers - Heroes-United/HeroesUnited GitHub Wiki

Superpower creation is very easy!

Superpower should be in data/yourpackname/husuperpowers First of all you'll need a JSON object where you can "list" all the abilities you want to have.

"abilities": {

}

Every ability needs its own JSON object, so inside this list you can add another JSON object.

"abilities": {
   "<name_of_addon>:ability_one": {
      "ability": "hugeneratorrex:breach" //You can only use abilities from mods (For example, Generator Rex), Core add's 2 abilities AttributeModifier and Flight so u can use like "heroesunited:attribute_modifier" or "heroesunited:flight".
      "active": true, // Our ability can be left as it is, or made always active
      "hidden": true // The ability is not visible in the gui
   }
}

Abilities can be translated to other languages or only on english like:

			"title": {
				"translate": "ban.abilities.wow.name" //For translation
			},
			"title": {
				"text": "Wowo text" //For default text
			},

Some abilities add's own data, so u should write it, for use this ability. For Attribute Modifier u should add :

			"attribute": {
				"name": "minecraft:generic.movement_speed", //Name of attribute
				"amount": 5, //Amount
				"operation": 0, //Operation 0 - addition, 1 - multiple base, 2 - multiply total
				"uuid": "a253e5c2-ed6e-4d40-9843-4df889e84068" // UUID of attribute (u can use random)
			}

and key opinion:

			"key": {
				"id": 1, //What key should press player.
				"pressType": "action" //How player should press to activate ability, `toggle, held or action`
			},

For Flight (and u can use key opinion) :

"rotateArms": false, //Rotate arms in flight?
"render": true //Render fly?

If you want to add your own icon for an ability, you must select the type of this icon - item, texture

For item icon:

			"icon": {
				"type": "item", 
				"item": "minecraft:stick"
			},

For Texture icon

			"icon": {
				"type": "texture",
				"texture": "<name_of_addon>:textures/<path_to_icon>/<icon_texture>.png",
				"u": 0,
				"v": 0,
				"width": 16,
				"height": 16,
				"texture_width": 16,
				"texture_height": 16
			},

Result

Result!

{
	"abilities": {
		"ability_one": {
			"ability": "hugeneratorrex:breach"
			"active": true,
			"hidden": true
		}
	}
}