diff --git a/src/main/java/net/neoforged/moddevgradle/dsl/NeoForgeExtension.java b/src/main/java/net/neoforged/moddevgradle/dsl/NeoForgeExtension.java index 0228791e..1632ab11 100644 --- a/src/main/java/net/neoforged/moddevgradle/dsl/NeoForgeExtension.java +++ b/src/main/java/net/neoforged/moddevgradle/dsl/NeoForgeExtension.java @@ -1,7 +1,7 @@ package net.neoforged.moddevgradle.dsl; +import org.gradle.api.Action; import org.gradle.api.NamedDomainObjectContainer; -import org.gradle.api.NamedDomainObjectSet; import org.gradle.api.Project; import org.gradle.api.provider.ListProperty; import org.gradle.api.provider.Property; @@ -51,11 +51,19 @@ public NeoForgeExtension(Project project) { public abstract ListProperty getAccessTransformers(); - public NamedDomainObjectSet getMods() { + public NamedDomainObjectContainer getMods() { return mods; } - public NamedDomainObjectSet getRuns() { + public void mods(Action> action) { + action.execute(mods); + } + + public NamedDomainObjectContainer getRuns() { return runs; } + + public void runs(Action> action) { + action.execute(runs); + } }