Skip to content

Commit 8b756bb

Browse files
committed
fix: some null ex
1 parent e7aa6b9 commit 8b756bb

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

src/main/java/zadudoder/spmhelper/tutorial/TutorialManager.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,9 @@ public static void skipTutorial() {
3737
}
3838

3939
private static void pullText(String text) {
40-
MinecraftClient.getInstance().player.sendMessage(Text.literal(text));
40+
if (MinecraftClient.getInstance().player != null) {
41+
MinecraftClient.getInstance().player.sendMessage(Text.literal(text));
42+
}
4143
}
4244

4345
public static void startPNTutorial() {
@@ -216,6 +218,9 @@ private static void GoToEndAction() {
216218
}
217219

218220
public static void StartEnd() {
221+
if (!isEnabled || checkpoints == null) {
222+
preTutorial();
223+
}
219224
checkpoints.add(new TutorialPoint(96, 49, 0, END, null, false));
220225
checkpoints.add(new TutorialPoint(90, 49, 0, END, null, false));
221226
checkpoints.add(new TutorialPoint(87, 54, 0, END, null, false));

0 commit comments

Comments
 (0)