|
|
1.1 ! root 1: /* ! 2: * Copyright (c) 1980 Regents of the University of California. ! 3: * All rights reserved. The Berkeley software License Agreement ! 4: * specifies the terms and conditions for redistribution. ! 5: * ! 6: * @(#)robots.h 5.1 (Berkeley) 5/30/85 ! 7: */ ! 8: ! 9: # include <curses.h> ! 10: # include <setjmp.h> ! 11: ! 12: /* ! 13: * miscellaneous constants ! 14: */ ! 15: ! 16: # define Y_FIELDSIZE 23 ! 17: # define X_FIELDSIZE 60 ! 18: # define Y_SIZE 24 ! 19: # define X_SIZE 80 ! 20: # define MAXLEVELS 4 ! 21: # define MAXROBOTS (MAXLEVELS * 10) ! 22: # define ROB_SCORE 10 ! 23: # define S_BONUS (60 * ROB_SCORE) ! 24: # define Y_SCORE 21 ! 25: # define X_SCORE (X_FIELDSIZE + 9) ! 26: # define Y_PROMPT (Y_FIELDSIZE - 1) ! 27: # define X_PROMPT (X_FIELDSIZE + 2) ! 28: # define MAXSCORES (Y_SIZE - 2) ! 29: # define MAXNAME 16 ! 30: # define MS_NAME "Ten" ! 31: # define SCOREFILE "/usr/games/lib/robots_roll" ! 32: ! 33: /* ! 34: * characters on screen ! 35: */ ! 36: ! 37: # define ROBOT '+' ! 38: # define HEAP '*' ! 39: # define PLAYER '@' ! 40: ! 41: /* ! 42: * pseudo functions ! 43: */ ! 44: ! 45: # undef CTRL ! 46: # define CTRL(X) ('X' - 'A' + 1) ! 47: ! 48: /* ! 49: * type definitions ! 50: */ ! 51: ! 52: typedef struct { ! 53: int y, x; ! 54: } COORD; ! 55: ! 56: /* ! 57: * global variables ! 58: */ ! 59: ! 60: extern bool Dead, Full_clear, Jump, Newscore, Real_time, Running, ! 61: Teleport, Waiting, Was_bonus; ! 62: ! 63: #ifdef FANCY ! 64: extern bool Pattern_roll, Stand_still; ! 65: #endif ! 66: ! 67: extern char Cnt_move, Field[Y_FIELDSIZE][X_FIELDSIZE], *Next_move, ! 68: *Move_list, Run_ch; ! 69: ! 70: extern int Count, Level, Num_robots, Num_scores, Score, ! 71: Start_level, Wait_bonus; ! 72: ! 73: extern COORD Max, Min, My_pos, Robots[]; ! 74: ! 75: extern jmp_buf End_move; ! 76: ! 77: /* ! 78: * functions types ! 79: */ ! 80: ! 81: int quit(), cmp_sc(), move_robots(); ! 82: ! 83: COORD *rnd_pos();
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.