Skip to content

Commit

Permalink
Added Sword on a Stick (...yep)
Browse files Browse the repository at this point in the history
Tweaked Omen proc sound effect
Added sound effect to Watcher proc
  • Loading branch information
Sweenus committed Aug 16, 2022
1 parent 9ecb948 commit d4002c2
Show file tree
Hide file tree
Showing 11 changed files with 692 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public void applyUpdateEffect(LivingEntity pLivingEntity, int pAmplifier) {
pLivingEntity.kill();
if (pPlayer.getAbsorptionAmount() < 6f) {
pPlayer.setAbsorptionAmount(pPlayer.getAbsorptionAmount() + absAmount);
world.playSound(null, position, SoundEvents.BLOCK_ANVIL_LAND, SoundCategory.BLOCKS, 1f, 1f);
world.playSound(null, position, SoundEvents.BLOCK_ANVIL_LAND, SoundCategory.BLOCKS, 0.6f, 1f);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public void applyUpdateEffect(LivingEntity pLivingEntity, int pAmplifier) {
if (e != null && pPlayer != null){
e.damage(DamageSource.FREEZE, rAmount);
pPlayer.setHealth(pPlayer.getHealth() + rAmount);
world.playSound(null, position, SoundEvents.BLOCK_ENDER_CHEST_OPEN, SoundCategory.BLOCKS, 1f, 1f);
world.playSound(null, position, SoundEvents.BLOCK_ENDER_CHEST_OPEN, SoundCategory.BLOCKS, 0.2f, 1f);
}
}

Expand Down
4 changes: 4 additions & 0 deletions src/main/java/net/sweenus/simplyswords/item/ModItems.java
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,10 @@ public class ModItems {
new StormSwordItem(ToolMaterials.NETHERITE, 3, -1.7f,
new FabricItemSettings().group(ModItemGroup.SIMPLYSWORDS).rarity(Rarity.EPIC)));

public static final Item SWORD_ON_A_STICK = registerItem( "sword_on_a_stick",
new SwordItem(ToolMaterials.WOOD, 5, -1.9f,
new FabricItemSettings().group(ModItemGroup.SIMPLYSWORDS).rarity(Rarity.EPIC)));

public static final Item TOXIC_LONGSWORD = registerItem( "toxic_longsword",
new PoisonSwordItem(ToolMaterials.NETHERITE, 3, -2.4f,
new FabricItemSettings().group(ModItemGroup.SIMPLYSWORDS).rarity(Rarity.EPIC)));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,8 @@ public static void modifyLootTables() {
.conditionally(RandomChanceLootCondition.builder(SimplySwordsConfig.getFloatValue("unique_loot_table_weight"))) // 1 = 100% of the time
.with(ItemEntry.builder(ModItems.WATCHER_CLAYMORE))
.with(ItemEntry.builder(ModItems.TOXIC_LONGSWORD))
.with(ItemEntry.builder(ModItems.SWORD_ON_A_STICK))
.with(ItemEntry.builder(ModItems.STORMS_EDGE))
.with(ItemEntry.builder(ModItems.BRIMSTONE_CLAYMORE));
tableBuilder.pool(upool);

Expand Down
1 change: 1 addition & 0 deletions src/main/resources/assets/simplyswords/lang/en_us.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
"item.simplyswords.diamond_twinblade": "Diamond Twinblade",
"item.simplyswords.netherite_twinblade": "Netherite Twinblade",
"item.simplyswords.storms_edge": "Storm's Edge",
"item.simplyswords.sword_on_a_stick": "Sword on a Stick",


"itemGroup.simplyswords.simplyswords": "Simply Swords",
Expand Down
Loading

0 comments on commit d4002c2

Please sign in to comment.