@nxg-org/mineflayer-physics-util 1.9.1 → 1.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -0
- package/dist/index.js +3 -1
- package/dist/physics/states/playerState.js +3 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ declare module "mineflayer" {
|
|
|
8
8
|
}
|
|
9
9
|
export default function loader(bot: Bot): void;
|
|
10
10
|
export declare function initSetup(data: IndexedData): void;
|
|
11
|
+
export { PhysicsUtilWrapper } from "./wrapper";
|
|
11
12
|
export { EPhysicsCtx, PhysicsWorldSettings } from "./physics/settings";
|
|
12
13
|
export { BaseSimulator } from "./simulators";
|
|
13
14
|
export { EntityPhysics, BotcraftPhysics } from "./physics/engines";
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.applyToPlayerState = exports.convertPlayerState = exports.ControlStateHandler = exports.PlayerPoses = exports.PlayerState = exports.EntityState = exports.BotcraftPhysics = exports.EntityPhysics = exports.BaseSimulator = exports.PhysicsWorldSettings = exports.EPhysicsCtx = void 0;
|
|
3
|
+
exports.applyToPlayerState = exports.convertPlayerState = exports.ControlStateHandler = exports.PlayerPoses = exports.PlayerState = exports.EntityState = exports.BotcraftPhysics = exports.EntityPhysics = exports.BaseSimulator = exports.PhysicsWorldSettings = exports.EPhysicsCtx = exports.PhysicsUtilWrapper = void 0;
|
|
4
4
|
exports.default = loader;
|
|
5
5
|
exports.initSetup = initSetup;
|
|
6
6
|
const settings_1 = require("./physics/settings");
|
|
@@ -14,6 +14,8 @@ function loader(bot) {
|
|
|
14
14
|
function initSetup(data) {
|
|
15
15
|
settings_1.EPhysicsCtx.loadData(data);
|
|
16
16
|
}
|
|
17
|
+
var wrapper_2 = require("./wrapper");
|
|
18
|
+
Object.defineProperty(exports, "PhysicsUtilWrapper", { enumerable: true, get: function () { return wrapper_2.PhysicsUtilWrapper; } });
|
|
17
19
|
var settings_2 = require("./physics/settings");
|
|
18
20
|
Object.defineProperty(exports, "EPhysicsCtx", { enumerable: true, get: function () { return settings_2.EPhysicsCtx; } });
|
|
19
21
|
Object.defineProperty(exports, "PhysicsWorldSettings", { enumerable: true, get: function () { return settings_2.PhysicsWorldSettings; } });
|
|
@@ -332,6 +332,9 @@ class PlayerState {
|
|
|
332
332
|
bot.sprintTriggerTime = this.sprintTriggerTime;
|
|
333
333
|
bot.entity.yaw = this.yaw;
|
|
334
334
|
bot.entity.pitch = this.pitch;
|
|
335
|
+
bot.entity.height = this.height;
|
|
336
|
+
bot.entity.width = this.halfWidth * 2;
|
|
337
|
+
bot.entity.eyeHeight = this.eyeHeight;
|
|
335
338
|
Object.assign(bot.entity, this.pose);
|
|
336
339
|
bot.game.gameMode = this.gameMode; // this should never actually be in charge.
|
|
337
340
|
bot.food = this.food; // this should also never actually be in charge.
|