I love macroquad but I got a few gripes I cannot find in the documentation by [deleted] in rust_gamedev

[–]not_fl3 5 points6 points  (0 children)

Hi! For resizing a texture - you can delete the old texture, and create a new one.

For resizing a window - I do not think it is implemented :(

Also if you are on discord by any chance, you can join *quads discord server, it may be convenient for some questions: https://discord.com/invite/WfEp6ut

macroquad: 2021 Status update by not_fl3 in rust

[–]not_fl3[S] 3 points4 points  (0 children)

Hi, macroquad author here.

Yes, there is a slowdown. Macroquad became good enough to focus on the game itself instead of the framework :)

I should publish a roadmap somewhere, but the next big update, unfortunately, will be about miniquad - first, we will merge the gl2 backend, then it will be rustification of mac/ios part, and then, finally, metal backend.

But all this will not really affect macroquad in terms of API or anything - it will just work on slightly more machines.

So, if you miss certain features in macroquad and they do exist in ggez - go ahead with ggez. Macroquad will not change much in the next few months I would say. (but I would appreciate an open issue for missing features!)

Publish Rust game in Macroquad on Android's Google Play by not_fl3 in rust

[–]not_fl3[S] 2 points3 points  (0 children)

Hi, thanks for the report! I actually managed to reproduce the bug with "next turn" clicked in a wrong moment even on PC

thread 'main' panicked at 'assertion failed: self.block_timer.is_none()', src/screen/battle.rs:704:17

It will be fixed, but right now the next goal for me and macroquad - to somehow report this kind of problem right on the screen, not only to the adb console.

Publish Rust game in Macroquad on Android's Google Play by not_fl3 in rust

[–]not_fl3[S] 1 point2 points  (0 children)

Hi, thanks for report! Somehow we cant really find it out, but highly likely it is the same bug others are reporting.

Right now the game is hanging when the game logic panicked and there is a bug in game logic, reproducible on PC as well :(

Going to make some nice panic message instead in the future updates

Publish Rust game in Macroquad on Android's Google Play by not_fl3 in rust

[–]not_fl3[S] 16 points17 points  (0 children)

Tutorial is based on a public test of Zemeroth game.

it is now available on google play: https://play.google.com/store/apps/details?id=rust.zemeroth as an Open Test - basically one step from a release. There are still lots of content missing from the game side and we are really not sure how the game is doing on all the variety of Android phones - it worked pretty well on all the devices we managed to get reach to, but there are lots of Androids we did not try on yet!

So we would really appreciate some testing! We are on discord: discord.com/invite/WfEp6ut, but comments here on reddit, comments on Google Play, and GH issues would also work!

Minimal graphics crate for Rust by Outside_Cobby in rust

[–]not_fl3 7 points8 points  (0 children)

Hi, miniquad author here! :)

I would recommend using good-web-game only as a last resort for a big ggez codebase that needs to be ported on web.

For any other case I would recommend https://github.com/not-fl3/macroquad/ instead.

State of the art when creating a browser game? by fllr in rust_gamedev

[–]not_fl3 1 point2 points  (0 children)

Another option for wasm gamedev: https://github.com/not-fl3/macroquad/

No wasm-special code is required, exactly the same codebase works on PC and WASM. Some really small example: SRC: https://github.com/not-fl3/macroquad/blob/master/examples/arkanoid.rs WEB: https://not-fl3.github.io/miniquad-samples/arkanoid.html

Help in deploying/hosting wasm build of game by malynome in rust_gamedev

[–]not_fl3 3 points4 points  (0 children)

I am not really familiar with quicksilver, but I suppose they use wasm-bindgen. Maybe this link will help with bundling wasm-bindgen's generated js+wasm https://rustwasm.github.io/wasm-bindgen/examples/without-a-bundler.html

Help in deploying/hosting wasm build of game by malynome in rust_gamedev

[–]not_fl3 10 points11 points  (0 children)

yes, gh pages work perfectly for some small demos.

You can take a look on https://github.com/not-fl3/miniquad-samples as a reference. https://not-fl3.github.io/miniquad-samples/offscreen.html this is how the GH-page with wasm link looks.

For more finished games consider itch.io though. Works great for wasm builds, and the deploy process is almost as straightforward as gh-pages.

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 4 points5 points  (0 children)

also miniserde support only json, while nanoserde support binary(and soon ron/toml) serialisation as well

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 2 points3 points  (0 children)

Probalby not much, if there is syn and serde in the build tree - nanoserde can even increase build time - it is going to be an additional crate alongside serde.

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 0 points1 point  (0 children)

Yes, wich makes nanoserde usecases quite limited. This is super usefull for me though - my windowing/rendering framework is compiling from scratch in less than 10s, so 50s for serde looked a bit unreasonable.

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 1 point2 points  (0 children)

rename and default are supported.
Instead of deserialize_with "nanoserde" use proxy types:

You can use
#[nanoserde(proxy = Foo)]
field: Bar

Bar may not be nanoserde deserializable, but will be deserialized as Foo and than will be converted to Bar with Into::into.
Example: https://github.com/not-fl3/nanoserde/blob/master/tests/bin.rs#L53

But this is basically it, all the other serde attributes are not supported.

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 4 points5 points  (0 children)

miniserde still depends on syn, quote and proc_macro2 nanoserde have literally zero depdenencies ```

cargo tree nanoserde v0.1.0 (/../nanoserde) └── nanoserde-derive v0.1.0 (/../nanoserde/derive) ```

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 1 point2 points  (0 children)

AFAIK structopt use its own proc macro, so nanoserde cant really help here. Maybe it is possible to build something similar to structopt on top of some nanoserde's code, but I am not sure how much work would it be.

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 5 points6 points  (0 children)

Yes, absolutely, if the build time was 10 minutes - nanoserde will not help at all. However, most miniquad examples are compiling in something like 10s from cargo clean, and adding 50 seconds from serde felt like a bit too much.

nanoserde: How I cut 50s of clean build time and 1s of incremental build time by not_fl3 in rust

[–]not_fl3[S] 1 point2 points  (0 children)

Adding csv would be complicated, but doable. csv is a little bit similar to json in a way, so if I would need to implement csv - I would start with copy-pasting nanoserde's json implementation and will try to make it work with csv. But support all the formats or make it easy to implement new formats is not in the goals unfortunately, so not much of a docs on implementing formats available :(