aboutsummaryrefslogtreecommitdiff
path: root/src/moves.rs
diff options
context:
space:
mode:
authoreug-vs <eugene@eug-vs.xyz>2023-01-22 04:31:43 +0300
committereug-vs <eugene@eug-vs.xyz>2023-01-22 04:31:43 +0300
commitc7b627574945a8c492e05db168726737cd301b39 (patch)
tree099ab65146421017badb4338c0e1e4d56203135c /src/moves.rs
parenteb54ede6d11ed9f3817e4521d47b23b0c7d642a2 (diff)
downloadchessnost-c7b627574945a8c492e05db168726737cd301b39.tar.gz
feat: add initial moves module
Diffstat (limited to 'src/moves.rs')
-rw-r--r--src/moves.rs21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/moves.rs b/src/moves.rs
new file mode 100644
index 0000000..0dd5353
--- /dev/null
+++ b/src/moves.rs
@@ -0,0 +1,21 @@
+use crate::board::Square;
+
+#[derive(Debug)]
+pub struct Move {
+ from: Square,
+ to: Square,
+}
+
+// TODO: think about the size
+type MoveList = [Move; 1024];
+
+#[cfg(test)]
+mod tests {
+ use super::*;
+
+ #[test]
+ fn mock() {
+ let mov = Move { from: Square::E2, to: Square::E4 };
+ println!("{:?}", mov);
+ }
+}