ServerLevelAccessor .java

net.minecraft.world.level.ServerLevelAccessor (interface): members: addFreshEntityWithPassengers, getCurrentDifficultyAt, getLevel. imports: Entity.

net.minecraft.world.levelinterface17 linescommonextends LevelAccessor489 B

API Surface (0)

No public/protected methods detected (fields or constants only).

Code Graph: Dependencies (5)

Edges (calls / imports / inherits / references) resolved by graphify from the AST. Every chip opens the class source.

Full Source

ServerLevelAccessor.java17 lines · Minecraft 26.3 · verbatim
1
package net.minecraft.world.level;
2
3
import net.minecraft.core.BlockPos;
4
import net.minecraft.server.level.ServerLevel;
5
import net.minecraft.world.DifficultyInstance;
6
import net.minecraft.world.entity.Entity;
7
8
public interface ServerLevelAccessor extends LevelAccessor {
9
	ServerLevel getLevel();
10
11
	DifficultyInstance getCurrentDifficultyAt(BlockPos pos);
12
13
	default void addFreshEntityWithPassengers(final Entity entity) {
14
		entity.getSelfAndPassengers().forEach(this::addFreshEntity);
15
	}
16
}
17

Decompiled Minecraft 26.3 source of ServerLevelAccessor (net/minecraft/world/level/ServerLevelAccessor.java) with Mojang official mappings, stored verbatim on the site.