package ru.dbotthepony.mc.otm.item

import ru.dbotthepony.mc.otm.OverdriveThatMatters
import net.minecraft.world.item.ItemStack
import net.minecraft.world.item.TooltipFlag
import net.minecraft.ChatFormatting
import net.minecraft.network.chat.Component
import net.minecraft.world.item.Item
import net.minecraft.world.item.Rarity
import net.minecraft.world.level.Level
import ru.dbotthepony.mc.otm.core.TranslatableComponent

class GravitationalDisruptorItem :
	Item(Properties().stacksTo(1).rarity(Rarity.EPIC)) {
	override fun appendHoverText(
		p_41421_: ItemStack,
		p_41422_: Level?,
		list: MutableList<Component>,
		p_41424_: TooltipFlag
	) {
		super.appendHoverText(p_41421_, p_41422_, list, p_41424_)
		list.add(DESCRIPTION)
		list.add(DESCRIPTION2)
		list.add(DESCRIPTION3)
		list.add(DESCRIPTION4)
	}

	companion object {
		private val DESCRIPTION: Component =
			TranslatableComponent("item.overdrive_that_matters.gravitational_disruptor.description").withStyle(
				ChatFormatting.GRAY
			)
		private val DESCRIPTION2: Component =
			TranslatableComponent("item.overdrive_that_matters.gravitational_disruptor.description2").withStyle(
				ChatFormatting.GRAY
			)
		private val DESCRIPTION3: Component =
			TranslatableComponent("item.overdrive_that_matters.gravitational_disruptor.description3").withStyle(
				ChatFormatting.DARK_RED
			)
		private val DESCRIPTION4: Component = TranslatableComponent(
			"item.overdrive_that_matters.gravitational_disruptor.description4",
			TranslatableComponent("item.overdrive_that_matters.gravitational_disruptor.description4_clarification").withStyle(
				ChatFormatting.DARK_RED,
				ChatFormatting.BOLD,
				ChatFormatting.UNDERLINE
			),
			TranslatableComponent("item.overdrive_that_matters.gravitational_disruptor.description4_clarification2").withStyle(
				ChatFormatting.DARK_RED,
				ChatFormatting.ITALIC
			)
		).withStyle(ChatFormatting.DARK_RED)
	}
}
