Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions src/main/java/gregtech/api/unification/material/Material.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
import com.google.common.base.Preconditions;
import com.google.common.collect.ImmutableList;
import crafttweaker.annotations.ZenRegister;
import org.jetbrains.annotations.Contract;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.annotations.Range;
Expand Down Expand Up @@ -520,6 +521,18 @@ public MaterialRegistry getRegistry() {
return GregTechAPI.materialManager.getRegistry(getModid());
}

/**
* Create a new {@link Material.Builder}.
*
* @param id The MetaItemSubID for this Material. Must be unique to your mods material registry.
* @param resourceLocation The ModId and Name of this Material. Will be formatted as "<modid>.material.<name>" for
* the Translation Key.
*/
@Contract("_, _ -> new")
public static @NotNull Builder builder(int id, @NotNull ResourceLocation resourceLocation) {
return new Builder(id, resourceLocation);
}

/**
* @since GTCEu 2.0.0
*/
Expand Down
Loading
Loading