From a01aad1250864b94b9757826e744dd02ce1cd07d Mon Sep 17 00:00:00 2001 From: Yufan You Date: Wed, 18 May 2022 15:28:21 +0800 Subject: [PATCH] docs: add FAQ and update other docs --- README.md | 18 +++ src/components/AboutDialog.vue | 217 +++++++++++++++++++---------- src/components/PlausibleDialog.vue | 5 +- 3 files changed, 164 insertions(+), 76 deletions(-) diff --git a/README.md b/README.md index 53e5442..00c5d16 100644 --- a/README.md +++ b/README.md @@ -12,3 +12,21 @@ sudo pnpm build-treesitter:cpp # requires docker pnpm serve pnpm build ``` + +## Puzzles + +The puzzles are in the `puzzles` directory which is not managed in this Git repository. + +The file structure looks like this: + +``` +codle +├── package.json +└── puzzles + ├── 1.cpp + ├── 1.md + ├── 2.cpp + └── 2.md +``` + +You may need to calculate the week number or change `beginTimestamp` in [config.ts](config.ts). diff --git a/src/components/AboutDialog.vue b/src/components/AboutDialog.vue index 9925e6b..49f5598 100644 --- a/src/components/AboutDialog.vue +++ b/src/components/AboutDialog.vue @@ -3,83 +3,154 @@ - - Codle is a game developed by - . - In this game, you need to guess the Abstract Syntax Tree (AST) - of a piece of code called "target code". - It's like - - with AST nodes as "letters". - - - It's open-sourced at - - under the - - license. It makes use of - , - , - , - - and many other dependencies which can be found in the source code. - - - Thanks should also go to people who examined the original idea and - provided valuable suggestions at the early stage of this game. - - - If you have any suggestions, please open an - - on GitHub. - - - If you enjoy this game, consider - - (currently only accepting WeChat and AliPay) - - - Further information can be found at - . - + + + Codle is a game developed by + . + In this game, you need to guess the Abstract Syntax Tree (AST) + of a piece of code called "target code". + It's like + + with AST nodes as "letters". + + + It's open-sourced at + + under the + + license. It makes use of + , + , + , + + and many other dependencies which can be found in the source code. + + + Thanks should also go to people who examined the original idea and + provided valuable suggestions at the early stage of this game. + + + If you have any suggestions, please open an + + on GitHub. + + + If you enjoy this game, consider + + (currently only accepting WeChat and AliPay) + + + Further information can be found at + . + + + FAQ + + + Tips: You can ask more questions at + . + + + + Why not make daily puzzles? +

+ To give you more time to solve the puzzles :) +
+ Well, I have to admit that's not the main reason. + Unlike Wordle and many other puzzle games, Codle's puzzles cannot be auto-generated. + I need to manually select a coding problem that suits Codle well, + write a solution that is fun to guess and provides enough hints via variable names, etc, + and rewrite the problem statement in Markdown. + It takes at least a half and sometimes a few hours + if puzzle quality is taken into count. +

+
+ + Can I play previous puzzles? +

+ On the official game site, unfortunately, no you can't :( +
+ However, you can click the calendar icon on the top to see all previous puzzles. + Codle is + , + so you can run Codle locally and play previous puzzles or custom puzzles. +

+
+ + How many people play Codle? +

+ Take the week of 8 May - 14 May 2022 as an example, + there were 111 visitors and 10 game successes. + So please share (your scores) with others if you like this game :) +

+
+ + What are other players' scores? +

+ In the first 6 weeks, according to the anonymously collected guess count data, + the average number of guesses is 47.8 and the median is 34.5. +

+
+ + I succeeded without a correct solution to the problem! +

+ That's how Codle works :) +
+ AST is the only thing that matters, your code doesn't even need to compile. +

+
+
+