diff options
| author | Charles <sircharlesaze@gmail.com> | 2020-06-28 09:40:47 +0200 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2020-06-28 09:40:47 +0200 |
| commit | 15e690e0dc9f539ca0e8e9c98c3fdc9105ec9d74 (patch) | |
| tree | d60e39bdac9d2447b89e56dac88b8877b5005378 /inc/tower.h | |
| parent | feae9f442000cf218c249e6e163e8b5137771857 (diff) | |
| download | hanoi-15e690e0dc9f539ca0e8e9c98c3fdc9105ec9d74.tar.gz hanoi-15e690e0dc9f539ca0e8e9c98c3fdc9105ec9d74.tar.bz2 hanoi-15e690e0dc9f539ca0e8e9c98c3fdc9105ec9d74.zip | |
Diffstat (limited to 'inc/tower.h')
| -rw-r--r-- | inc/tower.h | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/inc/tower.h b/inc/tower.h deleted file mode 100644 index da3fb1e..0000000 --- a/inc/tower.h +++ /dev/null @@ -1,43 +0,0 @@ -/* ************************************************************************** */ -/* */ -/* . */ -/* tower.h / \ */ -/* / \ */ -/* By: charles <charles.cabergs@gmail.com> /o o \ */ -/* / v \ */ -/* Created: 2020/06/27 14:06:50 by charles / _ \ */ -/* Updated: 2020/06/28 08:12:37 by charles '-----------' */ -/* */ -/* ************************************************************************** */ - -#ifndef TOWER_H -# define TOWER_H - -# include <stdlib.h> -# include <stdint.h> -# include <stddef.h> -# include <string.h> - -# include <ncurses.h> - -# define MAX_HEIGHT 128 - -typedef struct -{ - uint8_t data[MAX_HEIGHT]; - size_t len; -} t_tower; - -enum e_highlight -{ - HIGHLIGHT_NONE = 0, - HIGHLIGHT_FROM = 1 << 0, - HIGHLIGHT_CURRENT = 1 << 1, -}; - -void towers_init(t_tower towers[3], size_t disk_num); -void towers_move(t_tower towers[3], size_t from, size_t to); -void tower_put(t_tower *tower, WINDOW *win, enum e_highlight highlight_level); -uint8_t tower_peek(t_tower *tower); - -#endif |
