getViewers

fun <T : Any> getViewers(clazz: KClass<T>): Map<Player, T>

Gets all online players currently viewing an inventory holder of the specified type.

Return

Map of players to their open inventory holders of type T

Since

2.2.0

Parameters

clazz

The KClass of the inventory holder type

Type Parameters

T

The inventory holder type


inline fun <T : Any> getViewers(): Map<Player, T>

Gets all online players currently viewing an inventory holder of the specified type.

Return

Map of players to their open inventory holders of type T

Since

2.2.0

Type Parameters

T

The inventory holder type