zackmdavis / Leafline

an oppositional strategy game engine
MIT License
5 stars 2 forks source link

don't save space in correspondence postcards #33

Closed zackmdavis closed 3 years ago

zackmdavis commented 3 years ago

The space-saving measures in c04afe38a1 broke the web client. (It was possible to make the first move, but it got confused immediately thereafter because the client couldn't understand the compressed rank_and_file field now being sent from the game engine.) I'm less afraid of editing five-year-old Rust than JavaScript, so let's slap in some From/Into conversions to make the JSON output be the way it used to rather than updating the client.

FoxLisk commented 3 years ago

this seems good! i have never written an impl From<> before but i'm assuming that it works based on you merging it, and it looks like a smart way to handle the impedance mismatch to me.