FallingTree

FallingTree

28M Downloads

[1.16.5] Blacklisted Tinker's Tool Not Working

conneich opened this issue ยท 4 comments

commented

Describe the bug

In testing for a modpack I tried to add a Tinker's Construct tool to the tools blacklist but Minecraft crashes on startup with this error: "Invalid value tconstruct:broad_axe - Expected the boolean value true."

Minecraft version

1.16.5

Forge version

32

Mod version

2.11.5

Relevant log output

net.minecraftforge.fml.config.ConfigFileTypeHandler$ConfigLoadingException: Failed loading config file fallingtree-common.toml of type COMMON for modid fallingtree
	at net.minecraftforge.fml.config.ConfigFileTypeHandler.lambda$reader$1(ConfigFileTypeHandler.java:61) ~[?:?] {re:classloading}
	at net.minecraftforge.fml.config.ConfigFileTypeHandler$$Lambda$7074/148908860.apply(Unknown Source) ~[?:?] {}
	at net.minecraftforge.fml.config.ConfigTracker.openConfig(ConfigTracker.java:104) ~[?:?] {re:classloading}
	at net.minecraftforge.fml.config.ConfigTracker.lambda$loadConfigs$1(ConfigTracker.java:83) ~[?:?] {re:classloading}
	at net.minecraftforge.fml.config.ConfigTracker$$Lambda$7073/648759476.accept(Unknown Source) ~[?:?] {}
	at java.lang.Iterable.forEach(Iterable.java:75) ~[?:1.8.0_51] {}
	at java.util.Collections$SynchronizedCollection.forEach(Collections.java:2062) ~[?:1.8.0_51] {}
	at net.minecraftforge.fml.config.ConfigTracker.loadConfigs(ConfigTracker.java:83) ~[?:?] {re:classloading}
	at net.minecraftforge.fml.ModLoader.loadMods(ModLoader.java:209) ~[?:?] {re:classloading}
	at net.minecraftforge.fml.client.ClientModLoader.lambda$startModLoading$7(ClientModLoader.java:132) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
	at net.minecraftforge.fml.client.ClientModLoader$$Lambda$7066/83127926.run(Unknown Source) ~[?:?] {}
	at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$4(ClientModLoader.java:123) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
	at net.minecraftforge.fml.client.ClientModLoader$$Lambda$2939/1911586923.run(Unknown Source) ~[?:?] {}
	at net.minecraftforge.fml.client.ClientModLoader.startModLoading(ClientModLoader.java:132) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
	at net.minecraftforge.fml.client.ClientModLoader.lambda$onResourceReload$2(ClientModLoader.java:114) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
	at net.minecraftforge.fml.client.ClientModLoader$$Lambda$7062/714710118.run(Unknown Source) ~[?:?] {}
	at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$4(ClientModLoader.java:123) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
	at net.minecraftforge.fml.client.ClientModLoader$$Lambda$2939/1911586923.run(Unknown Source) ~[?:?] {}
	at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1618) ~[?:1.8.0_51] {}
	at java.util.concurrent.CompletableFuture$AsyncRun.exec(CompletableFuture.java:1610) ~[?:1.8.0_51] {}
	at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) ~[?:1.8.0_51] {}
	at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056) ~[?:1.8.0_51] {}
	at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1689) ~[?:1.8.0_51] {}
	at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157) ~[?:1.8.0_51] {}
