This commit is contained in:
Flanks255 2021-11-26 16:52:59 -06:00
parent 62754fc72d
commit 7d536b06ba
6 changed files with 18 additions and 5 deletions

View file

@ -227,6 +227,7 @@ bbd32f2ac5a2a55332aa9b73fd06aa1462fdd29a assets/actuallyadditions/models/item/ba
14391f4c4d029a354d40a7aa26af4f279dba6684 assets/actuallyadditions/models/item/black_quartz_brick_slab.json
c3cf76ca67515c059d3eaf6b70369151a4f29831 assets/actuallyadditions/models/item/black_quartz_brick_stair.json
fb3f2411b48e77c8230b9c9316ac7d214e505032 assets/actuallyadditions/models/item/black_quartz_brick_wall.json
cd408ce9d0cc7ab33fe7327af3ebcc177fef6690 assets/actuallyadditions/models/item/black_quartz_ore.json
50075e8e8b428b161113d45d583f6eae5e8360f3 assets/actuallyadditions/models/item/black_quartz_pillar_block.json
5614453539110f6214c52d47c12aa1ce05447d53 assets/actuallyadditions/models/item/black_quartz_pillar_slab.json
3bd2d755493ff85b07dff3cb31d0cc040e6150c5 assets/actuallyadditions/models/item/black_quartz_pillar_stair.json
@ -239,6 +240,7 @@ f3282e55e71d26a32cee1287881ac2d5e91c30a8 assets/actuallyadditions/models/item/ca
08c70d561c219bb4c6d21b5f56192df81f054e0a assets/actuallyadditions/models/item/canola_press.json
0507025fadef30e363cbc825265576c782880f7b assets/actuallyadditions/models/item/canola_seeds.json
b0f7c3915b646ccd27ca6ff40517e19e2a0fb7ef assets/actuallyadditions/models/item/canolaoil.json
83b47876ba2c85d3ba83e36ee9b02a8d458f7230 assets/actuallyadditions/models/item/charcoal_block.json
36179c5cc77dc38364a1931f2fabbf846ef9c39d assets/actuallyadditions/models/item/chiseled_black_quartz_block.json
27c8ed9e39b600161a6a327db0ac53e10acc13bb assets/actuallyadditions/models/item/chiseled_black_quartz_slab.json
0b574626d1648584c3afa6ee0ccc974fb68bb425 assets/actuallyadditions/models/item/chiseled_black_quartz_stair.json

View file

