Interface SpawnReplacementLogic
- All Known Implementing Classes:
AbstractReplacementLogic
,BeeReplacementLogic
,NoReplacementLogic
,SimpleReplacementLogic
,VillagerReplacementLogic
public interface SpawnReplacementLogic
Replacement logic for when an entity spawns
-
Method Summary
Modifier and TypeMethodDescriptiongetId()
The ID to be used for identification in the datapacksvoid
read
(com.google.gson.Gson context, com.google.gson.JsonElement element) Reads the data required from the datapack JSONvoid
replaceSpawn
(net.minecraftforge.event.entity.EntityJoinLevelEvent event) Handles replacing the spawn
-
Method Details
-
getId
String getId()The ID to be used for identification in the datapacks- Returns:
- The unique ID
-
replaceSpawn
void replaceSpawn(net.minecraftforge.event.entity.EntityJoinLevelEvent event) Handles replacing the spawn- Parameters:
event
- The spawn event
-
read
void read(com.google.gson.Gson context, com.google.gson.JsonElement element) Reads the data required from the datapack JSON- Parameters:
context
- The gsonelement
- The json element of the file
-