mirror of
https://github.com/eaglerforge/EaglerForgeInjector
synced 2025-07-23 06:01:38 -09:00
Merge branch 'main' of https://github.com/eaglerforge/EaglerForgeInjector
This commit is contained in:
commit
a85b9c2524
@ -62,7 +62,7 @@ When TeaVM translates booleans, it converts booleans to integers:
|
|||||||
- `false` turns into `0`
|
- `false` turns into `0`
|
||||||
- `true` turns into `1`
|
- `true` turns into `1`
|
||||||
|
|
||||||
So when we override `hasParticlesInAlphaLayer`, we'll need to return a `0` or a `1`. Since we want the game to thing that there aren't any particles in the alpha layer, we'll return `0` (false).
|
So when we override `hasParticlesInAlphaLayer`, we'll need to return a `0` or a `1`. Since we want the game to think that there aren't any particles in the alpha layer, we'll return `0` (false).
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
(function NoParticles() {
|
(function NoParticles() {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
## /hat with ModAPI
|
## /hat with ModAPI
|
||||||
/hat is a common server-side plugin that lets you put any block/item on your head. This tutorial will explain how to register a server-side command, construct a packet, and send it to a player.
|
/hat is a common server-side plugin that lets you put any block/item on your head. This tutorial will explain how to register a server-side command, construct a packet, and send it to a player.
|
||||||
[`S09PacketHeldItemChange` constructors]()
|
[`S09PacketHeldItemChange` constructors](https://nurmarvin.github.io/Minecraft-1.8-JavaDocs/net/minecraft/network/play/server/S09PacketHeldItemChange.html)
|
||||||
|
|
||||||
|
|
||||||
As always, start with the basic boilerplate IIFE with credits:
|
As always, start with the basic boilerplate IIFE with credits:
|
||||||
|
@ -15,6 +15,7 @@ We'll begin with the basic boilerplate mod code:
|
|||||||
Let's write the client side part of the code first.
|
Let's write the client side part of the code first.
|
||||||
- We'll get the keys for the ModAPI.blocks object (ids of each block) using [`Object.keys()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/keys)
|
- We'll get the keys for the ModAPI.blocks object (ids of each block) using [`Object.keys()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/keys)
|
||||||
- Then, we'll loop over those keys, and modify their respective block to be as slippery as ice.
|
- Then, we'll loop over those keys, and modify their respective block to be as slippery as ice.
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
var blockKeys = Object.keys(ModAPI.blocks);
|
var blockKeys = Object.keys(ModAPI.blocks);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user