Skip to content

Commit 2c83b7b

Browse files
committed
v0.0.3
1 parent 3f4655d commit 2c83b7b

5 files changed

Lines changed: 15 additions & 14 deletions

File tree

.changeset/stale-coins-punch.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@lpsmods/mc-dev": patch
3+
---
4+
5+
Fixed missing import errors.

libraries/mc-dev/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@lpsmods/mc-dev",
3-
"version": "0.0.2",
3+
"version": "0.0.3",
44
"author": "legopitstop",
55
"license": "MIT",
66
"description": "Debug utilities for Minecraft Bedrock Edition Add-On development.",

libraries/mc-dev/src/developer_tools/base.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,13 @@
11
import { Player } from "@minecraft/server";
22
import {
3-
ActionButton,
4-
ActionForm,
5-
ActionFormHandler,
63
ChunkEvents,
74
ChunkTickEvent,
85
EntityTickEvent,
9-
ParticleDrawer,
106
PlayerChunkLoadEvent,
117
PlayerChunkUnloadEvent,
128
PlayerHandler,
139
} from "@lpsmods/mc-utils";
10+
import { ActionButton, ActionForm, ActionFormHandler } from "@lpsmods/mc-common";
1411

1512
import { DevTool } from "./tools";
1613

@@ -21,13 +18,13 @@ export type DeveloperToolsConfig = { [key: string]: boolean };
2118
export class DeveloperTools extends PlayerHandler {
2219
static instance: DeveloperTools | undefined = undefined;
2320
delay: number = 0;
24-
particleDrawer: ParticleDrawer;
21+
// particleDrawer: ParticleDrawer;
2522
textDisplayId?: string;
2623

2724
constructor(textDisplayId?: string) {
2825
super();
2926
this.onTick = this.onTick.bind(this);
30-
this.particleDrawer = new ParticleDrawer("overworld");
27+
// this.particleDrawer = new ParticleDrawer("overworld");
3128
this.textDisplayId = textDisplayId;
3229
if (!initialized) init();
3330
DeveloperTools.instance = this;

libraries/mc-dev/src/developer_tools/tools.ts

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
1+
import { Block, EquipmentSlot, ItemStack, Player, RawMessage } from "@minecraft/server";
12
import {
23
ChunkTickEvent,
34
DirectionUtils,
45
EntityTickEvent,
5-
Identifier,
66
PlayerChunkLoadEvent,
77
PlayerChunkUnloadEvent,
8-
Settings,
98
} from "@lpsmods/mc-utils";
10-
import { Block, EquipmentSlot, ItemStack, Player, RawMessage } from "@minecraft/server";
9+
import { Identifier, Settings, TextUtils } from "@lpsmods/mc-common";
1110

1211
export interface DevToolOptions {
1312
name?: string;
@@ -176,7 +175,7 @@ class BlockInfoTool extends DevTool {
176175

177176
if (this.store.get("dimension")) {
178177
const dimId = Identifier.parse(block.dimension.id).path;
179-
texts.push({ text: `Dimension: §7${dimId.toTitleCase()}§r` });
178+
texts.push({ text: `Dimension: §7${TextUtils.smartTitleCase(dimId)}§r` });
180179
}
181180

182181
if (this.store.get("position")) {
@@ -283,11 +282,11 @@ class PlayerInfoTool extends DevTool {
283282

284283
if (this.store.get("dimension")) {
285284
const dimId = Identifier.parse(dim.id).path;
286-
texts.push({ text: `Dimension: §7${dimId.toTitleCase()}§r` });
285+
texts.push({ text: `Dimension: §7${TextUtils.smartTitleCase(dimId)}§r` });
287286
}
288287
if (this.store.get("biome")) {
289288
const b = dim.getBiome({ x, y, z }).id.replace("minecraft:", "");
290-
texts.push({ text: `Biome: §7${b.toTitleCase()}§r` });
289+
texts.push({ text: `Biome: §7${TextUtils.smartTitleCase(b)}§r` });
291290
}
292291
if (this.store.get("position")) {
293292
const text = `Position: ${this.store.get("position_coloring") ? `§c${x.toFixed(2)}§7, §a${y.toFixed(2)}§7, §9${z.toFixed(2)}§r` : `§7${x.toFixed(2)}, ${y.toFixed(2)}, ${z.toFixed(2)}§r`}`;

libraries/mc-dev/src/main.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ describe("placeholder", () => {
44
it("should pass", () => {
55
expect(true).toBe(true);
66
});
7-
});
7+
});

0 commit comments

Comments
 (0)