downforacross / downforacross.com

Web frontend for downforacross.com -- continuation of stevenhao/crosswordsio
https://downforacrosscom.downforacross1.now.sh
MIT License
229 stars 90 forks source link

Fencing Mode #145

Closed stevenhao closed 3 years ago

stevenhao commented 3 years ago

Part 1: https://github.com/downforacross/downforacross.com/pull/146 (merged)

Part 2 (This PR):

image

Todos

Game mechanics

Acknowledgements

Credits to @cesium12 for building the original matchmaking and game server for the competitive crossword game that this PR is based on.

vercel[bot] commented 3 years ago

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/downforacross/downforacross.com/83EixLdNd9LMNy2q3VjVaiJSc13Z
✅ Preview: https://downforacrosscom-git-fencing-downforacross1.vercel.app

stevenhao commented 3 years ago

Some implementation notes

Need to support:

cesium12 commented 3 years ago

initial set of unlocked squares generated via algo (see Game Mechanics section)

FWIW, the original behavior is: The corner square itself must be white. Then, count white squares in the two available directions until hitting a black square. The product of the two counts must be between 10 and 30 for the grid to be allowed; furthermore, all clues that intersect that L-shaped region are unlocked initially. The goal is to provide a natural subsection of the grid as a reasonably sized "starting base".

color the background of correct (green) squares by the team that got it

This is one of the places where I ran into UX trouble. Most crossword interfaces shade the square the cursor is on, but I had reserved shading to indicate which team owned the square. I ended up trying to pop out the square slightly plus hatching on the rest of the light, so it would be independent of the color. (And the cell also has to indicate its cooldown somehow.)

stevenhao commented 3 years ago

The corner square itself must be white. Then, count white squares in the two available directions until hitting a black square. The product of the two counts must be between 10 and 30 for the grid to be allowed; furthermore, all clues that intersect that L-shaped region are unlocked initially.

This is really helpful! I was unsure about how to choose constants, so it helps a lot to have some reference parameters (10-30 starting corner area) that already have been tested in live gameplay.

Most crossword interfaces shade the square the cursor is on, but I had reserved shading to indicate which team owned the square.

Yeah, this is going to be tricky. I'll experiment with various styles that play nicely with the background-color-cursor... (maybe underline with color? outline?). Will also look closely at how you did it with pop-out/hatching... your UI felt very natural to me when I first used it.