back to scratko.xyz
aboutsummaryrefslogtreecommitdiff
path: root/field.h
diff options
context:
space:
mode:
authorscratko <m@scratko.xyz>2025-07-31 03:55:59 +0300
committerscratko <m@scratko.xyz>2025-08-12 03:43:35 +0300
commite79798e5ecc85738813363c3025961b0099802fb (patch)
tree6fce5a438871f0a8eeeb1160b7153e5914d5adc9 /field.h
parentcba2e3ddd2596f519750aed1179da8a757023850 (diff)
downloadpacman-e79798e5ecc85738813363c3025961b0099802fb.tar.gz
pacman-e79798e5ecc85738813363c3025961b0099802fb.tar.bz2
pacman-e79798e5ecc85738813363c3025961b0099802fb.zip
Add README and revise distance metricHEADmaster
Added many inline comments for clarity. Introduced initial version of README with gameplay details, controls, and AI logic. Replaced Euclidean distance with Manhattan distance in standard_distance() to better match grid-based movement without diagonal traversal.
Diffstat (limited to 'field.h')
-rw-r--r--field.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/field.h b/field.h
index 728d75a..7bce8c5 100644
--- a/field.h
+++ b/field.h
@@ -16,6 +16,12 @@ enum intersection_type {
one_path = '1',
two_paths = '2',
three_paths = '3',
+ /*
+ * Yellow blocks': ghosts can't go up from these tiles during normal
+ * movement. When entering from left or right, they can only continue
+ * straight. This restriction is ignored in frightened mode or during
+ * mode transitions.
+ */
yellow_block = 'y',
direct_path
};