From 0dd366856faeb50c7a1d0ad0a62efb6a9207b9da Mon Sep 17 00:00:00 2001 From: ZXMushroom63 Date: Sun, 15 Oct 2023 12:35:42 +0800 Subject: [PATCH 1/2] Extra information for doc. Remove
tags and sub Add foodstats Plugin API a5.3 Doc Fix installing plugins doc --- src/.vuepress/config.js | 131 +++++++++++---------- src/guide/InstallingPlugins.md | 35 +++--- src/guide/MakingPlugins.md | 92 +++++++++++++++ src/guide/making-patch-files.md | 28 ++--- src/plugindocs/README.md | 8 +- src/plugindocs/events/addEventListener.md | 13 +- src/plugindocs/globals/BlockData.md | 1 + src/plugindocs/globals/FoodStatsData.md | 19 +++ src/plugindocs/globals/GameSettingsData.md | 73 ++++++++++++ src/plugindocs/globals/KeyBindingData.md | 18 +++ src/plugindocs/globals/PlayerData.md | 97 ++++++++++++++- src/plugindocs/globals/Vec3i.md | 6 +- 12 files changed, 418 insertions(+), 103 deletions(-) create mode 100644 src/guide/MakingPlugins.md create mode 100644 src/plugindocs/globals/FoodStatsData.md create mode 100644 src/plugindocs/globals/GameSettingsData.md create mode 100644 src/plugindocs/globals/KeyBindingData.md diff --git a/src/.vuepress/config.js b/src/.vuepress/config.js index f2d76ed..5541509 100755 --- a/src/.vuepress/config.js +++ b/src/.vuepress/config.js @@ -21,15 +21,15 @@ module.exports = { ['meta', { name: 'apple-mobile-web-app-status-bar-style', content: 'black' }], ['link', { rel: 'icon', href: '/favicon.ico' }], ['meta', { - name: 'theme-color', - content: '#22282e', - media: '(prefers-color-scheme: light)' - }], + name: 'theme-color', + content: '#22282e', + media: '(prefers-color-scheme: light)' + }], ['meta', { - name: 'theme-color', - content: '#22282e', - media: '(prefers-color-scheme: dark)' - }] + name: 'theme-color', + content: '#22282e', + media: '(prefers-color-scheme: dark)' + }] ], /** @@ -58,69 +58,72 @@ module.exports = { sidebar: { '/guide/': [ { - + title: 'Guide', collapsable: false, - children: [ + children: [ '', 'non-eagler', - 'making-patch-files', - 'InstallingPlugins', - + 'making-patch-files', + 'InstallingPlugins', + 'MakingPlugins', ], } ], -'/plugindocs/': [ - { - title: 'Plugin API', - collapsable: false, - children: [ - '', - ], - }, - { - title: 'Events', - collapsable: true, - children: [ - 'events/addEventListener', - 'events/removeEventListener', - 'events/FromServerEvents', - 'events/ToServerEvents', - ], - }, - { - title: 'Globals', - collapsable: true, - children: [ - 'globals/Data', - 'globals/AxisAlignedBB', - 'globals/BlockData', - 'globals/BlockPos', - 'globals/ChunkData', - 'globals/ContainerData', - 'globals/EnchantmentData', - 'globals/EntityData', - 'globals/FishHookData', - 'globals/InventoryBasicData', - 'globals/InventoryPlayerData', - 'globals/ItemData', - 'globals/ItemStackData', - 'globals/LivingEntityData', - 'globals/LocalPlayerData', - 'globals/MapColor', - 'globals/MaterialData', - 'globals/NetworkData', - 'globals/PlayerCapabilities', - 'globals/PlayerData', - 'globals/RemotePlayerData', - 'globals/require', - 'globals/updateComponent', - 'globals/Vec3', - 'globals/Vec3i', - 'globals/Vec4b', - ], - } + '/plugindocs/': [ + { + title: 'Plugin API', + collapsable: false, + children: [ + '', + ], + }, + { + title: 'Events', + collapsable: true, + children: [ + 'events/addEventListener', + 'events/removeEventListener', + 'events/FromServerEvents', + 'events/ToServerEvents', + ], + }, + { + title: 'Globals', + collapsable: true, + children: [ + 'globals/Data', + 'globals/AxisAlignedBB', + 'globals/BlockData', + 'globals/BlockPos', + 'globals/ChunkData', + 'globals/ContainerData', + 'globals/EnchantmentData', + 'globals/EntityData', + 'globals/FishHookData', + 'globals/FoodStatsData', + 'globals/GameSettingsData', + 'globals/InventoryBasicData', + 'globals/InventoryPlayerData', + 'globals/ItemData', + 'globals/ItemStackData', + 'globals/KeyBindingData', + 'globals/LivingEntityData', + 'globals/LocalPlayerData', + 'globals/MapColor', + 'globals/MaterialData', + 'globals/NetworkData', + 'globals/PlayerCapabilities', + 'globals/PlayerData', + 'globals/RemotePlayerData', + 'globals/require', + 'globals/updateComponent', + 'globals/Vec3', + 'globals/Vec3i', + 'globals/Vec4b', + ], + } ], } }, @@ -128,7 +131,7 @@ module.exports = { /** * Apply plugins,ref:https://v1.vuepress.vuejs.org/zh/plugin/ */ - plugins: [ + plugins: [ '@vuepress/plugin-back-to-top', '@vuepress/plugin-medium-zoom', ] diff --git a/src/guide/InstallingPlugins.md b/src/guide/InstallingPlugins.md index 7efba20..4c0286c 100644 --- a/src/guide/InstallingPlugins.md +++ b/src/guide/InstallingPlugins.md @@ -1,22 +1,23 @@ # How to install a plugin -Please keep in mind that these plugins are fully client side and therefore work on most servers. They can be considered hacks or unfair advantages, so be careful when using them. - -
    -
  1. Open the compiled client
  2. -
  3. Open options
  4. -
  5. Click 'Plugins'
  6. -
  7. Click 'Add New'
  8. -
  9. Paste in the .js url.
  10. -
  11. Optional: Refresh the GUI to see if the plugin loaded correctly.
  12. -
  13. Optional: If the plugin is not working, go to options > plugins and make sure it says 'LOADED' next to your plugin. If it doesn't, it's not my fault!!!
  14. -
- -Here is a sample plugin that allows you to climb up walls like a spider: -https://raw.githubusercontent.com/EaglerReborn/reborn/main/exampleplugins/spider.js - -And one that allows you to step up 9.5 blocks:
+_Please keep in mind that these plugins are fully client side and therefore work on most servers. They can be considered hacks or unfair advantages, so be careful when using them._ + +1. Open the compiled client +2. Open options +3. Click 'Plugins' +4. Click 'Add New' +5. Paste in the .js url. +6. Optional: Refresh the GUI to see if the plugin loaded correctly. + + +----- + + +Here is a sample plugin that prevents you from taking fall damage:\ +https://raw.githubusercontent.com/EaglerReborn/reborn/main/exampleplugins/nofall.js + +And one that allows you to step up 9.5 blocks:\ https://raw.githubusercontent.com/EaglerReborn/reborn/main/exampleplugins/step.js -And finally, a grappling hook mod!:
+And finally, a grappling hook mod!:\ https://raw.githubusercontent.com/EaglerReborn/reborn/main/exampleplugins/grapplehook.js diff --git a/src/guide/MakingPlugins.md b/src/guide/MakingPlugins.md new file mode 100644 index 0000000..69dcb58 --- /dev/null +++ b/src/guide/MakingPlugins.md @@ -0,0 +1,92 @@ +# How to create a plugin + +You will need: +- Knowledge of JavaScript +- A code editor (I use [vscode.dev](https://vscode.dev)) +- Knowledge of Minecraft + +## What is a plugin? +A plugin is a script that is loaded by EaglerReborn on startup or when added. It can do anythin regular JavaScript do, as well as access the [Plugin API](../plugindocs/README.md). + +
+ +How to make an example "Spider" hack plugin + + +## How to make an example "Spider" hack plugin + +Spider is a hack that allows you to climb up walls like a spider. + +Create a new file with the `.js` extension, and open it in your code editor. + +We will start by [requiring](../plugindocs/README.md#using-non-auto-properties) the player. +Requiring allows us to access non-automatic properties of the Plugin API. + +Add this line of code: +```javascript +PluginAPI.require("player"); +``` +This will allow us to access the player. + + +Now, we need to add a listener that will run code every game tick.\ +Make a function. (Name it whatever you want) +```javascript +function spiderListener() { + +} +``` + +Inside this function we will do two things: +- Check if the player is walking in to a wall +- If they are, add vertical motion + +Let's start with checking if the player is walking in to a wall.\ +In the function you just made, add an `if` block. +```javascript +if () { + +} +``` + +We can check whether or not the player is walking in to a wall with `PluginAPI.player.isCollidedHorizontally`. +```javascript +if (PluginAPI.player.isCollidedHorizontally) { + +} +``` + +Now to add the vertical motion, we change the `motionY` property of `PluginAPI.player`.\ +I will use the `+=` operator, which adds an amount to a variable. + +In the if, add these lines: +```javascript +PluginAPI.player.motionY += 0.2; +PluginAPI.player.reload(); +``` + +You can change the `0.2` to something larger or smaller if you want. The `reload()` call is used to tell the Plugin API to update the in-game values, so we can see our changes. + +Finally, we need to add the listener. +```javascript +PluginAPI.addEventListener("update", spiderListener); +``` +This tells the Plugin API to run `spiderListener` every game update (or tick). + +Your finished code should somewhat look like this: +```javascript +function spiderListener() { + if (PluginAPI.player.isCollidedHorizontally) { + PluginAPI.player.motionY += 0.2; + PluginAPI.player.reload(); + } +} +PluginAPI.addEventListener("update", spiderListener); +``` + +Now, open the EaglerReborn client. +Go to Options > Plugins and press "upload". +Select the plugin file. + +Now, when joining a server (without an anti-cheat), you should be able to climb up walls like a spider. +
\ No newline at end of file diff --git a/src/guide/making-patch-files.md b/src/guide/making-patch-files.md index d23cee0..c4862c9 100644 --- a/src/guide/making-patch-files.md +++ b/src/guide/making-patch-files.md @@ -8,22 +8,22 @@ In order to make your own patch files, you will need the following: 4. FFMPEG --- -Note: This tutorial only works on Linux or MacOS. To do this on Windows, either setup up a virtual machine or use WSL (preferably WSL 2). +Note: This tutorial only works on Linux or MacOS. To do this on Windows, either setup up a virtual machine or use WSL (preferably WSL 2). --- -First, move the 1.8.8 jar, the 1.8.json file, and mcp918.zip into the mcp918 folder.
-Then. open a terminal in the root directory of the repo.
-Run `java -jar buildtools/BuildTools.jar init` in the terminal.
-After it's done, do `java -jar buildtools/BuildTools.jar workspace`. It should ask you what directory you want it in.
-After putting this info in, it should create the directory you specified and place a Gradle project inside.
-This is the decompiled source of Minecraft 1.8.8, plus the patches.
-Just modify the files and do `./gradlew teavm` inside the workspace to compile.
-Then do `bash CompileEPK.sh` to get an assets.epk file.
-If you want to quickly test, do `python -m http.server` in the workspace and go to localhost:8000 in your browser.
-If you want to make a pull request, do `java -jar buildtools/BuildTools.jar pullrequest` to generate a pullrequest folder.
-Then, take this modified version of the repo and upload it to Github, make a pullrequest, and I will take a look.
+First, move the 1.8.8 jar, the 1.8.json file, and mcp918.zip into the mcp918 folder. +Then. open a terminal in the root directory of the repo. +Run `java -jar buildtools/BuildTools.jar init` in the terminal. +After it's done, do `java -jar buildtools/BuildTools.jar workspace`. It should ask you what directory you want it in. +After putting this info in, it should create the directory you specified and place a Gradle project inside. +This is the decompiled source of Minecraft 1.8.8, plus the patches. +Just modify the files and do `./gradlew teavm` inside the workspace to compile. +Then do `bash CompileEPK.sh` to get an assets.epk file. +If you want to quickly test, do `python -m http.server` in the workspace and go to localhost:8000 in your browser. +If you want to make a pull request, do `java -jar buildtools/BuildTools.jar pullrequest` to generate a pullrequest folder. +Then, take this modified version of the repo and upload it to Github, make a pullrequest, and I will take a look. If you are making your own fork of EaglerReborn and have it open source, you can do `java -jar buildtools/BuildTools.jar merge` -to finish generating the patch files.
-
+to finish generating the patch files. + To make an offline download, run `bash MakeOfflineDownload.sh` after running `./gradlew teavm` and `bash CompileEPK.sh` diff --git a/src/plugindocs/README.md b/src/plugindocs/README.md index 1876f69..7e51b9f 100644 --- a/src/plugindocs/README.md +++ b/src/plugindocs/README.md @@ -4,9 +4,11 @@ The Plugin API consists of a global JavaScript object on the window, called, ver It has the following properties: - `player: LocalPlayerData` - - A [`LocalPlayerData`](globals/LocalPlayerData.md) made from `EntityPlayerSP`. + - A [`LocalPlayerData`](globals/LocalPlayerData.md) made from `EntityPlayerSP`. Regenerated every time the `update` event is called. - `network: NetworkData` - - A [`NetworkData`](globals/NetworkData.md) made from `NetHandlerPlayClient`. + - A [`NetworkData`](globals/NetworkData.md) made from `NetHandlerPlayClient`. Regenerated every time the `update` event is called. +- `settings: GameSettingsData` + - A [`GameSettingsData`](globals/GameSettingsData.md) made from `GameSettings`. Regenerated every time the `update` event is called. - `items: ItemData{}` - A [`ItemData`](globals/ItemData.md) dictionary of all item types, and block-item types. [Auto] - `blocks: BlockData{}` @@ -39,6 +41,8 @@ It has the following methods: - Triggers a left click ingame. - `rightClickMouse()` - Triggers a right click ingame. +- `update()` + - Force triggers a Plugin API update. Note that while the update event fires, not all objects are necessarily generated. Eg: Calling `update()` while not ingame will not generate `PluginAPI.player` or `PluginAPI.network` ### Passing 'Ref' objects Eg: `setCurrentItemOrArmor({slotIn: Integer, itemStack: ItemStackRef}) : void` diff --git a/src/plugindocs/events/addEventListener.md b/src/plugindocs/events/addEventListener.md index 21a2bbb..720de47 100644 --- a/src/plugindocs/events/addEventListener.md +++ b/src/plugindocs/events/addEventListener.md @@ -15,17 +15,24 @@ It has the following valid values: - `gui` Called when the Plugin Manager GUI shows up. No arguments passed to callback. +- `load` + Called when all plugins have finished loading. + - `update` Called every client tick. No arguments passed to callback. - `sendchatmessage` Called just before the player sends a chat message. Passes an object with properties: - `message`: String representing the chat message. - - `preventDefault:` Boolean representing whether or not to cancel sending the packet. Default is `false`. + - `preventDefault:` Boolean representing whether or not to cancel processing the chat message. Default is `false`. - `postmotionupdate` Called after player motion is updated. No arguments passed to callback. +- `motionupdate` + Called on motion update. + - `preventDefault`: Boolean representing whether or not to cancel sending motion updates to the server. + - `premotionupdate` Called before player motion is updated. Passes an object with properties: - `yaw`: Number representing the player's yaw rotation. @@ -39,8 +46,10 @@ It has the following valid values: - `preventDefault`: Boolean representing whether or not to prevent the default action for this key (if any). -More events: +### More events: + [Receiving packet events](FromServerEvents.md) + [Sending packet events](ToServerEvents.md) ### (Function) Callback diff --git a/src/plugindocs/globals/BlockData.md b/src/plugindocs/globals/BlockData.md index edba808..196067c 100644 --- a/src/plugindocs/globals/BlockData.md +++ b/src/plugindocs/globals/BlockData.md @@ -24,6 +24,7 @@ Has the following properties: - `blockResistance`: Integer: equal to the block's `blockResistance` - `noRender`: Boolean: equal to the block's `noRender` - `forceRender`: Boolean: equal to the block's `forceRender` +- `fullCube`: Boolean: equal to the block's `fullCube` It has the following methods: - `getID() : Integer` diff --git a/src/plugindocs/globals/FoodStatsData.md b/src/plugindocs/globals/FoodStatsData.md new file mode 100644 index 0000000..3202ad3 --- /dev/null +++ b/src/plugindocs/globals/FoodStatsData.md @@ -0,0 +1,19 @@ +# FoodStatsData +Represents the food stats of a player. + +Has the following properties: +- `foodLevel`: Integer +- `foodSaturationLevel`: Number +- `foodExhaustionLevel`: Number +- `foodTimer`: Integer +- `prevFoodLevel`: Integer + +Has the following methods: +- `addStats({foodLevelIn: Integer, foodSaturationModifier: Number}) : void` +- `addExhaustion({parFloat1: Number}) : void` +- `setFoodLevel({foodLevelIn: Integer}) : void` +- `setFoodSaturationLevel({foodSaturationLevelIn: Number}) : void` +- `getFoodLevel() : Integer` +- `getPrevFoodLevel() : Integer` +- `getSaturationLevel() : Number` +- `needFood() : Boolean` \ No newline at end of file diff --git a/src/plugindocs/globals/GameSettingsData.md b/src/plugindocs/globals/GameSettingsData.md new file mode 100644 index 0000000..2d24eed --- /dev/null +++ b/src/plugindocs/globals/GameSettingsData.md @@ -0,0 +1,73 @@ +# BlockData +Represents the game's settings. + +Has the following properties: +- `mouseSensitivity: Number` +- `invertMouse: Boolean` +- `renderDistanceChunks: Integer` +- `viewBobbing: Boolean` +- `anaglyph: Boolean` +- `fboEnable: Boolean` +- `limitFramerate: Integer` +- `clouds: Integer` +- `fancyGraphics: Boolean` +- `ambientOcclusion: Integer` +- `chatVisibility: String` + - Can be one of: `FULL`, `SYSTEM` or `HIDDEN` +- `chatColours: Boolean` +- `chatLinks: Boolean` +- `chatLinksPrompt: Boolean` +- `chatOpacity: Number` +- `enableVsync: Boolean` +- `snooperEnabled: Boolean` +- `allowBlockAlternatives: Boolean` +- `reducedDebugInfo: Boolean` +- `hideServerAddress: Boolean` +- `pauseOnLostFocus: Boolean` +- `touchscreen: Boolean` +- `overrideWidth: Integer` +- `overrideHeight: Integer` +- `heldItemTooltips: Boolean` +- `chatScale: Number` +- `chatWidth: Number` +- `chatHeightUnfocused: Number` +- `chatHeightFocused: Number` +- `streamBytesPerPixel: Number` +- `streamMicVolume: Number` +- `streamGameVolume: Number` +- `streamKbps: Number` +- `streamFps: Number` +- `fovSetting: Number` +- `gammaSetting: Number` +- `saturation: Number` +- `streamChatEnabled: Integer` +- `streamChatUserFilter: Integer` +- `streamMicToggleBehavior: Integer` +- `guiScale: Integer` +- `fxaa: Integer` +- `particleSetting: Integer` +- `streamCompression: Integer` +- `thirdPersonView: Integer` +- `mipmapLevels: Integer` +- `forceUnicodeFont: Boolean` +- `hudFps: Boolean` +- `hudCoords: Boolean` +- `hudPlayer: Boolean` +- `hudWorld: Boolean` +- `hudStats: Boolean` +- `hud24h: Boolean` +- `chunkFix: Boolean` +- `fog: Boolean` +- `streamSendMetadata: Boolean` +- `hideGUI: Boolean` +- `smoothCamera: Boolean` +- `debugCamEnable: Boolean` +- `showDebugInfo: Boolean` +- `showDebugProfilerChart: Boolean` +- `showInventoryAchievementHint: Boolean` +- `difficulty: String` + - Can be one of `PEACEFUL`, `EASY`, `NORMAL` or `HARD` +- `lastServer: String` +- `language: String` +- `streamPreferredServer: String` +- `keyBindings: KeyBindingData[]` \ No newline at end of file diff --git a/src/plugindocs/globals/KeyBindingData.md b/src/plugindocs/globals/KeyBindingData.md new file mode 100644 index 0000000..fa0c87d --- /dev/null +++ b/src/plugindocs/globals/KeyBindingData.md @@ -0,0 +1,18 @@ +# KeyBindingData +Represents a in-game keybind. + +Has the following properties: +- `keyCode: Integer` +- `pressTime: Integer` +- `pressed: Boolean` +- `keyDescription: String` [read-only] +- `keyCategory: String` [read-only] + +Has the following methods: +- `isKeyDown() : Boolean` +- `getKeyCategory() : String` +- `isPressed() : Boolean` +- `unpressKey() : void` +- `getKeyDescription() : String` +- `getKeyCodeDefault() : Integer` +- `getKeyCode() : Integer` \ No newline at end of file diff --git a/src/plugindocs/globals/PlayerData.md b/src/plugindocs/globals/PlayerData.md index f9984fd..4b0ca8e 100644 --- a/src/plugindocs/globals/PlayerData.md +++ b/src/plugindocs/globals/PlayerData.md @@ -3,6 +3,7 @@ Represents a player. A PlayerData usually has all of the properties of [LivingEntityData](LivingEntityData.md), and: +- `foodStats`: [FoodStatsData](FoodStatsData.md): Equal to the player's `foodStats`. - `cameraYaw`: Number: Equal to the player's `cameraYaw`. - `chasingPosX`: Number: Equal to the player's `chasingPosX`. - `chasingPosY`: Number: Equal to the player's `chasingPosY`. @@ -28,4 +29,98 @@ A PlayerData usually has all of the properties of [LivingEntityData](LivingEntit - `inventory`: [InventoryPlayerData](InventoryPlayerData.md): Equals to the player's `inventory`. - `capabilities`: [PlayerCapabilities](PlayerCapabilities.md): Equals to the player's `capabilities`. -Todo: methods. \ No newline at end of file +It has the following methods: +- `getItemInUse() : ItemStackData` +- `getItemInUseCount() : Integer` +- `isUsingItem() : Boolean` +- `getItemInUseDuration() : Integer` +- `stopUsingItem() : void` +- `clearItemInUse() : void` +- `isBlocking() : Boolean` +- `getMaxInPortalTime() : Integer` +- `getSwimSound() : String` +- `getSplashSound() : String` +- `getPortalCooldown() : Integer` +- `playSound({s: String, f: Number, f1: Number}) : void` +- `updateItemUse({itemStackIn: ItemStackData, parInt1: Integer}) : void` +- `onItemUseFinish() : void` +- `handleStatusUpdate({b0: Byte}) : void` +- `isMovementBlocked() : Boolean` +- `closeScreen() : void` +- `updateRidden() : void` +- `preparePlayerToSpawn() : void` +- `updateEntityActionState() : void` +- `onLivingUpdate() : void` +- `collideWithPlayer({parEntity: EntityData}) : void` +- `getScore() : Integer` +- `addScore({parInt1: Integer}) : void` +- `getHurtSound() : String` +- `getDeathSound() : String` +- `addToPlayerScore({entity: EntityData, i: Integer}) : void` +- `dropOneItem({flag: Boolean}) : ItemEntityData` +- `dropPlayerItemWithRandomChoice({itemStackIn: ItemStackData}) : ItemEntityData` +- `dropItem({droppedItem: ItemStackData, dropAround: Boolean, traceItem: Boolean}) : ItemEntityData` +- `joinEntityItemWithWorld({entityitem: ItemEntityData}) : void` +- `getToolDigEfficiency({parBlock: BlockData}) : Number` +- `canHarvestBlock({blockToHarvest: BlockData}) : Boolean` +- `canAttackPlayer({entityplayer: PlayerData}) : Boolean` +- `damageArmor({f: Number}) : void` +- `getTotalArmorValue() : Integer` +- `getArmorVisibility() : Number` +- `interactWith({parEntity: EntityData}) : Boolean` +- `getCurrentEquippedItem() : ItemStackData` +- `destroyCurrentEquippedItem() : void` +- `getYOffset() : Number` +- `attackTargetEntityWithCurrentItem({entity: EntityData}) : void` +- `respawnPlayer() : void` +- `isEntityInsideOpaqueBlock() : Boolean` +- `isUser() : Boolean` +- `trySleep({blockpos: BlockPos}) : String` +- `wakeUpPlayer({flag: Boolean, flag1: Boolean, flag2: Boolean}) : void` +- `isInBed() : Boolean` +- `getBedOrientationInDegrees() : Number` +- `isPlayerSleeping() : Boolean` +- `isPlayerFullyAsleep() : Boolean` +- `getSleepTimer() : Integer` +- `getBedLocation() : BlockPos` +- `isSpawnForced() : Boolean` +- `setSpawnPoint({pos: BlockPos, forced: Boolean}) : void` +- `moveEntityWithHeading({f: Number, f1: Number}) : void` +- `getAIMoveSpeed() : Number` +- `addMovementStat({parDouble1: Number, parDouble2: Number, parDouble3: Number}) : void` +- `addMountedMovementStat({parDouble1: Number, parDouble2: Number, parDouble3: Number}) : void` +- `fall({f: Number, f1: Number}) : void` +- `resetHeight() : void` +- `getFallSoundString({i: Integer}) : String` +- `setInWeb() : void` +- `getCurrentArmor({i: Integer}) : ItemStackData` +- `addExperience({amount: Integer}) : void` +- `getXPSeed() : Integer` +- `removeExperienceLevel({i: Integer}) : void` +- `addExperienceLevel({i: Integer}) : void` +- `xpBarCap() : Integer` +- `addExhaustion({parFloat1: Number}) : void` +- `getFoodStats() : FoodStatsData` +- `canEat({ignoreHunger: Boolean}) : Boolean` +- `shouldHeal() : Boolean` +- `setItemInUse({itemstack: ItemStackData, i: Integer}) : void` +- `isAllowEdit() : Boolean` +- `canPlayerEdit({parBlockPos: BlockPos, parEnumFacing: String, parItemStack: ItemStackData}) : Boolean` + - `parEnumFacing` can be one of `UP`, `DOWN`, `NORTH`, `SOUTH`, `EAST` or `WEST` +- `isPlayer() : Boolean` +- `getAlwaysRenderNameTagForRender() : Boolean` +- `clonePlayer({entityplayer: PlayerData, flag: Boolean}) : void` +- `canTriggerWalking() : Boolean` +- `sendPlayerAbilities() : void` +- `getName() : String` +- `getEquipmentInSlot({i: Integer}) : ItemStackData` +- `getHeldItem() : ItemStackData` +- `setCurrentItemOrArmor({i: Integer, itemstack: ItemStackData}) : void` +- `isInvisibleToPlayer({entityplayer: PlayerData}) : Boolean` +- `getInventory() : ItemStackData[]` +- `isPushedByWater() : Boolean` +- `getEyeHeight() : Number` +- `getOfflineUUID({username: String}) : String` +- `replaceItemInInventory({i: Integer, itemstack: ItemStack}) : Boolean` +- `hasReducedDebug() : Boolean` +- `setReducedDebug({reducedDebug: Boolean}) : void` \ No newline at end of file diff --git a/src/plugindocs/globals/Vec3i.md b/src/plugindocs/globals/Vec3i.md index 9f10055..8400c0c 100644 --- a/src/plugindocs/globals/Vec3i.md +++ b/src/plugindocs/globals/Vec3i.md @@ -5,9 +5,9 @@ Represents a 3d integer point in 3d space. PluginAPI.contructors.Vec3i({x: Integer, y: Integer, z: Integer}) Has the following properties: -- `x` : Integer -- `y` : Integer -- `z` : Integer +- `x`: Integer +- `y`: Integer +- `z`: Integer Has the following methods: - `hashCode() : Integer` From fd516ba027d32996001e8b4adc568a71d8a9169f Mon Sep 17 00:00:00 2001 From: OtterDev <144633084+OtterCodes102@users.noreply.github.com> Date: Sat, 21 Oct 2023 08:30:48 -0600 Subject: [PATCH 2/2] fix --- src/plugindocs/globals/GameSettingsData.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugindocs/globals/GameSettingsData.md b/src/plugindocs/globals/GameSettingsData.md index 2d24eed..7fa970f 100644 --- a/src/plugindocs/globals/GameSettingsData.md +++ b/src/plugindocs/globals/GameSettingsData.md @@ -1,4 +1,4 @@ -# BlockData +# GameSettingsData Represents the game's settings. Has the following properties: @@ -70,4 +70,4 @@ Has the following properties: - `lastServer: String` - `language: String` - `streamPreferredServer: String` -- `keyBindings: KeyBindingData[]` \ No newline at end of file +- `keyBindings: KeyBindingData[]`