blob: fed7ec27597b42ba1237f339f124ae9066dd9b02 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
package com.anthonyhilyard.iceberg.events;
import net.minecraftforge.event.entity.player.PlayerEvent;
import net.minecraft.advancements.Advancement;
import net.minecraft.world.entity.player.Player;
import net.minecraftforge.common.MinecraftForge;
/**
* This event is fired when a player is granted an advancement criterion.
* <br>
* This event is not {@link net.minecraftforge.eventbus.api.Cancelable}.<br>
* <br>
* This event does not have a result. {@link HasResult}<br>
* <br>
* This event is fired on the {@link MinecraftForge#EVENT_BUS}.
*/
public class CriterionEvent extends PlayerEvent
{
private final Advancement advancement;
private final String criterionKey;
public CriterionEvent(Player player, Advancement advancement, String criterionKey)
{
super(player);
this.advancement = advancement;
this.criterionKey = criterionKey;
}
public Advancement getAdvancement()
{
return advancement;
}
public String getCriterionKey()
{
return criterionKey;
}
}
|