blob: cec91593e75d21c5695ce85b28020628f1b564db (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
# KotlinForForge
Makes Kotlin forge-friendly by doing the following:
- Provides the Kotlin libraries.
- Provides `KotlinLanguageProvider` to allow usage of object declarations as @Mod targets.
- Provides `AutoKotlinEventBusSubscriber` to allow usage of object declarations as @Mod.EventBusSubscriber targets.
- Provides useful top-level utility functions and constants
To implement in your project, add the following to your build.gradle:
```groovy
repositories {
maven {
name = 'kotlinforforge'
url = 'https://thedarkcolour.github.io/KotlinForForge/'
}
}
dependencies {
// Uses the latest version of KotlinForForge
implementation 'thedarkcolour:kotlinforforge:1+'
}
```
Then, add the following to your mods.toml file:
```toml
modLoader="kotlinforforge"
loaderVersion="[1,)"
```
Use
```thedarkcolour.kotlinforforge.KotlinModLoadingContext```
instead of
```net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext```
|