Created
November 13, 2024 10:53
-
-
Save LoneDev6/eb21fec10aa0fb0aa7db3a6fc62caa8e to your computer and use it in GitHub Desktop.
Debugging Minecraft packets
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<Configuration status="WARN"> | |
<Appenders> | |
<Console name="SysOut" target="SYSTEM_OUT"> | |
<PatternLayout pattern="[%d{HH:mm:ss}] [%t/%level]: %msg%n" /> | |
<Filters> | |
<RegexFilter regex=".*(keep_alive|client_tick_end|set_time|move_player_rot|move_player_pos|move_entity_pos_rot|move_entity_pos|set_entity_motion|rotate_head).*" onMatch="DENY" onMismatch="ACCEPT" /> | |
</Filters> | |
</Console> | |
<RollingRandomAccessFile name="File" fileName="logs/latest.log" filePattern="logs/%d{yyyy-MM-dd}-%i.log.gz"> | |
<PatternLayout pattern="[%d{HH:mm:ss}] [%t/%level]: %msg%n" /> | |
<Policies> | |
<TimeBasedTriggeringPolicy /> | |
<OnStartupTriggeringPolicy /> | |
</Policies> | |
<DefaultRolloverStrategy max="1000"/> | |
</RollingRandomAccessFile> | |
</Appenders> | |
<Loggers> | |
<!-- Logger specifico per NETWORK_PACKETS --> | |
<Logger name="com.mojang.network" level="debug" additivity="false"> | |
<filters> | |
<MarkerFilter marker="NETWORK_PACKETS" onMatch="ACCEPT" onMismatch="DENY" /> | |
</filters> | |
<AppenderRef ref="SysOut"/> | |
<AppenderRef ref="File"/> | |
</Logger> | |
<!-- Root logger per tutti gli altri log --> | |
<Root level="debug"> | |
<AppenderRef ref="SysOut"/> | |
<AppenderRef ref="File"/> | |
</Root> | |
</Loggers> | |
</Configuration> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
RegexFilter
is used to ignore some packets, to avoid log spam. You can enable some if you need them.Put this file in any folder of your PC and set this java argument in your client:
-Dlog4j.configurationFile="file:///C:/your_path_here/log4j2.xml"