package pw.hamzantal.bloodmoon.specialattacks

import org.bukkit.entity.Entity
import org.bukkit.entity.Monster
import org.bukkit.entity.Player
import org.bukkit.entity.Zombie
import pw.hamzantal.bloodmoon.BloodMoon

interface  SpecialAttack <T: Entity> {
    fun spawnAttack(attacker: T, p: Player, pl: BloodMoon)

    infix fun typeNameHas(s: String) = javaClass.genericInterfaces.any { it.typeName.contains(s) }
}

val zombieAttacks: List<SpecialAttack<Zombie>> = listOf(
    ArrowBarrage(),
    FlipBack(),
    SlamDunk()
)