DebugSubscriptions.java
net.minecraft.util.debug.DebugSubscriptions
信息
- 全限定名:net.minecraft.util.debug.DebugSubscriptions
- 类型:public class
- 包:net.minecraft.util.debug
- 源码路径:src/main/java/net/minecraft/util/debug/DebugSubscriptions.java
- 起始行号:L14
- 职责:
TODO
字段/常量
-
DEDICATED_SERVER_TICK_TIME- 类型:
DebugSubscription<?> - 修饰符:
public static final - 源码定位:
L15 - 说明:
TODO
- 类型:
-
BEES- 类型:
DebugSubscription<DebugBeeInfo> - 修饰符:
public static final - 源码定位:
L16 - 说明:
TODO
- 类型:
-
BRAINS- 类型:
DebugSubscription<DebugBrainDump> - 修饰符:
public static final - 源码定位:
L17 - 说明:
TODO
- 类型:
-
BREEZES- 类型:
DebugSubscription<DebugBreezeInfo> - 修饰符:
public static final - 源码定位:
L18 - 说明:
TODO
- 类型:
-
GOAL_SELECTORS- 类型:
DebugSubscription<DebugGoalInfo> - 修饰符:
public static final - 源码定位:
L19 - 说明:
TODO
- 类型:
-
ENTITY_PATHS- 类型:
DebugSubscription<DebugPathInfo> - 修饰符:
public static final - 源码定位:
L20 - 说明:
TODO
- 类型:
-
ENTITY_BLOCK_INTERSECTIONS- 类型:
DebugSubscription<DebugEntityBlockIntersection> - 修饰符:
public static final - 源码定位:
L21 - 说明:
TODO
- 类型:
-
BEE_HIVES- 类型:
DebugSubscription<DebugHiveInfo> - 修饰符:
public static final - 源码定位:
L24 - 说明:
TODO
- 类型:
-
POIS- 类型:
DebugSubscription<DebugPoiInfo> - 修饰符:
public static final - 源码定位:
L25 - 说明:
TODO
- 类型:
-
REDSTONE_WIRE_ORIENTATIONS- 类型:
DebugSubscription<Orientation> - 修饰符:
public static final - 源码定位:
L26 - 说明:
TODO
- 类型:
-
VILLAGE_SECTIONS- 类型:
DebugSubscription<Unit> - 修饰符:
public static final - 源码定位:
L29 - 说明:
TODO
- 类型:
-
RAIDS- 类型:
DebugSubscription<List<BlockPos>> - 修饰符:
public static final - 源码定位:
L30 - 说明:
TODO
- 类型:
-
STRUCTURES- 类型:
DebugSubscription<List<DebugStructureInfo>> - 修饰符:
public static final - 源码定位:
L31 - 说明:
TODO
- 类型:
-
GAME_EVENT_LISTENERS- 类型:
DebugSubscription<DebugGameEventListenerInfo> - 修饰符:
public static final - 源码定位:
L34 - 说明:
TODO
- 类型:
-
NEIGHBOR_UPDATES- 类型:
DebugSubscription<BlockPos> - 修饰符:
public static final - 源码定位:
L37 - 说明:
TODO
- 类型:
-
GAME_EVENTS- 类型:
DebugSubscription<DebugGameEventInfo> - 修饰符:
public static final - 源码定位:
L38 - 说明:
TODO
- 类型:
内部类/嵌套类型
- 无
构造器
- 无
方法
下面的方法块按源码顺序生成。
public static DebugSubscription<?> bootstrap(Registry<DebugSubscription<?>> registry) @ L40
- 方法名:bootstrap
- 源码定位:L40
- 返回类型:DebugSubscription<?>
- 修饰符:public static
参数:
- registry: Registry<DebugSubscription<?>>
说明:
TODO
private static DebugSubscription<?> registerSimple(String id) @ L44
- 方法名:registerSimple
- 源码定位:L44
- 返回类型:DebugSubscription<?>
- 修饰符:private static
参数:
- id: String
说明:
TODO
private static <T> DebugSubscription<T> registerWithValue(String id, StreamCodec<?super RegistryFriendlyByteBuf,T> valueStreamCodec) @ L48
- 方法名:registerWithValue
- 源码定位:L48
- 返回类型:
DebugSubscription - 修饰符:private static
参数:
- id: String
- valueStreamCodec: StreamCodec<?super RegistryFriendlyByteBuf,T>
说明:
TODO
private static <T> DebugSubscription<T> registerTemporaryValue(String id, StreamCodec<?super RegistryFriendlyByteBuf,T> valueStreamCodec, int expireAfterTicks) @ L52
- 方法名:registerTemporaryValue
- 源码定位:L52
- 返回类型:
DebugSubscription - 修饰符:private static
参数:
- id: String
- valueStreamCodec: StreamCodec<?super RegistryFriendlyByteBuf,T>
- expireAfterTicks: int
说明:
TODO
代码
public class DebugSubscriptions<T> {
public static final DebugSubscription<?> DEDICATED_SERVER_TICK_TIME = registerSimple("dedicated_server_tick_time");
public static final DebugSubscription<DebugBeeInfo> BEES = registerWithValue("bees", DebugBeeInfo.STREAM_CODEC);
public static final DebugSubscription<DebugBrainDump> BRAINS = registerWithValue("brains", DebugBrainDump.STREAM_CODEC);
public static final DebugSubscription<DebugBreezeInfo> BREEZES = registerWithValue("breezes", DebugBreezeInfo.STREAM_CODEC);
public static final DebugSubscription<DebugGoalInfo> GOAL_SELECTORS = registerWithValue("goal_selectors", DebugGoalInfo.STREAM_CODEC);
public static final DebugSubscription<DebugPathInfo> ENTITY_PATHS = registerWithValue("entity_paths", DebugPathInfo.STREAM_CODEC);
public static final DebugSubscription<DebugEntityBlockIntersection> ENTITY_BLOCK_INTERSECTIONS = registerTemporaryValue(
"entity_block_intersections", DebugEntityBlockIntersection.STREAM_CODEC, 100
);
public static final DebugSubscription<DebugHiveInfo> BEE_HIVES = registerWithValue("bee_hives", DebugHiveInfo.STREAM_CODEC);
public static final DebugSubscription<DebugPoiInfo> POIS = registerWithValue("pois", DebugPoiInfo.STREAM_CODEC);
public static final DebugSubscription<Orientation> REDSTONE_WIRE_ORIENTATIONS = registerTemporaryValue(
"redstone_wire_orientations", Orientation.STREAM_CODEC, 200
);
public static final DebugSubscription<Unit> VILLAGE_SECTIONS = registerWithValue("village_sections", Unit.STREAM_CODEC);
public static final DebugSubscription<List<BlockPos>> RAIDS = registerWithValue("raids", BlockPos.STREAM_CODEC.apply(ByteBufCodecs.list()));
public static final DebugSubscription<List<DebugStructureInfo>> STRUCTURES = registerWithValue(
"structures", DebugStructureInfo.STREAM_CODEC.apply(ByteBufCodecs.list())
);
public static final DebugSubscription<DebugGameEventListenerInfo> GAME_EVENT_LISTENERS = registerWithValue(
"game_event_listeners", DebugGameEventListenerInfo.STREAM_CODEC
);
public static final DebugSubscription<BlockPos> NEIGHBOR_UPDATES = registerTemporaryValue("neighbor_updates", BlockPos.STREAM_CODEC, 200);
public static final DebugSubscription<DebugGameEventInfo> GAME_EVENTS = registerTemporaryValue("game_events", DebugGameEventInfo.STREAM_CODEC, 60);
public static DebugSubscription<?> bootstrap(Registry<DebugSubscription<?>> registry) {
return DEDICATED_SERVER_TICK_TIME;
}
private static DebugSubscription<?> registerSimple(String id) {
return Registry.register(BuiltInRegistries.DEBUG_SUBSCRIPTION, Identifier.withDefaultNamespace(id), new DebugSubscription(null));
}
private static <T> DebugSubscription<T> registerWithValue(String id, StreamCodec<? super RegistryFriendlyByteBuf, T> valueStreamCodec) {
return Registry.register(BuiltInRegistries.DEBUG_SUBSCRIPTION, Identifier.withDefaultNamespace(id), new DebugSubscription<>(valueStreamCodec));
}
private static <T> DebugSubscription<T> registerTemporaryValue(
String id, StreamCodec<? super RegistryFriendlyByteBuf, T> valueStreamCodec, int expireAfterTicks
) {
return Registry.register(
BuiltInRegistries.DEBUG_SUBSCRIPTION, Identifier.withDefaultNamespace(id), new DebugSubscription<>(valueStreamCodec, expireAfterTicks)
);
}
}引用的其他类
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
参数/方法调用 - 关联成员:
Registry.register()
- 引用位置:
-
- 引用位置:
参数
- 引用位置:
-
- 引用位置:
方法调用 - 关联成员:
ByteBufCodecs.list()
- 引用位置:
-
- 引用位置:
参数
- 引用位置:
-
- 引用位置:
方法调用 - 关联成员:
Identifier.withDefaultNamespace()
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
字段
- 引用位置:
-
- 引用位置:
参数/字段/构造调用/返回值 - 关联成员:
DebugSubscription()
- 引用位置:
-
- 引用位置:
字段
- 引用位置: