/*
 * SPDX-FileCopyrightText: 2026 KOKA99CAB
 * SPDX-License-Identifier: LGPL-3.0-or-later
 */

package net.koka99cab.portals;

import net.fabricmc.api.ModInitializer;
import net.koka99cab.portals.portal.PortalDefinitions;
import net.koka99cab.portals.portal.PortalIgnitionHandler;
import net.koka99cab.portals.registry.ModBlocks;
import net.koka99cab.portals.world.ModDimensions;
import net.koka99cab.portals.world.ModFeatures;
import net.koka99cab.portals.world.SkeletonWasteSpawner;
import net.minecraft.resources.Identifier;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

public final class PortalsMod implements ModInitializer {
	public static final String MOD_ID = "portals";
	public static final Logger LOGGER = LoggerFactory.getLogger(MOD_ID);

	public static Identifier id(String path) {
		return Identifier.fromNamespaceAndPath(MOD_ID, path);
	}

	@Override
	public void onInitialize() {
		ModDimensions.init();
		ModFeatures.init();
		ModBlocks.init();
		PortalDefinitions.init();
		PortalIgnitionHandler.register();
		SkeletonWasteSpawner.register();

		LOGGER.info("Portals initialized.");
	}
}
