-
-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
50fa7f6
commit 9890e57
Showing
14 changed files
with
154 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
minecraft/protocol/packet/compressed_biome_definition_list .go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package packet | ||
|
||
import ( | ||
"github.com/sandertv/gophertunnel/minecraft/protocol" | ||
) | ||
|
||
type CompressedBiomeDefinitionList struct { | ||
SerialisedBiomeDefinitions []byte | ||
} | ||
|
||
// ID ... | ||
func (*CompressedBiomeDefinitionList) ID() uint32 { | ||
return IDCompressedBiomeDefinitionList | ||
} | ||
|
||
func (pk *CompressedBiomeDefinitionList) Marshal(io protocol.IO) { | ||
io.Bytes(&pk.SerialisedBiomeDefinitions) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package packet | ||
|
||
import ( | ||
"github.com/go-gl/mathgl/mgl32" | ||
"github.com/sandertv/gophertunnel/minecraft/protocol" | ||
) | ||
|
||
// OpenSign is sent by the server to open a sign for editing. As of 1.19.80, the player can interact with a sign to edit | ||
// either the text on either side instead of just the front. | ||
This comment has been minimized.
Sorry, something went wrong. |
||
type OpenSign struct { | ||
// Position is the position of the sign to edit. The client uses this position to get the data of the sign, including | ||
// the existing text and formatting etc. | ||
Position mgl32.Vec3 | ||
// FrontSide dictates whether the front side of the sign should be opened for editing. If false, the back side is | ||
// assumed to be edited. | ||
FrontSide bool | ||
} | ||
|
||
// ID ... | ||
func (*OpenSign) ID() uint32 { | ||
return IDOpenSign | ||
} | ||
|
||
func (pk *OpenSign) Marshal(io protocol.IO) { | ||
io.Vec3(&pk.Position) | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong. |
||
io.Bool(&pk.FrontSide) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package packet | ||
|
||
import ( | ||
"github.com/sandertv/gophertunnel/minecraft/protocol" | ||
) | ||
|
||
type TrimData struct { | ||
Patterns []protocol.TrimPattern | ||
Materials []protocol.TrimMaterial | ||
} | ||
|
||
// ID ... | ||
func (*TrimData) ID() uint32 { | ||
return IDTrimData | ||
} | ||
|
||
func (pk *TrimData) Marshal(io protocol.IO) { | ||
protocol.Slice(io, &pk.Patterns) | ||
protocol.Slice(io, &pk.Materials) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
package protocol | ||
|
||
type TrimPattern struct { | ||
ItemName string | ||
PatternID string | ||
} | ||
|
||
// Marshal ... | ||
func (x *TrimPattern) Marshal(r IO) { | ||
r.String(&x.ItemName) | ||
r.String(&x.PatternID) | ||
} | ||
|
||
type TrimMaterial struct { | ||
MaterialID string | ||
Colour string | ||
ItemName string | ||
} | ||
|
||
// Marshal ... | ||
func (x *TrimMaterial) Marshal(r IO) { | ||
r.String(&x.MaterialID) | ||
r.String(&x.Colour) | ||
r.String(&x.ItemName) | ||
} |
"the player can interact with a sign to edit either the text on either side instead of just the front."