Compare commits
No commits in common. "484c470f4f8125e1b9c718ce53f8197749cd5fe1" and "2cb6007d163acd7de859e0c45c5016ef725703d7" have entirely different histories.
484c470f4f
...
2cb6007d16
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -6,4 +6,3 @@ src/generated/**/*.json text eol=lf
|
|||||||
*.png filter=lfs diff=lfs merge=lfs -text
|
*.png filter=lfs diff=lfs merge=lfs -text
|
||||||
*.gif filter=lfs diff=lfs merge=lfs -text
|
*.gif filter=lfs diff=lfs merge=lfs -text
|
||||||
*.pxc filter=lfs diff=lfs merge=lfs -text
|
*.pxc filter=lfs diff=lfs merge=lfs -text
|
||||||
*.bbmodel filter=lfs diff=lfs merge=lfs -text
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
zlib License
|
zlib License
|
||||||
|
|
||||||
(C) 2024 shylie
|
(C) 2024 Shylie
|
||||||
|
|
||||||
This software is provided 'as-is', without any express or implied
|
This software is provided 'as-is', without any express or implied
|
||||||
warranty. In no event will the authors be held liable for any damages
|
warranty. In no event will the authors be held liable for any damages
|
||||||
|
@ -42,9 +42,9 @@ mapping_version=1.20.1
|
|||||||
|
|
||||||
# The unique mod identifier for the mod. Must be lowercase in English locale. Must fit the regex [a-z][a-z0-9_]{1,63}
|
# The unique mod identifier for the mod. Must be lowercase in English locale. Must fit the regex [a-z][a-z0-9_]{1,63}
|
||||||
# Must match the String constant located in the main mod class annotated with @Mod.
|
# Must match the String constant located in the main mod class annotated with @Mod.
|
||||||
mod_id=apparatus
|
mod_id=ashes
|
||||||
# The human-readable display name for the mod.
|
# The human-readable display name for the mod.
|
||||||
mod_name=Apparatus
|
mod_name=Ashes
|
||||||
# The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default.
|
# The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default.
|
||||||
mod_license=zlib
|
mod_license=zlib
|
||||||
# The mod version. See https://semver.org/
|
# The mod version. See https://semver.org/
|
||||||
@ -52,11 +52,11 @@ mod_version=0.1.0
|
|||||||
# The group ID for the mod. It is only important when publishing as an artifact to a Maven repository.
|
# The group ID for the mod. It is only important when publishing as an artifact to a Maven repository.
|
||||||
# This should match the base package used for the mod sources.
|
# This should match the base package used for the mod sources.
|
||||||
# See https://maven.apache.org/guides/mini/guide-naming-conventions.html
|
# See https://maven.apache.org/guides/mini/guide-naming-conventions.html
|
||||||
mod_group_id=info.shylie.apparatus
|
mod_group_id=info.shylie.ashes
|
||||||
# The authors of the mod. This is a simple text string that is used for display purposes in the mod list.
|
# The authors of the mod. This is a simple text string that is used for display purposes in the mod list.
|
||||||
mod_authors=shylie
|
mod_authors=Shylie
|
||||||
# The description of the mod. This is a simple multiline text string that is used for display purposes in the mod list.
|
# The description of the mod. This is a simple multiline text string that is used for display purposes in the mod list.
|
||||||
mod_description=Golems.
|
mod_description=Embers addon focused on ash-related content.
|
||||||
|
|
||||||
embers_version=5571196
|
embers_version=5571196
|
||||||
jei_version=15.2.0.23
|
jei_version=15.2.0.23
|
||||||
|
@ -1,4 +0,0 @@
|
|||||||
// 1.20.1 2024-08-05T15:53:54.8948719 Item Models: apparatus
|
|
||||||
63ec6c618a3a23eab4cab9c52d7d3250de9b516e assets/apparatus/models/item/ashen_golem_spawn_egg.json
|
|
||||||
08b29faee9e863e4236705fd32ac24195a02bdd2 assets/apparatus/models/item/heated_ashy_ingot.json
|
|
||||||
0dc353ee91d1c36e07a28d5b3733c140a681a24d assets/apparatus/models/item/rune.json
|
|
@ -0,0 +1,4 @@
|
|||||||
|
// 1.20.1 2024-08-02T01:31:53.2565269 Item Models: ashes
|
||||||
|
63ec6c618a3a23eab4cab9c52d7d3250de9b516e assets/ashes/models/item/ashen_golem_spawn_egg.json
|
||||||
|
060aa5df9f6e6c2d7476baa7c80b996a3c9fd4df assets/ashes/models/item/heated_ashy_ingot.json
|
||||||
|
49ecc679012241ea5a31c76f6ffde9236c2a2ef5 assets/ashes/models/item/rune.json
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"parent": "minecraft:item/generated",
|
"parent": "minecraft:item/generated",
|
||||||
"textures": {
|
"textures": {
|
||||||
"layer0": "apparatus:item/heated_ashy_ingot"
|
"layer0": "ashes:item/heated_ashy_ingot"
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"parent": "minecraft:item/generated",
|
"parent": "minecraft:item/generated",
|
||||||
"textures": {
|
"textures": {
|
||||||
"layer0": "apparatus:item/rune"
|
"layer0": "ashes:item/rune"
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,10 +1,10 @@
|
|||||||
package info.shylie.apparatus;
|
package info.shylie.ashes;
|
||||||
|
|
||||||
import com.mojang.logging.LogUtils;
|
import com.mojang.logging.LogUtils;
|
||||||
import info.shylie.apparatus.api.tooltip.SingleItemTooltip;
|
import info.shylie.ashes.api.tooltip.SingleItemTooltip;
|
||||||
import info.shylie.apparatus.datagen.ItemModels;
|
import info.shylie.ashes.datagen.ItemModels;
|
||||||
import info.shylie.apparatus.entity.AshenGolemEntity;
|
import info.shylie.ashes.entity.AshenGolemEntity;
|
||||||
import info.shylie.apparatus.entity.render.AshenGolemRenderer;
|
import info.shylie.ashes.entity.render.AshenGolemRenderer;
|
||||||
import net.minecraft.data.DataGenerator;
|
import net.minecraft.data.DataGenerator;
|
||||||
import net.minecraft.data.PackOutput;
|
import net.minecraft.data.PackOutput;
|
||||||
import net.minecraftforge.api.distmarker.Dist;
|
import net.minecraftforge.api.distmarker.Dist;
|
||||||
@ -25,24 +25,24 @@ import net.minecraftforge.fml.event.lifecycle.FMLCommonSetupEvent;
|
|||||||
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
|
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
|
|
||||||
@Mod(ApparatusMod.MODID)
|
@Mod(Ashes.MODID)
|
||||||
public class ApparatusMod
|
public class Ashes
|
||||||
{
|
{
|
||||||
public static final String MODID = "apparatus";
|
public static final String MODID = "ashes";
|
||||||
public static final Logger LOGGER = LogUtils.getLogger();
|
public static final Logger LOGGER = LogUtils.getLogger();
|
||||||
|
|
||||||
public ApparatusMod() {
|
public Ashes() {
|
||||||
IEventBus modEventBus = FMLJavaModLoadingContext.get().getModEventBus();
|
IEventBus modEventBus = FMLJavaModLoadingContext.get().getModEventBus();
|
||||||
|
|
||||||
modEventBus.addListener(this::commonSetup);
|
modEventBus.addListener(this::commonSetup);
|
||||||
modEventBus.addListener(this::gatherData);
|
modEventBus.addListener(this::gatherData);
|
||||||
modEventBus.addListener(this::entityAttributes);
|
modEventBus.addListener(this::entityAttributes);
|
||||||
|
|
||||||
ApparatusRegistry.BLOCKS.register(modEventBus);
|
AshesRegistry.BLOCKS.register(modEventBus);
|
||||||
ApparatusRegistry.ITEMS.register(modEventBus);
|
AshesRegistry.ITEMS.register(modEventBus);
|
||||||
ApparatusRegistry.ENTITY_TYPES.register(modEventBus);
|
AshesRegistry.ENTITY_TYPES.register(modEventBus);
|
||||||
ApparatusRegistry.CREATIVE_TABS.register(modEventBus);
|
AshesRegistry.CREATIVE_TABS.register(modEventBus);
|
||||||
ApparatusRegistry.RUNES.register(modEventBus);
|
AshesRegistry.RUNES.register(modEventBus);
|
||||||
|
|
||||||
MinecraftForge.EVENT_BUS.register(this);
|
MinecraftForge.EVENT_BUS.register(this);
|
||||||
|
|
||||||
@ -54,7 +54,7 @@ public class ApparatusMod
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void entityAttributes(EntityAttributeCreationEvent event) {
|
private void entityAttributes(EntityAttributeCreationEvent event) {
|
||||||
event.put(ApparatusRegistry.ASHEN_GOLEM.get(), AshenGolemEntity.createAttributes().build());
|
event.put(AshesRegistry.ASHEN_GOLEM.get(), AshenGolemEntity.createAttributes().build());
|
||||||
}
|
}
|
||||||
|
|
||||||
private void gatherData(GatherDataEvent event) {
|
private void gatherData(GatherDataEvent event) {
|
||||||
@ -80,7 +80,7 @@ public class ApparatusMod
|
|||||||
@OnlyIn(Dist.CLIENT)
|
@OnlyIn(Dist.CLIENT)
|
||||||
@SubscribeEvent
|
@SubscribeEvent
|
||||||
public static void registerRenderers(EntityRenderersEvent.RegisterRenderers event) {
|
public static void registerRenderers(EntityRenderersEvent.RegisterRenderers event) {
|
||||||
event.registerEntityRenderer(ApparatusRegistry.ASHEN_GOLEM.get(), AshenGolemRenderer::new);
|
event.registerEntityRenderer(AshesRegistry.ASHEN_GOLEM.get(), AshenGolemRenderer::new);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,15 +1,15 @@
|
|||||||
package info.shylie.apparatus;
|
package info.shylie.ashes;
|
||||||
|
|
||||||
import com.rekindled.embers.RegistryManager;
|
import com.rekindled.embers.RegistryManager;
|
||||||
import com.rekindled.embers.util.Misc;
|
import com.rekindled.embers.util.Misc;
|
||||||
import info.shylie.apparatus.api.rune.Rune;
|
import info.shylie.ashes.api.rune.Rune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import info.shylie.apparatus.entity.AshenGolemEntity;
|
import info.shylie.ashes.entity.AshenGolemEntity;
|
||||||
import info.shylie.apparatus.item.RuneItem;
|
import info.shylie.ashes.item.RuneItem;
|
||||||
import info.shylie.apparatus.rune.param.BlockPosRune;
|
import info.shylie.ashes.rune.param.BlockPosRune;
|
||||||
import info.shylie.apparatus.rune.param.ItemRune;
|
import info.shylie.ashes.rune.param.ItemRune;
|
||||||
import info.shylie.apparatus.rune.task.composite.*;
|
import info.shylie.ashes.rune.task.composite.*;
|
||||||
import info.shylie.apparatus.rune.task.leaf.*;
|
import info.shylie.ashes.rune.task.leaf.*;
|
||||||
import net.minecraft.core.registries.Registries;
|
import net.minecraft.core.registries.Registries;
|
||||||
import net.minecraft.network.chat.Component;
|
import net.minecraft.network.chat.Component;
|
||||||
import net.minecraft.resources.ResourceLocation;
|
import net.minecraft.resources.ResourceLocation;
|
||||||
@ -26,12 +26,12 @@ import net.minecraftforge.registries.*;
|
|||||||
|
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
public class ApparatusRegistry {
|
public class AshesRegistry {
|
||||||
public static final DeferredRegister<Item> ITEMS = DeferredRegister.create(ForgeRegistries.ITEMS, ApparatusMod.MODID);
|
public static final DeferredRegister<Item> ITEMS = DeferredRegister.create(ForgeRegistries.ITEMS, Ashes.MODID);
|
||||||
public static final DeferredRegister<Block> BLOCKS = DeferredRegister.create(ForgeRegistries.BLOCKS, ApparatusMod.MODID);
|
public static final DeferredRegister<Block> BLOCKS = DeferredRegister.create(ForgeRegistries.BLOCKS, Ashes.MODID);
|
||||||
public static final DeferredRegister<EntityType<?>> ENTITY_TYPES = DeferredRegister.create(ForgeRegistries.ENTITY_TYPES, ApparatusMod.MODID);
|
public static final DeferredRegister<EntityType<?>> ENTITY_TYPES = DeferredRegister.create(ForgeRegistries.ENTITY_TYPES, Ashes.MODID);
|
||||||
public static final DeferredRegister<CreativeModeTab> CREATIVE_TABS = DeferredRegister.create(Registries.CREATIVE_MODE_TAB, ApparatusMod.MODID);
|
public static final DeferredRegister<CreativeModeTab> CREATIVE_TABS = DeferredRegister.create(Registries.CREATIVE_MODE_TAB, Ashes.MODID);
|
||||||
public static final DeferredRegister<RuneType<? extends Rune>> RUNES = DeferredRegister.create(new ResourceLocation(ApparatusMod.MODID, "rune"), ApparatusMod.MODID);
|
public static final DeferredRegister<RuneType<? extends Rune>> RUNES = DeferredRegister.create(new ResourceLocation(Ashes.MODID, "rune"), Ashes.MODID);
|
||||||
|
|
||||||
public static final Supplier<IForgeRegistry<RuneType<?>>> RUNE_REGISTRY = RUNES.makeRegistry(RegistryBuilder::new);
|
public static final Supplier<IForgeRegistry<RuneType<?>>> RUNE_REGISTRY = RUNES.makeRegistry(RegistryBuilder::new);
|
||||||
|
|
||||||
@ -41,7 +41,7 @@ public class ApparatusRegistry {
|
|||||||
|
|
||||||
public static final RegistryObject<EntityType<AshenGolemEntity>> ASHEN_GOLEM;
|
public static final RegistryObject<EntityType<AshenGolemEntity>> ASHEN_GOLEM;
|
||||||
|
|
||||||
public static final RegistryObject<CreativeModeTab> APPARATUS_TAB;
|
public static final RegistryObject<CreativeModeTab> ASHES_TAB;
|
||||||
|
|
||||||
public static final RegistryObject<RuneType<BlockPosRune>> BLOCK_POS_RUNE;
|
public static final RegistryObject<RuneType<BlockPosRune>> BLOCK_POS_RUNE;
|
||||||
public static final RegistryObject<RuneType<ItemRune>> ITEM_RUNE;
|
public static final RegistryObject<RuneType<ItemRune>> ITEM_RUNE;
|
||||||
@ -73,14 +73,14 @@ public class ApparatusRegistry {
|
|||||||
() -> EntityType.Builder.of(AshenGolemEntity::new, MobCategory.MISC)
|
() -> EntityType.Builder.of(AshenGolemEntity::new, MobCategory.MISC)
|
||||||
.sized(0.6F, 1.8F)
|
.sized(0.6F, 1.8F)
|
||||||
.fireImmune()
|
.fireImmune()
|
||||||
.build(ApparatusMod.MODID + "ashen_golem")
|
.build(Ashes.MODID + "ashen_golem")
|
||||||
);
|
);
|
||||||
ASHEN_GOLEM_SPAWN_EGG = registerSpawnEgg(ASHEN_GOLEM, Misc.intColor(38, 38, 38), Misc.intColor(66, 66, 66));
|
ASHEN_GOLEM_SPAWN_EGG = registerSpawnEgg(ASHEN_GOLEM, Misc.intColor(38, 38, 38), Misc.intColor(66, 66, 66));
|
||||||
|
|
||||||
APPARATUS_TAB = CREATIVE_TABS.register("apparatus_tab",
|
ASHES_TAB = CREATIVE_TABS.register("ashes_tab",
|
||||||
() -> CreativeModeTab.builder()
|
() -> CreativeModeTab.builder()
|
||||||
.icon(() -> new ItemStack(RegistryManager.INTELLIGENT_APPARATUS.get()))
|
.icon(() -> new ItemStack(RegistryManager.INTELLIGENT_APPARATUS.get()))
|
||||||
.title(Component.translatable("itemgroup." + ApparatusMod.MODID))
|
.title(Component.translatable("itemgroup." + Ashes.MODID))
|
||||||
.withTabsBefore(CreativeModeTabs.SPAWN_EGGS)
|
.withTabsBefore(CreativeModeTabs.SPAWN_EGGS)
|
||||||
.displayItems((params, output) -> {
|
.displayItems((params, output) -> {
|
||||||
for (var item : ITEMS.getEntries()) {
|
for (var item : ITEMS.getEntries()) {
|
@ -1,11 +1,11 @@
|
|||||||
package info.shylie.apparatus;
|
package info.shylie.ashes;
|
||||||
|
|
||||||
import net.minecraftforge.common.ForgeConfigSpec;
|
import net.minecraftforge.common.ForgeConfigSpec;
|
||||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||||
import net.minecraftforge.fml.common.Mod;
|
import net.minecraftforge.fml.common.Mod;
|
||||||
import net.minecraftforge.fml.event.config.ModConfigEvent;
|
import net.minecraftforge.fml.event.config.ModConfigEvent;
|
||||||
|
|
||||||
@Mod.EventBusSubscriber(modid = ApparatusMod.MODID, bus = Mod.EventBusSubscriber.Bus.MOD)
|
@Mod.EventBusSubscriber(modid = Ashes.MODID, bus = Mod.EventBusSubscriber.Bus.MOD)
|
||||||
public class Config
|
public class Config
|
||||||
{
|
{
|
||||||
private static final ForgeConfigSpec.Builder BUILDER = new ForgeConfigSpec.Builder();
|
private static final ForgeConfigSpec.Builder BUILDER = new ForgeConfigSpec.Builder();
|
@ -1,9 +1,8 @@
|
|||||||
package info.shylie.apparatus;
|
package info.shylie.ashes;
|
||||||
|
|
||||||
import java.lang.reflect.Array;
|
import java.lang.reflect.Array;
|
||||||
|
|
||||||
public class Utils {
|
public class Utils {
|
||||||
@SafeVarargs
|
|
||||||
public static <T> T[] concat(T[] b, T... a) {
|
public static <T> T[] concat(T[] b, T... a) {
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
T[] c = (T[])Array.newInstance(a.getClass().getComponentType(), a.length + b.length);
|
T[] c = (T[])Array.newInstance(a.getClass().getComponentType(), a.length + b.length);
|
@ -1,7 +1,7 @@
|
|||||||
package info.shylie.apparatus.api.golem;
|
package info.shylie.ashes.api.golem;
|
||||||
|
|
||||||
import com.mojang.authlib.GameProfile;
|
import com.mojang.authlib.GameProfile;
|
||||||
import info.shylie.apparatus.api.rune.TaskRune;
|
import info.shylie.ashes.api.rune.TaskRune;
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.server.level.ServerLevel;
|
import net.minecraft.server.level.ServerLevel;
|
||||||
import net.minecraft.world.entity.animal.AbstractGolem;
|
import net.minecraft.world.entity.animal.AbstractGolem;
|
@ -1,6 +1,6 @@
|
|||||||
package info.shylie.apparatus.api.rune;
|
package info.shylie.ashes.api.rune;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import net.minecraft.core.NonNullList;
|
import net.minecraft.core.NonNullList;
|
||||||
import net.minecraft.nbt.CompoundTag;
|
import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.nbt.ListTag;
|
import net.minecraft.nbt.ListTag;
|
@ -1,6 +1,6 @@
|
|||||||
package info.shylie.apparatus.api.rune;
|
package info.shylie.ashes.api.rune;
|
||||||
|
|
||||||
import info.shylie.apparatus.ApparatusMod;
|
import info.shylie.ashes.Ashes;
|
||||||
import net.minecraft.nbt.CompoundTag;
|
import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.nbt.ListTag;
|
import net.minecraft.nbt.ListTag;
|
||||||
import net.minecraft.nbt.Tag;
|
import net.minecraft.nbt.Tag;
|
||||||
@ -29,7 +29,7 @@ public abstract class LeafTaskRune extends TaskRune {
|
|||||||
parameters[index] = parameter;
|
parameters[index] = parameter;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
ApparatusMod.LOGGER.warn("Invalid parameter type '{}' provided to leaf of type '{}'", parameter.getTypeID(), getTypeID());
|
Ashes.LOGGER.warn("Invalid parameter type '{}' provided to leaf of type '{}'", parameter.getTypeID(), getTypeID());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package info.shylie.apparatus.api.rune;
|
package info.shylie.ashes.api.rune;
|
||||||
|
|
||||||
import net.minecraft.nbt.CompoundTag;
|
import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.world.InteractionHand;
|
import net.minecraft.world.InteractionHand;
|
@ -1,6 +1,6 @@
|
|||||||
package info.shylie.apparatus.api.rune;
|
package info.shylie.ashes.api.rune;
|
||||||
|
|
||||||
import info.shylie.apparatus.ApparatusRegistry;
|
import info.shylie.ashes.AshesRegistry;
|
||||||
import net.minecraft.nbt.CompoundTag;
|
import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.network.chat.Component;
|
import net.minecraft.network.chat.Component;
|
||||||
import net.minecraft.resources.ResourceLocation;
|
import net.minecraft.resources.ResourceLocation;
|
||||||
@ -17,7 +17,7 @@ public abstract class Rune {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public ResourceLocation getTypeID() {
|
public ResourceLocation getTypeID() {
|
||||||
return ApparatusRegistry.RUNE_REGISTRY.get().getKey(type);
|
return AshesRegistry.RUNE_REGISTRY.get().getKey(type);
|
||||||
}
|
}
|
||||||
|
|
||||||
public Component getTooltip() {
|
public Component getTooltip() {
|
||||||
@ -29,7 +29,7 @@ public abstract class Rune {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void save(CompoundTag tag) {
|
public void save(CompoundTag tag) {
|
||||||
tag.putString(RUNE_TYPE_TAG, ApparatusRegistry.RUNE_REGISTRY.get().getKey(type).toString());
|
tag.putString(RUNE_TYPE_TAG, AshesRegistry.RUNE_REGISTRY.get().getKey(type).toString());
|
||||||
CompoundTag runeData = new CompoundTag();
|
CompoundTag runeData = new CompoundTag();
|
||||||
saveImpl(runeData);
|
saveImpl(runeData);
|
||||||
tag.put(RUNE_DATA_TAG, runeData);
|
tag.put(RUNE_DATA_TAG, runeData);
|
||||||
@ -52,7 +52,7 @@ public abstract class Rune {
|
|||||||
ResourceLocation location = ResourceLocation.tryParse(tag.getString(RUNE_TYPE_TAG));
|
ResourceLocation location = ResourceLocation.tryParse(tag.getString(RUNE_TYPE_TAG));
|
||||||
if (location == null) { return null; }
|
if (location == null) { return null; }
|
||||||
|
|
||||||
RuneType<?> type = ApparatusRegistry.RUNE_REGISTRY.get().getValue(location);
|
RuneType<?> type = AshesRegistry.RUNE_REGISTRY.get().getValue(location);
|
||||||
if (type == null) { return null; }
|
if (type == null) { return null; }
|
||||||
|
|
||||||
Rune rune = type.create();
|
Rune rune = type.create();
|
@ -1,6 +1,6 @@
|
|||||||
package info.shylie.apparatus.api.rune;
|
package info.shylie.ashes.api.rune;
|
||||||
|
|
||||||
import info.shylie.apparatus.ApparatusRegistry;
|
import info.shylie.ashes.AshesRegistry;
|
||||||
|
|
||||||
public class RuneType<T extends Rune> {
|
public class RuneType<T extends Rune> {
|
||||||
private final RuneFactory<T> factory;
|
private final RuneFactory<T> factory;
|
||||||
@ -15,7 +15,7 @@ public class RuneType<T extends Rune> {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return ApparatusRegistry.RUNE_REGISTRY.get().getKey(this).toString();
|
return AshesRegistry.RUNE_REGISTRY.get().getKey(this).toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public interface RuneFactory<T extends Rune> {
|
public interface RuneFactory<T extends Rune> {
|
@ -1,6 +1,6 @@
|
|||||||
package info.shylie.apparatus.api.rune;
|
package info.shylie.ashes.api.rune;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
|
|
||||||
public abstract class TaskRune extends Rune {
|
public abstract class TaskRune extends Rune {
|
||||||
boolean ran;
|
boolean ran;
|
@ -1,9 +1,9 @@
|
|||||||
package info.shylie.apparatus.api.rune.leaf;
|
package info.shylie.ashes.api.rune.leaf;
|
||||||
|
|
||||||
import info.shylie.apparatus.Utils;
|
import info.shylie.ashes.Utils;
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.LeafTaskRune;
|
import info.shylie.ashes.api.rune.LeafTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.world.level.block.entity.BlockEntity;
|
import net.minecraft.world.level.block.entity.BlockEntity;
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package info.shylie.apparatus.api.tooltip;
|
package info.shylie.ashes.api.tooltip;
|
||||||
|
|
||||||
import net.minecraft.client.gui.Font;
|
import net.minecraft.client.gui.Font;
|
||||||
import net.minecraft.client.gui.GuiGraphics;
|
import net.minecraft.client.gui.GuiGraphics;
|
||||||
@ -7,6 +7,7 @@ import net.minecraft.resources.ResourceLocation;
|
|||||||
import net.minecraft.world.inventory.tooltip.TooltipComponent;
|
import net.minecraft.world.inventory.tooltip.TooltipComponent;
|
||||||
import net.minecraft.world.item.Item;
|
import net.minecraft.world.item.Item;
|
||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
||||||
|
import net.minecraft.world.item.Items;
|
||||||
|
|
||||||
public class SingleItemTooltip implements TooltipComponent {
|
public class SingleItemTooltip implements TooltipComponent {
|
||||||
private final Item item;
|
private final Item item;
|
@ -1,7 +1,7 @@
|
|||||||
package info.shylie.apparatus.datagen;
|
package info.shylie.ashes.datagen;
|
||||||
|
|
||||||
import info.shylie.apparatus.ApparatusMod;
|
import info.shylie.ashes.Ashes;
|
||||||
import info.shylie.apparatus.ApparatusRegistry;
|
import info.shylie.ashes.AshesRegistry;
|
||||||
import net.minecraft.data.PackOutput;
|
import net.minecraft.data.PackOutput;
|
||||||
import net.minecraft.resources.ResourceLocation;
|
import net.minecraft.resources.ResourceLocation;
|
||||||
import net.minecraft.world.item.Item;
|
import net.minecraft.world.item.Item;
|
||||||
@ -11,14 +11,14 @@ import net.minecraftforge.registries.RegistryObject;
|
|||||||
|
|
||||||
public class ItemModels extends ItemModelProvider {
|
public class ItemModels extends ItemModelProvider {
|
||||||
public ItemModels(PackOutput gen, ExistingFileHelper exFileHelper) {
|
public ItemModels(PackOutput gen, ExistingFileHelper exFileHelper) {
|
||||||
super(gen, ApparatusMod.MODID, exFileHelper);
|
super(gen, Ashes.MODID, exFileHelper);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void registerModels() {
|
protected void registerModels() {
|
||||||
basicItem(ApparatusRegistry.HEATED_ASHY_INGOT.get());
|
basicItem(AshesRegistry.HEATED_ASHY_INGOT.get());
|
||||||
basicItem(ApparatusRegistry.RUNE.get());
|
basicItem(AshesRegistry.RUNE.get());
|
||||||
spawnEgg(ApparatusRegistry.ASHEN_GOLEM_SPAWN_EGG);
|
spawnEgg(AshesRegistry.ASHEN_GOLEM_SPAWN_EGG);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void itemWithTexture(RegistryObject<? extends Item> registryObject, String texture) {
|
private void itemWithTexture(RegistryObject<? extends Item> registryObject, String texture) {
|
@ -1,10 +1,10 @@
|
|||||||
package info.shylie.apparatus.entity;
|
package info.shylie.ashes.entity;
|
||||||
|
|
||||||
import com.rekindled.embers.datagen.EmbersSounds;
|
import com.rekindled.embers.datagen.EmbersSounds;
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.Rune;
|
import info.shylie.ashes.api.rune.Rune;
|
||||||
import info.shylie.apparatus.api.rune.TaskRune;
|
import info.shylie.ashes.api.rune.TaskRune;
|
||||||
import info.shylie.apparatus.entity.ai.GolemTaskGoal;
|
import info.shylie.ashes.entity.ai.GolemTaskGoal;
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.nbt.CompoundTag;
|
import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.sounds.SoundEvent;
|
import net.minecraft.sounds.SoundEvent;
|
@ -1,7 +1,8 @@
|
|||||||
package info.shylie.apparatus.entity.ai;
|
package info.shylie.ashes.entity.ai;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.TaskRune;
|
import info.shylie.ashes.api.rune.TaskRune;
|
||||||
|
import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.world.entity.ai.goal.Goal;
|
import net.minecraft.world.entity.ai.goal.Goal;
|
||||||
|
|
||||||
public class GolemTaskGoal extends Goal {
|
public class GolemTaskGoal extends Goal {
|
@ -1,10 +1,10 @@
|
|||||||
package info.shylie.apparatus.entity.render;
|
package info.shylie.ashes.entity.render;
|
||||||
|
|
||||||
import com.rekindled.embers.Embers;
|
import com.rekindled.embers.Embers;
|
||||||
import com.rekindled.embers.entity.render.AncientGolemEyeLayer;
|
import com.rekindled.embers.entity.render.AncientGolemEyeLayer;
|
||||||
import com.rekindled.embers.model.AncientGolemModel;
|
import com.rekindled.embers.model.AncientGolemModel;
|
||||||
import info.shylie.apparatus.ApparatusMod;
|
import info.shylie.ashes.Ashes;
|
||||||
import info.shylie.apparatus.entity.AshenGolemEntity;
|
import info.shylie.ashes.entity.AshenGolemEntity;
|
||||||
import net.minecraft.client.model.geom.ModelLayerLocation;
|
import net.minecraft.client.model.geom.ModelLayerLocation;
|
||||||
import net.minecraft.client.renderer.entity.EntityRendererProvider;
|
import net.minecraft.client.renderer.entity.EntityRendererProvider;
|
||||||
import net.minecraft.client.renderer.entity.MobRenderer;
|
import net.minecraft.client.renderer.entity.MobRenderer;
|
||||||
@ -15,7 +15,7 @@ import net.minecraftforge.api.distmarker.OnlyIn;
|
|||||||
@OnlyIn(Dist.CLIENT)
|
@OnlyIn(Dist.CLIENT)
|
||||||
public class AshenGolemRenderer extends MobRenderer<AshenGolemEntity, AncientGolemModel<AshenGolemEntity>> {
|
public class AshenGolemRenderer extends MobRenderer<AshenGolemEntity, AncientGolemModel<AshenGolemEntity>> {
|
||||||
public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation(new ResourceLocation(Embers.MODID, "ancient_golem"), "main");
|
public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation(new ResourceLocation(Embers.MODID, "ancient_golem"), "main");
|
||||||
public static final ResourceLocation TEXTURE = new ResourceLocation(ApparatusMod.MODID, "textures/entity/golem.png");
|
public static final ResourceLocation TEXTURE = new ResourceLocation(Ashes.MODID, "textures/entity/golem.png");
|
||||||
|
|
||||||
public AshenGolemRenderer(EntityRendererProvider.Context context) {
|
public AshenGolemRenderer(EntityRendererProvider.Context context) {
|
||||||
super(context, new AncientGolemModel<>(context.bakeLayer(LAYER_LOCATION)), 0.5F);
|
super(context, new AncientGolemModel<>(context.bakeLayer(LAYER_LOCATION)), 0.5F);
|
@ -1,7 +1,7 @@
|
|||||||
package info.shylie.apparatus.item;
|
package info.shylie.ashes.item;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.*;
|
import info.shylie.ashes.api.rune.*;
|
||||||
import net.minecraft.Util;
|
import net.minecraft.Util;
|
||||||
import net.minecraft.network.chat.Component;
|
import net.minecraft.network.chat.Component;
|
||||||
import net.minecraft.world.InteractionHand;
|
import net.minecraft.world.InteractionHand;
|
@ -1,7 +1,7 @@
|
|||||||
package info.shylie.apparatus.rune.param;
|
package info.shylie.ashes.rune.param;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.rune.ParameterRune;
|
import info.shylie.ashes.api.rune.ParameterRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import net.minecraft.ChatFormatting;
|
import net.minecraft.ChatFormatting;
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.nbt.CompoundTag;
|
import net.minecraft.nbt.CompoundTag;
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.param;
|
package info.shylie.ashes.rune.param;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.rune.ParameterRune;
|
import info.shylie.ashes.api.rune.ParameterRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import info.shylie.apparatus.api.tooltip.SingleItemTooltip;
|
import info.shylie.ashes.api.tooltip.SingleItemTooltip;
|
||||||
import net.minecraft.nbt.CompoundTag;
|
import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.resources.ResourceLocation;
|
import net.minecraft.resources.ResourceLocation;
|
||||||
import net.minecraft.world.inventory.tooltip.TooltipComponent;
|
import net.minecraft.world.inventory.tooltip.TooltipComponent;
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.composite;
|
package info.shylie.ashes.rune.task.composite;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.CompositeTaskRune;
|
import info.shylie.ashes.api.rune.CompositeTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
|
|
||||||
public class InverterRune extends CompositeTaskRune {
|
public class InverterRune extends CompositeTaskRune {
|
||||||
public InverterRune(RuneType<? extends InverterRune> type) {
|
public InverterRune(RuneType<? extends InverterRune> type) {
|
@ -1,9 +1,9 @@
|
|||||||
package info.shylie.apparatus.rune.task.composite;
|
package info.shylie.ashes.rune.task.composite;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.CompositeTaskRune;
|
import info.shylie.ashes.api.rune.CompositeTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import info.shylie.apparatus.api.rune.TaskRune;
|
import info.shylie.ashes.api.rune.TaskRune;
|
||||||
|
|
||||||
public class SelectorRune extends CompositeTaskRune {
|
public class SelectorRune extends CompositeTaskRune {
|
||||||
public SelectorRune(RuneType<? extends SelectorRune> type) {
|
public SelectorRune(RuneType<? extends SelectorRune> type) {
|
@ -1,9 +1,9 @@
|
|||||||
package info.shylie.apparatus.rune.task.composite;
|
package info.shylie.ashes.rune.task.composite;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import info.shylie.apparatus.api.rune.TaskRune;
|
import info.shylie.ashes.api.rune.TaskRune;
|
||||||
import info.shylie.apparatus.api.rune.CompositeTaskRune;
|
import info.shylie.ashes.api.rune.CompositeTaskRune;
|
||||||
|
|
||||||
public class SequenceRune extends CompositeTaskRune {
|
public class SequenceRune extends CompositeTaskRune {
|
||||||
public SequenceRune(RuneType<? extends SequenceRune> type) {
|
public SequenceRune(RuneType<? extends SequenceRune> type) {
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.composite;
|
package info.shylie.ashes.rune.task.composite;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.CompositeTaskRune;
|
import info.shylie.ashes.api.rune.CompositeTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
|
|
||||||
public class StepSelectorRune extends CompositeTaskRune {
|
public class StepSelectorRune extends CompositeTaskRune {
|
||||||
private int current;
|
private int current;
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.composite;
|
package info.shylie.ashes.rune.task.composite;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.CompositeTaskRune;
|
import info.shylie.ashes.api.rune.CompositeTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
|
|
||||||
public class StepSequenceRune extends CompositeTaskRune {
|
public class StepSequenceRune extends CompositeTaskRune {
|
||||||
private int current;
|
private int current;
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.leaf;
|
package info.shylie.ashes.rune.task.leaf;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.LeafTaskRune;
|
import info.shylie.ashes.api.rune.LeafTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import net.minecraft.world.item.Item;
|
import net.minecraft.world.item.Item;
|
||||||
|
|
||||||
public class HasItemRune extends LeafTaskRune {
|
public class HasItemRune extends LeafTaskRune {
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.leaf;
|
package info.shylie.ashes.rune.task.leaf;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.LeafTaskRune;
|
import info.shylie.ashes.api.rune.LeafTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.core.Direction;
|
import net.minecraft.core.Direction;
|
||||||
import net.minecraft.world.InteractionHand;
|
import net.minecraft.world.InteractionHand;
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.leaf;
|
package info.shylie.ashes.rune.task.leaf;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.LeafTaskRune;
|
import info.shylie.ashes.api.rune.LeafTaskRune;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.world.entity.MoverType;
|
import net.minecraft.world.entity.MoverType;
|
||||||
import net.minecraft.world.entity.animal.AbstractGolem;
|
import net.minecraft.world.entity.animal.AbstractGolem;
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.leaf;
|
package info.shylie.ashes.rune.task.leaf;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import info.shylie.apparatus.api.rune.leaf.BEInteractRune;
|
import info.shylie.ashes.api.rune.leaf.BEInteractRune;
|
||||||
import net.minecraft.world.InteractionHand;
|
import net.minecraft.world.InteractionHand;
|
||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
||||||
import net.minecraft.world.level.block.entity.BlockEntity;
|
import net.minecraft.world.level.block.entity.BlockEntity;
|
@ -1,8 +1,8 @@
|
|||||||
package info.shylie.apparatus.rune.task.leaf;
|
package info.shylie.ashes.rune.task.leaf;
|
||||||
|
|
||||||
import info.shylie.apparatus.api.golem.IGolem;
|
import info.shylie.ashes.api.golem.IGolem;
|
||||||
import info.shylie.apparatus.api.rune.RuneType;
|
import info.shylie.ashes.api.rune.RuneType;
|
||||||
import info.shylie.apparatus.api.rune.leaf.BEInteractRune;
|
import info.shylie.ashes.api.rune.leaf.BEInteractRune;
|
||||||
import net.minecraft.world.InteractionHand;
|
import net.minecraft.world.InteractionHand;
|
||||||
import net.minecraft.world.item.Item;
|
import net.minecraft.world.item.Item;
|
||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
BIN
src/main/resources/assets/apparatus/textures/block/inscriber.png
(Stored with Git LFS)
BIN
src/main/resources/assets/apparatus/textures/block/inscriber.png
(Stored with Git LFS)
Binary file not shown.
BIN
src/main/resources/assets/inscriber.bbmodel
(Stored with Git LFS)
BIN
src/main/resources/assets/inscriber.bbmodel
(Stored with Git LFS)
Binary file not shown.
Loading…
Reference in New Issue
Block a user