From 900c8756edc3bc547dfd2cd47921ecd453bf703b Mon Sep 17 00:00:00 2001 From: jjanzen Date: Tue, 21 Jan 2025 23:26:23 -0600 Subject: doc comments and io refactor --- src/actions.zig | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'src/actions.zig') diff --git a/src/actions.zig b/src/actions.zig index 431a6d0..ac46574 100644 --- a/src/actions.zig +++ b/src/actions.zig @@ -1,13 +1,33 @@ +//! This module provides an enum of available actions in game including internal signals. const std = @import("std"); +/// An enum of available actions in the game pub const Action = enum { + /// Illegal action. Treated as a noop. illegal, + + /// One game tick has finished. tick, + + /// Exit the game. exit, + + /// Move the player character up one tile. move_up, + + /// Move the player character down one tile. move_down, + + /// Move the player character left one tile. move_left, + + /// Move the player character right one tile. move_right, + + /// The player character goes down a flight of stairs. down_stair, + + /// The player character goes up a flight of stairs. + /// (TODO: possibly merge with down_stair) up_stair, }; -- cgit v1.2.3