mirror of
https://github.com/boy0001/FastAsyncWorldedit.git
synced 2024-11-22 02:25:53 +01:00
Page:
Packet sending
Pages
API
Anvil API
AsyncWorld
Brushes
Clipboard API
Commands
Configuration
Copying a region to another world.
CreateFromImage
Download Instructions: Bukkit Spigot
Fawe TaskManager
FawePlayer
FaweQueue
Home
JavaScript API
Jobs API
Light API
NBT stream API
Packet sending
Pasting a schematic
Permissions
Progress API
Recovering corrupt NBT files (MCA Schematic etc.)
Region restriction API
Registering Custom Masks, Patterns and Transforms
Registering custom brushes or commands
Rollback API
Some tips when using the FAWE API
TaskBuilder
TextureUtil block and biome coloring
Third party loggers
Transforms
Web API
WorldEdit FAWE mask list
WorldEdit EditSession
WorldEdit World Player
WorldEdit and FAWE patterns
2
Packet sending
Jesse Boyd edited this page 2017-03-27 11:02:11 +11:00
FAWE can send block changes either by refreshing the chunk, or sending individual block changes. Brush visualization is an example of the latter, in which block changes are sent to only one player (Note: Blocks don't have to be changed on the server).
There's the VisualExtent which is optimized to only send 1 block (glass), and reset the changes after.
VisualExtent extent = new VisualExtent(editSession.getExtent(), editSession.getQueue());
// set some blocks
extent.visualize(player);
// Some time later, reset all blocks
// If you pass another visual extent, it won't reset blocks present in that.
extent.clear(VisualExtent or null);
To send specific blocks to a bunch of players use the FaweQueue. You can use any FaweChunk class, e.g. CharFaweChunk, VisualChunk etc.
FaweQueue.sendBlockUpdate(FaweChunk, FawePlayer...);
This Wiki is for Legacy Versions (1.8 - 1.12.2). Check here for 1.13+ versions: https://github.com/IntellectualSites/FastAsyncWorldEdit-Documentation/