Created
May 17, 2017 22:28
-
-
Save JamiesWhiteShirt/a297fa80bd21ba65fe0db8505078bd6d to your computer and use it in GitHub Desktop.
Annotation based configuration with Kotlin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.jamieswhiteshirt.responsiveinventory | |
import net.minecraftforge.common.config.Config | |
@Config(modid = ResponsiveInventory.MODID) | |
object Configuration { | |
@JvmField | |
@Config.Comment("It's a test") | |
var test = 0 | |
@JvmField | |
val testCategory = ItemSounds() | |
class ItemSounds { | |
@Config.Comment("Play sounds for items in inventories") | |
@JvmField | |
var inventory = true | |
@Config.Comment("Play sounds for items in main hand") | |
@JvmField | |
var mainHand = true | |
@Config.Comment("Play sounds for items in off hand") | |
@JvmField | |
var offHand = true | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Configuration file | |
general { | |
# It's a test | |
I:test=0 | |
instance { | |
} | |
testcategory { | |
# Play sounds for items in inventories | |
B:inventory=true | |
# Play sounds for items in main hand | |
B:mainHand=true | |
# Play sounds for items in off hand | |
B:offHand=true | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment