diff options
author | Elisey Puzko <puzko.e02@gmail.com> | 2018-02-22 20:07:08 +0100 |
---|---|---|
committer | Elisey Puzko <puzko.e02@gmail.com> | 2018-02-22 20:07:08 +0100 |
commit | 228423d91518d0b8bd1c4bf047f3d378567e00f9 (patch) | |
tree | e05f4d5ddb11794bb4eb8691e8970d063599e669 /src/GameState.cpp | |
parent | New event: SelectedBlockChanged (diff) | |
download | AltCraft-228423d91518d0b8bd1c4bf047f3d378567e00f9.tar AltCraft-228423d91518d0b8bd1c4bf047f3d378567e00f9.tar.gz AltCraft-228423d91518d0b8bd1c4bf047f3d378567e00f9.tar.bz2 AltCraft-228423d91518d0b8bd1c4bf047f3d378567e00f9.tar.lz AltCraft-228423d91518d0b8bd1c4bf047f3d378567e00f9.tar.xz AltCraft-228423d91518d0b8bd1c4bf047f3d378567e00f9.tar.zst AltCraft-228423d91518d0b8bd1c4bf047f3d378567e00f9.zip |
Diffstat (limited to 'src/GameState.cpp')
-rw-r--r-- | src/GameState.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/GameState.cpp b/src/GameState.cpp index 3166f1a..b963ef0 100644 --- a/src/GameState.cpp +++ b/src/GameState.cpp @@ -582,3 +582,11 @@ void GameState::CancelDigging() { auto packet = std::static_pointer_cast<Packet>(packetCancel); PUSH_EVENT("SendPacket", packet); } + +void GameState::PlaceBlock() { + auto packetPlace = std::make_shared<PacketPlayerBlockPlacement>( + selectedBlock, 1, 0, 0.0, 0.0, 0.0); + + auto packet = std::static_pointer_cast<Packet>(packetPlace); + PUSH_EVENT("SendPacket", packet); +}
\ No newline at end of file |