Skip to content
This repository was archived by the owner on Feb 16, 2026. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -90,23 +90,19 @@ public class ${name}PortalBlock extends NetherPortalBlock {
<#if data.portalSound.toString()?has_content>
if (random.nextInt(110) == 0)
world.playSound(null, pos.getX() + 0.5, pos.getY() + 0.5, pos.getZ() + 0.5,
ForgeRegistries.SOUND_EVENTS
.getValue(ResourceLocation.parse("${data.portalSound}")), SoundSource.BLOCKS, 0.5f,
ForgeRegistries.SOUND_EVENTS.getValue(ResourceLocation.parse("${data.portalSound}")), SoundSource.BLOCKS, 0.5f,
random.nextFloat() * 0.4f + 0.8f);
</#if>
}

@Override public void entityInside(BlockState state, Level world, BlockPos pos, Entity entity) {
<#if hasProcedure(data.portalUseCondition)>
if (<@procedureCode data.portalUseCondition, {
"x": "pos.getX()",
"y": "pos.getY()",
"z": "pos.getZ()",
"entity": "entity",
"world": "world"
}, false/>)
</#if>
if (entity.canChangeDimensions() && !entity.level().isClientSide()) {
if (<#if hasProcedure(data.portalUseCondition)><@procedureCode data.portalUseCondition, {
"x": "pos.getX()",
"y": "pos.getY()",
"z": "pos.getZ()",
"entity": "entity",
"world": "world"
}, false/> && </#if>entity.canChangeDimensions() && !entity.level().isClientSide()) {
if (entity.isOnPortalCooldown()) {
entity.setPortalCooldown();
} else if (entity.level().dimension() != ResourceKey.create(Registries.DIMENSION, ResourceLocation.parse("${modid}:${registryname}"))) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ package ${package}.item;
public class ${name}Item extends Item {

public ${name}Item() {
super(new Item.Properties().rarity(Rarity.${data.igniterRarity}).durability(64));
super(new Item.Properties()
<#if data.igniterRarity != "COMMON">.rarity(Rarity.${data.igniterRarity})</#if>
.durability(64)
);
}

<@addSpecialInformation data.specialInformation, "item." + modid + "." + registryname/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ public class ${name}Item extends BucketItem {

public ${name}Item() {
super(${JavaModName}Fluids.${REGISTRYNAME},
new Item.Properties().craftRemainder(Items.BUCKET).stacksTo(1).rarity(Rarity.${data.rarity}));
new Item.Properties().craftRemainder(Items.BUCKET).stacksTo(1)
<#if data.rarity != "COMMON">.rarity(Rarity.${data.rarity})</#if>
);
}

<@addSpecialInformation data.specialInformation, "item." + modid + "." + registryname + "_bucket"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ public class ${name}FluidType extends FluidType {
<#else>
.sound(SoundActions.BUCKET_EMPTY, SoundEvents.BUCKET_EMPTY)
</#if>
.sound(SoundActions.FLUID_VAPORIZE, SoundEvents.FIRE_EXTINGUISH));
.sound(SoundActions.FLUID_VAPORIZE, SoundEvents.FIRE_EXTINGUISH)
);
}

@Override public void initializeClient(Consumer<IClientFluidTypeExtensions> consumer) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public class ${name}MobEffect extends MobEffect {
public ${name}MobEffect() {
super(MobEffectCategory.${data.mobEffectCategory}, ${data.color.getRGB()});
<#list data.modifiers as modifier>
this.addAttributeModifier(${modifier.attribute}, "${w.getUUID(data.getModElement().getRegistryName() + "_" + modifier?index)}", ${modifier.amount},
this.addAttributeModifier(${modifier.attribute}, "${w.getUUID(registryname + "_" + modifier?index)}", ${modifier.amount},
AttributeModifier.Operation.${getAttributeOperation(modifier.operation)});
</#list>
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ public class ${name}Renderer extends EntityRenderer<${name}Entity> {
poseStack.pushPose();
poseStack.mulPose(Axis.YP.rotationDegrees(Mth.lerp(partialTicks, entityIn.yRotO, entityIn.getYRot()) - 90));
poseStack.mulPose(Axis.ZP.rotationDegrees(90 + Mth.lerp(partialTicks, entityIn.xRotO, entityIn.getXRot())));
model.setupAnim(entityIn, 0, 0, entityIn.tickCount + partialTicks, entityIn.getYRot(), entityIn.getXRot());
model.renderToBuffer(poseStack, vb, packedLightIn, OverlayTexture.NO_OVERLAY, 1, 1, 1, 1);
poseStack.popPose();

Expand Down