Caused by: com.electronwill.nightconfig.core.io.ParsingException: Invalid value tconstruct:broad_axe - Expected the boolean value true.
	at com.electronwill.nightconfig.toml.ValueParser.parseTrue(ValueParser.java:175) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.ValueParser.parse(ValueParser.java:46) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.ArrayParser.parse(ArrayParser.java:31) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.ValueParser.parse(ValueParser.java:32) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.ValueParser.parse(ValueParser.java:68) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.TableParser.parseNormal(TableParser.java:57) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.TableParser.parseNormal(TableParser.java:101) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.TomlParser.parse(TomlParser.java:88) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.toml.TomlParser.parse(TomlParser.java:37) ~[toml-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.core.io.ConfigParser.parse(ConfigParser.java:113) ~[core-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.core.io.ConfigParser.parse(ConfigParser.java:219) ~[core-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.core.io.ConfigParser.parse(ConfigParser.java:202) ~[core-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.core.file.WriteSyncFileConfig.load(WriteSyncFileConfig.java:73) ~[core-3.6.3.jar:?] {}
	at com.electronwill.nightconfig.core.file.AutosaveCommentedFileConfig.load(AutosaveCommentedFileConfig.java:85) ~[core-3.6.3.jar:?] {}
	at net.minecraftforge.fml.config.ConfigFileTypeHandler.lambda$reader$1(ConfigFileTypeHandler.java:57) ~[?:?] {re:classloading}
	... 23 more
commented

Can you share the content of your config file?

commented
reverse_sneaking = false
#When set to true, the mod will, cut down trees in creative too.
break_in_creative = false

#Falling Tree configuration
[trees]
	#How to break the tree.
	#INSTANTANEOUS will break it in one go.
	#SHIFT_DOWN will make the tree fall down as you cut it, so you still have to break x blocks but don't have to climb the tree for them.
	#Allowed Values: INSTANTANEOUS, SHIFT_DOWN
	break_mode = "SHIFT_DOWN"
	#What part of the tree should be cut.
	#WHOLE_TREE tree will break the whole tree.
	#ABOVE_CUT will break only blocks that are connected from above the cut point.
	#ABOVE_Y will break only blocks that are above the y value of the cut point.
	#Allowed Values: WHOLE_TREE, ABOVE_CUT, ABOVE_Y
	detection_mode = "ABOVE_CUT"
	#Additional list of blocks considered as logs and that will be destroyed by the mod.
	#INFO: Blocks marked with the log tag will already be whitelisted.
	logs_whitelisted = []
	#List of blocks that should not be considered as logs.
	#INFO: This wins over the whitelist.
	logs_blacklisted = []
	#Additional list of blocks considered as leaves (decay naturally).
	#INFO: Blocks marked with the leaves tag will already be whitelisted.
	leaves_whitelisted = []
	#Additional list of blocks considered as leaves but that doesn't decay (need to be broken by tool).
	leaves_non_decay_whitelisted = []
	#List of blocks that should not be considered as leaves.
	#INFO: This wins over the whitelist.
	leaves_blacklisted = []
	#The maximum size of a tree. If there's more logs than this value the tree won't be cut.
	#Range: > 1
	logs_max_count = 100
	#When set to true, the mod will cut trees with one cut.
	tree_breaking = true
	#When set to true, leaves that should naturally break will be broken instantly.
	leaves_breaking = true
	#Radius to force break leaves. If another tree is still holding the leaves they'll still be broken.
	#If the leaves are persistent (placed by player) they'll also be destroyed.
	#The radius is applied from one of the top most log blocks.
	#INFO: break_leaves must be activated for this to take effect.
	#INFO: Only in INSTANTANEOUS mode.
	#Range: 0 ~ 10
	leaves_breaking_force_radius = 0
	#The minimum amount of leaves that needs to be around the top most log in order for the mod to consider it a tree.
	#INFO: Only in INSTANTANEOUS mode.
	#Range: 0 ~ 5
	minimum_leaves_around_required = 1
	#When set to true this allow to have any kind of log in a tree trunk.
	#Otherwise (false) the trunk will be considered as being only one kind of log.
	allow_mixed_logs = false
	#When set to true nether tree warts (leaves) will be broken along with the trunk.
	break_nether_tree_warts = true
	#This defines the area in which the tree is searched. If any branch is going out of this area it won't be cut.
	#This value is the radius of the area.
	#i.e. Setting a value of 2 will result on an area of 3x3 centered on the log broken.
	#If this value is set to a negative number then no area restriction will be applied.
	#Range: > -2147483648
	search_around_radius = -1
	#List the blocks that can be against the tree. If something else is adjacent then the tree won't be cut.
	#INFO: Use adjacentStopMode to define how we stop the search for the tree.
	adjacent_blocks_whitelisted = []
	#What to do when an non whitelisted adjacent block is found.
	#STOP_ALL will stop the search and nothing will be cut.
	#STOP_BRANCH will stop the current branch only. The rest of the tree will be cut.
	#Allowed Values: STOP_ALL, STOP_BRANCH
	adjacent_stop_mode = "STOP_ALL"

[tools]
	#When set to true, the mod will be activated no matter what you have in your hand (or empty hand).
	#INFO: Blacklist still can be use to restrict some tools.
	ignore_tools = true
	#Additional list of tools that can be used to chop down a tree.
	#INFO: Items marked with the axe tag will already be whitelisted.
	whitelisted = []
	#List of tools that should not be considered as tools.
	#INFO: This wins over the whitelist.
	blacklisted = [tconstruct:broad_axe]
	#Defines the number of times the damage is applied to the tool.
	#ie: if set to 1 then breaking 5 logs will give 5 damage.
	#ie: if set to 2 then breaking 5 logs will give 10 damage.
	#If set to 0, it'll still apply 1 damage for every cut.
	#INFO: This only applies when the tree is cut when using the mod.
	#Range: > 0
	damage_multiplicand = 1
	#Applies a speed modifier when breaking the tree.
	#0 will disable this, so the speed will be the default one of breaking a block.
	#If set to 1 each log block will be counted once, so if the tree is 5 blocks tall it'll require the time of breaking 5 logs.
	#If set to 2 each log block will be counted twice, so if the tree is 5 blocks tall, it'll require the time of breaking 10 logs
	#INFO: Only in INSTANTANEOUS mode.
	#WARNING: If you are on a server, this either has to be set to 0 or every player should have the mod. Else they'll have a weird effect of breaking the block but the block is still there.
	#Range: 0.0 ~ 50.0
	speed_multiplicand = 0.0
	#When set to true, when a tree is broken and the tool is about to break we will just break enough blocks so that the tool is left at 1 of durability.
	preserve = true```
commented

Try replacing blacklisted = [tconstruct:broad_axe] with blacklisted = ["tconstruct:broad_axe"]. The blacklisted is an array of strings so key = ["value1","value2","value3"].

(You have an example here https://github.com/RakSrinaNa/FallingTree/wiki/Settings---Examples#forge)

commented

Jeeze I program and that just r/whoosh'ed me lol I even looked at the examples! Sorry but thanks for the quick help!