Cast, Convert & more

This commit is contained in:
skippyall
2026-03-16 23:01:58 +01:00
parent 9b61dba4c7
commit 7acd083e79
59 changed files with 1207 additions and 178 deletions
@@ -1,5 +1,6 @@
package io.github.skippyall.minions.registration;
import io.github.skippyall.minions.minion.program.supplier.AnalogInputSupplier;
import io.github.skippyall.minions.program.supplier.FixedValueSupplierType;
import io.github.skippyall.minions.program.supplier.ValueSupplierType;
import io.github.skippyall.minions.Minions;
@@ -9,6 +10,7 @@ import net.minecraft.util.Identifier;
public class ValueSuppliers {
public static final FixedValueSupplierType<MinionRuntime> FIXED_VALUE_SUPPLIER_TYPE = register("fixed", new FixedValueSupplierType<>());
public static final AnalogInputSupplier.AnalogInputSupplierType ANALOG_INPUT = register("analog_input", new AnalogInputSupplier.AnalogInputSupplierType());
public static <T extends ValueSupplierType<MinionRuntime>> T register(String id, T type) {
return Registry.register(MinionRegistries.VALUE_SUPPLIER_TYPES, Identifier.of(Minions.MOD_ID, id), type);