@ -145,8 +145,10 @@ public class ActuallyAdditions {
}
private void onConfigReload(ModConfig.ModConfigEvent event) {
Item item = ForgeRegistries.ITEMS.getValue(new ResourceLocation(CommonConfig.OTHER.REDSTONECONFIGURATOR.get()));
CommonConfig.OTHER.redstoneConfigureItem = item != null?item: Items.AIR;
Item item1 = ForgeRegistries.ITEMS.getValue(new ResourceLocation(CommonConfig.OTHER.REDSTONECONFIGURATOR.get()));
Item item2 = ForgeRegistries.ITEMS.getValue(new ResourceLocation(CommonConfig.OTHER.RELAYCONFIGURATOR.get()));
CommonConfig.OTHER.redstoneConfigureItem = item1 != null?item1: Items.AIR;
CommonConfig.OTHER.relayConfigureItem = item2 != null?item2: Items.AIR;
}
private void clientSetup(FMLClientSetupEvent event) {

View file

@ -208,6 +208,10 @@ public final class ActuallyBlocks {
// Misc building blocks
public static final AABlockReg<ActuallyBlock, AABlockItem, ?> ENDER_PEARL_BLOCK = new AABlockReg<>("ender_pearl_block", () -> new ActuallyBlock(miscBlockProperties),
(b) -> new AABlockItem(b, defaultBlockItemProperties));
public static final AABlockReg<ActuallyBlock, AABlockItem, ?> CHARCOAL_BLOCK = new AABlockReg<>("charcoal_block", () -> new ActuallyBlock(miscBlockProperties),
(b) -> new AABlockItem(b, defaultBlockItemProperties));
public static final AABlockReg<ActuallyBlock, AABlockItem, ?> BLACK_QUARTZ_ORE = new AABlockReg<>("black_quartz_ore", () -> new ActuallyBlock(miscBlockProperties),
(b) -> new AABlockItem(b, defaultBlockItemProperties));
public static final AABlockReg<ActuallyBlock, AABlockItem, ?> ETHETIC_GREEN_BLOCK = new AABlockReg<>("ethetic_green_block", () -> new ActuallyBlock(miscBlockProperties), (b) -> new AABlockItem(b, defaultBlockItemProperties));
public static final AABlockReg<ActuallyBlock, AABlockItem, ?> ETHETIC_WHITE_BLOCK = new AABlockReg<>("ethetic_white_block", () -> new ActuallyBlock(miscBlockProperties), (b) -> new AABlockItem(b, defaultBlockItemProperties));
@ -254,6 +258,7 @@ public final class ActuallyBlocks {
public static final AABlockReg<BlockTinyTorch, AABlockItem, ?> TINY_TORCH = new AABlockReg<>("tiny_torch", BlockTinyTorch::new,
(b) -> new AABlockItem(b, defaultBlockItemProperties));
//public static final AABlockReg<> WILD_PLANT = new AABlockReg<>("wild", BlockWildPlant::new); //TODO: what is this?
//TODO: Are plants normal blocks / blockitems? i have no idea... news at 11...

View file

@ -15,6 +15,7 @@ import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.laser.Network;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.blocks.base.FullyDirectionalBlock;
import de.ellpeck.actuallyadditions.mod.config.CommonConfig;
import de.ellpeck.actuallyadditions.mod.config.ConfigValues;
import de.ellpeck.actuallyadditions.mod.items.ItemEngineerGoggles;
import de.ellpeck.actuallyadditions.mod.items.ItemLaserRelayUpgrade;
@ -187,7 +188,7 @@ public class BlockLaserRelay extends FullyDirectionalBlock.Container implements
if (compass) {
expl = relay.getCompassDisplayString();
} else {
expl = TextFormatting.GRAY.toString() + TextFormatting.ITALIC + StringUtil.localizeFormatted("info." + ActuallyAdditions.MODID + ".laserRelay.mode.noCompasss", StringUtil.localize(ConfigValues.itemCompassConfigurator.getDescriptionId() + ".name"));
expl = TextFormatting.GRAY.toString() + TextFormatting.ITALIC + StringUtil.localizeFormatted("info." + ActuallyAdditions.MODID + ".laserRelay.mode.noCompasss", StringUtil.localize(CommonConfig.OTHER.relayConfigureItem.getDescriptionId() + ".name"));
}
StringUtil.drawSplitString(minecraft.font, expl, resolution.getGuiScaledWidth() / 2 + 5, resolution.getGuiScaledHeight() / 2 + 15, Integer.MAX_VALUE, StringUtil.DECIMAL_COLOR_WHITE, true);

View file

@ -33,7 +33,9 @@ public class CommonConfig {
public static ForgeConfigSpec.BooleanValue MOST_BLAND_PERSON_EVER;
public static ForgeConfigSpec.IntValue ELEVEN;
public static ForgeConfigSpec.ConfigValue<String> REDSTONECONFIGURATOR;
public static ForgeConfigSpec.ConfigValue<String> RELAYCONFIGURATOR;
public static Item redstoneConfigureItem = Items.AIR;
public static Item relayConfigureItem = Items.AIR;
public static void build() {
@ -89,6 +91,7 @@ public class CommonConfig {
ELEVEN = BUILDER.comment("11?").defineInRange("whatIs11", 11, 0, 12);
REDSTONECONFIGURATOR = BUILDER.comment("define the item used to configure Redstone Mode").define("redstoneConfigurator", Items.REDSTONE_TORCH.getRegistryName().toString(), obj -> obj instanceof String && ResourceLocation.isValidResourceLocation((String) obj));
RELAYCONFIGURATOR = BUILDER.comment("define the item used to configure Direction in laser relays").define("relayConfigurator", Items.COMPASS.getRegistryName().toString(), obj -> obj instanceof String && ResourceLocation.isValidResourceLocation((String) obj));
BUILDER.pop();
}

View file

@ -100,8 +100,8 @@ public final class PlayerData {
ListNBT bookmarks = new ListNBT();
for (IBookletPage bookmark : this.bookmarks) {
bookmarks.add(StringNBT.valueOf(bookmark == null
? ""
: bookmark.getIdentifier()));
? ""
: bookmark.getIdentifier()));
}
return bookmarks;
}