Omer Marciano

Make me a new item called "the god sword" it one-shots anything it hits, when i right click it i like dash 10 blocks to where I am looking, even if it's to the sky or into the ground. Also, when I hold the sword, I can't take damage.

Kodari AI
KodariOct 9 at 10:52 am 7
GodSword
Creates a custom "God Sword" item with three powerful abilities. The sword deals instant lethal damage to any entity it hits, guaranteeing a one-shot kill. Right-clicking triggers a 10-block dash toward the player's look direction, including vertical dashes into the sky or ground. While held in the main hand, the player becomes completely invulnerable to all damage sources. The item is obtainable via a command and features custom lore and enchantment glint.
  1. Create the Fabric 26.2 mod scaffold and register the God Sword.

  2. Add one-hit attacks, a 10-block look-direction dash, and damage immunity while held.

  3. Add a survival recipe and the sword’s item assets.

Added The God Sword Fabric 26.2 mod. It one-shots entities, dashes you 10 blocks in the direction you’re looking on right-click—including into the sky or ground—and prevents damage while held in either hand.

Craft it with a netherite sword, a nether star, and two diamonds. It appears in the Combat creative tab and can be repaired with netherite ingots.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
gradle.properties
settings.gradle
Code
14 247
src/main/java/com/kodari/godsword/GodSwordMod.java
package com.kodari.godsword;

import net.fabricmc.api.ModInitializer;

public final class GodSwordMod implements ModInitializer {
	public static final String MOD_ID = "godsword";

	@Override
	public void onInitialize() {
		ModItems.initialize();
		GodSwordEvents.initialize();
	}
}