Browse Source

docs(corewar): add config file for constants

pull/2072/head
Michele Sessa 1 year ago committed by Michele
parent
commit
3a10ff1af5
  1. 33
      subjects/corewar/config.md

33
subjects/corewar/config.md

@ -0,0 +1,33 @@
IND_SIZE = 2;
REG_SIZE = 4;
DIR_SIZE = REG_SIZE;
REG_CODE = 1;
DIR_CODE = 2;
IND_CODE = 3;
MAX_PLAYERS = 4;
MEM_SIZE = 4 * 1024;
IDX_MOD = MEM_SIZE / 8;
PLAYER_MAX_SIZE = MEM_SIZE / 6;
COMMENT_CHAR = '#';
LABEL_CHAR = ':';
DIRECT_CHAR = '%';
SEPARATOR_CHAR = ',';
LABEL_CHARS = "abcdefghijklmnopqrstuvwxyz_0123456789";
NAME_CMD_STRING = ".name";
DESCRIPTION_CMD_STRING = ".description";
REG_NUMBER = 16;
CYCLE_TO_DIE = 1536;
CYCLE_DELTA = 50;
NBR_LIVE = 21;
MAX_CHECKS = 10;
PROG_NAME_LENGTH = 128;
DESCRIPTION_LENGTH = 2048;
COREWAR_EXEC_SIGNATURE = 0xea83f3;
Loading…
Cancel
Save