Note this only is the first step in web support, although the project compiles, it doesn't run!
Merging now to avoid branch divergence, until dependencies can be updated for wasm support.
* Add instructions to build for wasm32-unknown-unknown with wasm-pack in www/
* Update to rust-clipboard fork to compile with emscripten
https://github.com/aweinstock314/rust-clipboard/pull/62
* Exclude reqwest dependency in wasm32
* Exclude compiling clipboard pasting on wasm32
* Exclude reqwest-using code from wasm32
* Install wasm target with rustup in Travis CI
* Update to collision 0.19.0
Fixes wasm incompatibility in deprecated rustc-serialize crate: https://github.com/rustgd/collision-rs/issues/106
error[E0046]: not all trait items implemented, missing: `encode`
--> github.com-1ecc6299db9ec823/rustc-serialize-0.3.24/src/serialize.rs:1358:1
* Increase travis_wait time even further, try 120 minutes
* Set RUST_BACKTRACE=1 in main
* Remove unused unneeded bzip2 features in zip crate
To fix wasm32-unknown-unknown target compile error:
error[E0432]: unresolved imports `libc::c_int`, `libc::c_uint`, `libc::c_void`, `libc::c_char`
--> src/github.com-1ecc6299db9ec823/bzip2-sys-0.1.7/lib.rs:5:12
|
5 | use libc::{c_int, c_uint, c_void, c_char};
| ^^^^^ ^^^^^^ ^^^^^^ ^^^^^^ no `c_char` in the root
| | | |
| | | no `c_void` in the root
| | no `c_uint` in the root
| no `c_int` in the root
* flate2 use Rust backend
* Add console_error_panic_hook module for wasm backtraces
* Build using wasm-pack, wasm-bindgen, run with wasm-app
* Update to miniz_oxide 0.2.1, remove patch for https://github.com/Frommi/miniz_oxide/issues/42
* Update to official clipboard crate since https://github.com/aweinstock314/rust-clipboard/pull/62 was merged, but git revision pending release
* Update to branch of glutin attempting to build for wasm
https://github.com/iceiix/glutin/pull/1
* Update winit dependency of glutin to git master
https://github.com/iceiix/winit/pull/2
* Update to glutin branch with working (compiles, doesn't run) wasm_stub
* Add app name in title on web page
* Add wasm to Travis-CI test matrix
* Update glutin to fix Windows EGL compilation on AppVeyor
97797352b5
Adds support for 1.13.2 protocol (404)
Expands https://github.com/iceiix/steven/issues/18 Enhance protocol support
Metadata:
* Support 1.13.2 slot data format, bool and varint item id, optional damage (moved to NBT)
https://wiki.vg/index.php?title=Slot_Data&type=revision&diff=14363&oldid=7835
Packets:
* Add 1.13.2 packets, and implement all the command data parsers
https://wiki.vg/Command_Data#Parsers
* Send new plugin channel minecraft:brand
https://wiki.vg/Plugin_channels#minecraft:brand
* Add 1.13.2 metadata format, with shifted IDs
https://wiki.vg/Entity_metadata#Entity_Metadata_Format
* Implement particle entity metadata
* Add structures for 16 new packets
Blocks: The Flattening:
* Assign flattened IDs in correct order using new 'offset' macro token
* Assign hierarchical (pre-flattening) block IDs sequentially by counting Some data
* Split VANILLA_ID_MAP into flat/hier struct, to support before and after the flattening
* Extend travis build time to 20 minutes because the blocks macro takes a long time
* Support both flat/hier blocks by passing protocol_version to by_vanilla_id
Add block states and offsets for all blocks, replacing metadata for 1.13+:
* Add stripped logs and what was Log2 to Log
* Add the Wood blocks, should be called bark, previously Axis::None Log
* Add leaves distance and offset
* Add jungle/acacia to Leaves moved from Leaves2
* Add dispenser offsets, direction
* Add note block states
* Add offset None to Missing253 and Missing254, no holes in block states of 1.13.2
* Add bed colors
* Add seagrass, tall seagrass, remove redundant deadgrass, and piston offset
* Add torch, TNT, fire offsets, remove slabs
* Add furnance offset, merges lit into a property
* Add pressure plate offsets, new pressure plates, redstone ore/lit merged
* Add lever offsets, new directions from ceiling/floor, rename LeverDirections
* Add redstone torch offsets, new blocks since lit/unlit is now merged, and standing/wall is split
* Change lever to split face/facing, rm LeverDirection, add AttachedFace
* Add stone button offsets, face/facing similar to lever
* Move face/facing data and variant to AttachedFace, reuse for lever/stonebutton
* Add data_with_facing_and_powered() to AttachedFace, for lever/stonebutton
* Add wooden button offsets each wood
* Add pumpkin without a face
* Add carved pumpkin, portal offsets
* Add lit pumpkin (as jack-o-lantern) offsets after carved pumpkin
* Add repeater offsets, merged into Repeater
* Change brown mushroom block to booleans instead of MushroomVariant
* Add mushroom block offsets, red/brown mushroom blocks, and a new mushroom stem block
* Add command block, cobblestone walls, and flower pot offsets
Empty flower pot, and potted plants including saplings. Rename
variant DarkOak to DarkOakSaplings because it is a sapling, and
remove the duplicate Dandelion variant which causes duplicate blocks.
* Increase recursion limit in steven_blocks
* Add colored banner offsets
* Add wooden slab including double slab, in a different position for pre-1.13 and 1.13
* StoneSlabVariant::Wood -> StoneSlabVariant::PetrifiedWood
* Add fence_gate_offset() for wooden fence gates
* Add frosted ice age, offset
* Add new blocks: kelp, turtle egg, coral, coral fans, sea pickle, blue ice, smooth stone
* Add new blocks: conduit, void air, cave aid, bubble column, last of the 1.13 blocks
* Add glutin dependency
* Create a glutin window
* Use the glutin window, basics work
* Store DPI factor on game object, update on Resized
* Use physical size for rendering only. Fixes UI scaled too small
Fixes https://github.com/iceiix/steven/pull/35#issuecomment-442683373
See also https://github.com/iceiix/steven/issues/22
* Begin adding mouse input events
* Listen for DeviceEvents
* Call hover_at on mouse motion
* Listen for CursorMoved window event, hovering works
Glutin has separate WindowEvent::CursorMoved and
DeviceEvent::MouseMotion events, for absolute cursor and relative mouse
motion, respectively, instead of SDL's Event::MouseMotion for both.
* Use tuple pattern matching instead of nested if for MouseInput
* Implement left clicking
* Use grab_cursor() to capture the cursor
* Hide the cursor when grabbing
* Implement MouseWheel event
* Listen for keyboard input, escape key release
* Keyboard input: console toggling, glutin calls backquote 'grave'
* Implement fullscreen in glutin, updates https://github.com/iceiix/steven/pull/31
* Update settings for glutin VirtualKeyCode
* Keyboard controls (note: must clear conf.cfg to use correct bindings)
* Move DeviceEvent match arm up higher for clarity
* Remove SDL
* Pass physical dimensions to renderer tick so blit_framebuffer can use full size but the ui is still sized logically.
* Listen for DeviceEvent::Text
* Implement text input using ReceivedCharacter window event, works
https://github.com/iceiix/steven/pull/35#issuecomment-443247267
* Request specific version of OpenGL, version 3.2
* Request OpenGL 3.2 but fallback to OpenGL ES 2.0 if available (not tested)
* Set core profile and depth 24-bits, stencil 0-bits
* Allow changing vsync, but require restarting (until https://github.com/tomaka/glutin/issues/693)
* Clarify specific Rust version requirement
* Import glutin::* in handle_window_event() to avoid overly repetitive code
* Linux in VM fix: manually calculate delta in MouseMotion
For the third issue on https://github.com/iceiix/steven/pull/35#issuecomment-443084458https://github.com/tomaka/glutin/issues/1084 MouseMotion event returns absolute instead of relative values, when running Linux in a VM
* Heuristic to detect absolute/relative MouseMotion from delta:(xrel, yrel); use a higher scaling factor
* Add clipboard pasting with clipboard crate instead of sdl2
https://github.com/iceiix/steven/pull/35#issuecomment-443307295
* Add handwritten RSA PKCS1 encryption using num-bigint and simple_asn1
* Add more logging to compare OpenSSL with/without side-by-side
* Log message and ciphertext in hex
* Print N and e as hexadecimal integers
* Fix bad encryption caused by zeros in PKCS1 padding
PS field in https://tools.ietf.org/html/rfc8017#section-7.2.1
Must be nonzero
* Use rand fill instead of rand_bytes
* Remove OpenSSL!
* Update CI scripts and docs to not install OpenSSL
* Remove copying OpenSSL DLLs (libeay and ssleay) in AppVeyor script
* Change rsa_public_encrypt_pkcs1 to return a Result<Vec<u8>, String>
* Add error checking, returning Err<String> on failure; RFC comments
* Add the required message representative range checking
* Use expect() instead of unwrap() on from_der
* Map the ASN.1 error to a String to return it from rsa_public_encrypt_pkcs1() instead of panicking
* Move RSA to a new crate, rsa_public_encrypt_pkcs1
https://github.com/iceiix/rsa_public_encrypt_pkcs1
* Update to rsa_public_encrypt_pkcs1 with simple_asn 0.1.0
https://github.com/iceiix/rsa_public_encrypt_pkcs1/issues/1
* Update to published version of rsa_public_encrypt_pkcs1, 0.1.0
* Remove unnecessarily added blank line
* Remove libssl-dev from .travis.yml
* Remove seemingly unneeded const on MetadataKey<T> new
* Change biome temperature/moisture to integer, x100 to remove floating-point so can use within stable 'const fn'
* Remove unstable const_fn feature, now using stable const fn: see https://www.reddit.com/r/rust/comments/9msqfn/const_fn_soon_on_stable_rust/
* Test on Rust beta (awaiting 1.31 release for stable)
* Update readme for beta Rust support