Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/shmup/redbean-cardgames
To become a collection of card games within a redbean
https://github.com/shmup/redbean-cardgames
cardgames fullmoon lua mithriljs redbean
Last synced: 1 day ago
JSON representation
To become a collection of card games within a redbean
- Host: GitHub
- URL: https://github.com/shmup/redbean-cardgames
- Owner: shmup
- Created: 2022-07-30T09:11:46.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-08-29T04:11:03.000Z (about 2 years ago)
- Last Synced: 2024-08-03T17:07:59.717Z (3 months ago)
- Topics: cardgames, fullmoon, lua, mithriljs, redbean
- Language: JavaScript
- Homepage:
- Size: 9.03 MB
- Stars: 8
- Watchers: 3
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-cosmopolitan - redbean-cardgames - Upcoming collection of cardgames playable in a browser (Redbean / Projects)
README
# Card games
The idea here is to have a [redbean](https://justine.lol/redbean2/) loaded with card games, both playable in
your shell and in a GUI (aka your browser via localhost).Starting small, I will introduce a couple [patience games](), followed up by 2+ player games against an AI. With those in place, I can consider handling wetware multiplayer (though maybe only in the GUI).
```bash
$ make test
π±: π
π²: π
π³: ππΆπΉ
π΄: ππΈπ½
[π΅π·πΊπ»] [πΎ]
```## β‘ TODO
#### [Calculation]() (patience)
- [ ] Update GameState after drag/drop (currently only updated on the DOM)
- [ ] Fire a validate request during a `dragenter` or `drop` ?
* Kinda pointless but I wanted to toy with keeping that kinda stuff "truly" hidden until client needs it
- [ ] Handle winning (aka empty talon and empty tableaus)
- [ ] Handle losing (determining if a game is unwinnable)
- [ ] Add some cute free sounds (or make my own)
- [x] Render unicode playing cards instead of indexes
- [x] Validate placement of cards in foundations
- [x] Render cards in the browser
- [x] Add drag/drop events## β’ Developer Documentation
- https://redbean.dev/
- https://github.com/pkulchenko/fullmoon/## β§ Lua Documentation
- https://devdocs.io/lua~5.4/
- https://learnxinyminutes.com/docs/lua/## β€ Sqlite Documentation
- https://devdocs.io/sqlite/
- https://learnxinyminutes.com/docs/sql/-----
#### Example of drag and drop
https://html.spec.whatwg.org/multipage/dnd.html#drag-and-drop-processing-model
https://user-images.githubusercontent.com/118710/185034491-11b5eb0e-0441-4f7a-8ee5-720b699457ef.mp4