package ru.dbotthepony.mc.otm.client.screen.panels.util

import net.minecraft.resources.ResourceLocation
import ru.dbotthepony.mc.otm.OverdriveThatMatters
import ru.dbotthepony.mc.otm.client.render.MatteryAtlas
import ru.dbotthepony.mc.otm.client.render.sprite

object ScrollBarConstants {
	const val WIDTH = 14f
	const val SLIM_WIDTH = 8f

	val NORMAL_ATLAS = 			MatteryAtlas(ResourceLocation(OverdriveThatMatters.MOD_ID, "textures/gui/widgets/scrollbar.png"), 62f, 15f)
	val SLIM_ATLAS = 			MatteryAtlas(ResourceLocation(OverdriveThatMatters.MOD_ID, "textures/gui/widgets/scrollbar_slim.png"), 32f, 15f)

	val BACKGROUND = 			NORMAL_ATLAS.sprite(width = 14f, height = 8f)
	val BACKGROUND_SLIM = 		SLIM_ATLAS.sprite(width = 8f, height = 8f)

	val TOP = 					BACKGROUND.sprite(height = 2f)
	val BODY = 					BACKGROUND.sprite(y = 2f, height = 5f)
	val BOTTOM = 				BACKGROUND.sprite(y = 6f, height = 2f)

	val BUTTON = 				NORMAL_ATLAS.sprite(x = 14f, width = 12f)
	val BUTTON_HOVER = 			NORMAL_ATLAS.sprite(x = 14f + 12f, width = 12f)
	val BUTTON_PRESS = 			NORMAL_ATLAS.sprite(x = 14f + 12f * 2f, width = 12f)
	val BUTTON_DISABLED = 		NORMAL_ATLAS.sprite(x = 14f + 12f * 3f, width = 12f)

	val SLIM_TOP = 				BACKGROUND_SLIM.sprite(height = 2f)
	val SLIM_BODY = 			BACKGROUND_SLIM.sprite(y = 2f, height = 5f)
	val SLIM_BOTTOM = 			BACKGROUND_SLIM.sprite(y = 6f, height = 2f)

	val SLIM_BUTTON = 			SLIM_ATLAS.sprite(x = 8f, width = 6f)
	val SLIM_BUTTON_HOVER = 	SLIM_ATLAS.sprite(x = 8f + 6f, width = 6f)
	val SLIM_BUTTON_PRESS = 	SLIM_ATLAS.sprite(x = 8f + 6f * 2f, width = 6f)
	val SLIM_BUTTON_DISABLED = 	SLIM_ATLAS.sprite(x = 8f + 6f * 3f, width = 6f)
}
