Age | Commit message (Collapse) | Author | |
---|---|---|---|
2025-02-24 | Implement test for int->card | Aryadev Chavali | |
2025-02-24 | Implement test for suit->int and int->suit being complete inverses | Aryadev Chavali | |
2025-02-24 | Implement test for suit->int | Aryadev Chavali | |
2025-02-24 | Implement test for rank->int and int->rank being complete inverses | Aryadev Chavali | |
2025-02-24 | Implement test for rank->int | Aryadev Chavali | |
2025-02-24 | Implement test for int->rank | Aryadev Chavali | |
2025-02-24 | Make suit->int and int->suit complete inverses | Aryadev Chavali | |
2025-02-22 | Extract error generation from `player-exists?` to ensure it's an indicator | Aryadev Chavali | |
2025-02-22 | Put dependencies for each test rather than on the suite. | Aryadev Chavali | |
2025-02-22 | Quickload cantedraw/tests in bob:qload | Aryadev Chavali | |
2025-02-22 | Implement specific function generation functions for each threading macro | Aryadev Chavali | |
2025-02-22 | Fix --> to not convert first argument, if it's a symbol, to a form. | Aryadev Chavali | |
2025-02-22 | Make card a structure | Aryadev Chavali | |
Card is a structure instead of just a type. Stronger type checking, automatic constructor, destructors and existence check. | |||
2025-02-21 | Add unit tests for model.int->suit | Aryadev Chavali | |
2025-02-21 | Make empty unit test suite for model package | Aryadev Chavali | |
2025-02-21 | Add unit tests for lib.functions.remove-at-indices | Aryadev Chavali | |
2025-02-21 | Add unit tests for lib.functions.rev-map | Aryadev Chavali | |
2025-02-21 | Add unit tests for lib.functions.split | Aryadev Chavali | |
2025-02-21 | Add unit tests for lib.functions.take | Aryadev Chavali | |
2025-02-21 | Add unit tests for lib.functions.range | Aryadev Chavali | |
2025-02-21 | Add unit tests for lib.functions.parse-integer* | Aryadev Chavali | |
2025-02-21 | Setup an empty unit test suite for lib.functions | Aryadev Chavali | |
I've added a dependency so if lib.macros isn't working, we can skip all the tests in lib.functions. Therefore we can use lib.macros in the test code. | |||
2025-02-21 | Add unit tests for lib.macros.-<> | Aryadev Chavali | |
2025-02-21 | Add unit tests for lib.macros.->> | Aryadev Chavali | |
2025-02-21 | Create a unit test system | Aryadev Chavali | |
Setup cantedraw/tests with a test-system record, as well as linking it back to cantedraw so we can run test-system on cantedraw and run the tests. Using parachute, we can setup a suite of unit tests for each package. For each package in src/ or lib/ we'll write a separate unit test suite with tests for all the public exposing functionality. I've setup a main suite in cantedraw/tests/main which will depend on each of the unit test suites so we can run the tests all at once. Currently we have one test for the --> macro. | |||
2025-02-19 | Implement -<> operator for threading an argument through first parameter | Aryadev Chavali | |
2025-02-15 | Added :author and :license to system definition | Aryadev Chavali | |
2025-02-15 | Rework player package to use structures and a hash table | Aryadev Chavali | |
Instead of an association list and a type contract, let's use a hash table and a structure. This is: more explicit, encapsulates state more effectively, generates much of the cruft (constructors, destructors) for me. A hash table is more efficient when considering large player bases. In particular, we'll be generating unique player IDs to make it a bit more difficult for a malicious agent to guess another player's ID and make bad requests. | |||
2025-02-15 | Yakshaving bob the builder | Aryadev Chavali | |
2025-02-15 | Add nicknames for all packages (cantedraw -> 5d) | Aryadev Chavali | |
2025-02-15 | Disable image compression for binary. | Aryadev Chavali | |
2025-02-15 | Clean up player-{pay,receive} | Aryadev Chavali | |
Clean up the implementation of player-pay and player-receive by: - Single-clause early-error `if` for errors - use `incf`/`decf` instead of `setf`. | |||
2025-02-15 | Introduce custom errors for player handling | Aryadev Chavali | |
Custom errors for malformed/nonexistent player IDs as well as a player not having a high enough balance for the money requested. This will allow me to encode more information in the errors, for callers to use. I'm generally of the opinion that callers should be checking error conditions before calling these functions, but per Murphy's law it would be nice to have more information in the error message. | |||
2025-02-15 | Player handler package | Aryadev Chavali | |
This package defines a player data structure, collections of players, and different interactions you can have with them: - Extracting attributes (destructors) - Checking if they're bankrupt or can bet - Modifying a collection to adjust the balance of any one player (including errors in case that isn't possible) | |||
2025-02-15 | Small changes | Aryadev Chavali | |
2025-02-15 | Rework `$` operator to take a capture variable | Aryadev Chavali | |
In case operators require use of a variable, we should let the caller provide the symbol so we don't fall into weird package issues. | |||
2025-02-15 | Added a tasks file to keep track of what to do next | Aryadev Chavali | |
2025-02-14 | Implement read-and-confirm for extra step before re-deal | Aryadev Chavali | |
Found that I sometimes did a misinput which lead to losing a critical card - implemented a function which asks for confirmation (with a print out of the cards that will be redealt) before doing the redeal. | |||
2025-02-14 | Rework cantedraw.main:start to run a read-redeal-print-loop | Aryadev Chavali | |
We've now got one of the major stages of the game down. I think it's worth investing in some testing functions now - we've reached just the level of complexity. | |||
2025-02-14 | Implement a read -> redeal -> print loop | Aryadev Chavali | |
Like REPL stands for Read -> Evaluate -> Print -> Loop, here we implement a similar loop which reads a set of indices for cards to remove from the user, redeals those cards then loops back. This keeps happening until either: - the user does not want to redeal (empty input) - there aren't enough cards for a redeal | |||
2025-02-14 | Fix problem with alexandria:shuffle not being truly random | Aryadev Chavali | |
Due to the way random works, we need to see it on each run of the binary - thus need to make a new random state. | |||
2025-02-14 | Rework read-until-valid-integers to work better for redeal inputs | Aryadev Chavali | |
A player may: - not redeal any cards - redeal all their cards Therefore the indices must be between 0,5 and there can be at most 5 inputs. | |||
2025-02-14 | Rework card< comparator to make Jokers the top of the hierarchy | Aryadev Chavali | |
2025-02-14 | Implement a package for some game mechanics | Aryadev Chavali | |
Currently can deal some hands and redeal some cards. | |||
2025-02-14 | Implement a function to remove specific indices from a list | Aryadev Chavali | |
2025-02-14 | Split source code into different modules for cleanliness | Aryadev Chavali | |
2025-02-14 | Update gitignore, add requirements to README, rework bob and build | Aryadev Chavali | |
2025-02-14 | WIP: Making a simple re-deal program. | Aryadev Chavali | |
Gives a hand from a shuffled deck to the user, asks them to provide indices for cards they wish to re-deal then does so. | |||
2025-02-14 | Adjust Bob so we can use quickload the project to get all dependencies | Aryadev Chavali | |
2025-02-14 | Refactor Joker generation in make-deck to use mapcar on a range. | Aryadev Chavali | |
This new version is terser while still expressing what I want. |