home *** CD-ROM | disk | FTP | other *** search
/ Scene Storm / Scene Storm - Volume 1.iso / coding / c / amiexpress / source / oldheads.lzh / express.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-10-06  |  11.5 KB  |  430 lines

  1. #define SUCCESS 0
  2. #define PRIVATE 10
  3. #define LCFILES 9
  4. #define FAILURE -1
  5. #define NOTALLOWED 1
  6. #define NOTTESTED  2
  7. #define ABORT    -2 
  8. #define HISTORY 999
  9. #define MAXHIST 20
  10.  
  11. #define NOSCREENS 0
  12. #define BBSSCREENS 1
  13. #define NODESCREENS 2
  14.  
  15. #define KEYBOARD_TIMEOUT 300L
  16.  
  17. #ifndef FOREVER
  18. #    define FOREVER for(;;)
  19. #endif  FOREVER
  20.  
  21. #define FALSE 0
  22. #define TRUE  1
  23.  
  24. #define AWAIT_LOGON    0
  25. #define SYSOP_LOGON    1
  26. #define LOCAL_LOGON    2
  27. #define REMOTE_LOGON    3
  28. #define GOODBYE_LOGON    4
  29. #define SUSPEND_LOGON    5
  30.  
  31. #define STANDARD_LOGOFF    1
  32. #define SLEEP_LOGOFF    2
  33. #define OVERTIME_LOGOFF    3
  34. #define CARRIER_LOGOFF    4
  35. #define ILLEGAL_LOGOFF    5
  36.  
  37. #define ENV_IDLE        0
  38. #define ENV_DOWNLOADING 1
  39. #define ENV_UPLOADING   2
  40. #define ENV_DOORS       3
  41. #define ENV_MAIL        4
  42. #define ENV_STATS       5
  43. #define ENV_ACCOUNT     6
  44. #define ENV_ZOOM        7
  45. #define ENV_FILES       8
  46. #define ENV_BULLETINS   9
  47. #define ENV_VIEWING     10
  48. #define ENV_ACCOUNTSEQ  11
  49. #define ENV_LOGOFF      12
  50. #define ENV_SYSOP       13
  51. #define ENV_SHELL       14
  52. #define ENV_EMACS       15
  53. #define ENV_JOIN        16
  54. #define ENV_CHAT        17
  55. #define ENV_NOTACTIVE   18
  56. #define ENV_REQ_CHAT    19
  57. #define ENV_CONNECT     20
  58. #define ENV_LOGGINGON   21
  59. #define ENV_AWAITCONNECT 22
  60. #define ENV_SCANNING     23
  61. #define ENV_SHUTDOWN     24
  62. #define ENV_MULTICHAT    25
  63. #define ENV_SUSPEND      26
  64. #define ENV_RESERVE      27
  65. #define ENV_VOICE        28
  66.  
  67. #define SV_SYSOPLOG       154
  68. #define SV_LOCALLOG       155
  69. #define SV_ACCOUNTS       156
  70. #define SV_CHAT           157
  71. #define SV_NODEOFFHOOK    158
  72. #define SV_EXITNODE       159
  73. #define SV_INITMODEM      160
  74. #define SV_WHATSUP        161
  75. #define RESERVED_BLOCK10  162
  76. #define SV_INSTANT        170
  77. #define SV_RESERVE        171
  78. #define SV_CHATTOGGLE     172
  79. #define SV_AESHELL        174
  80. #define SV_CLIPBOARD      175
  81. #define SV_START          176
  82. #define SV_NEWMSG         177
  83. #define SV_QUIETNODE      178
  84. #define SV_SETNRAMS       179
  85. #define WAIT     600
  86. #define NOWAIT   FALSE
  87. #define YES      TRUE
  88. #define NO       FALSE
  89. #define ECHO     TRUE
  90. #define NOECHO   FALSE
  91. #define CSI      0x9B
  92. #define RIGHTARROW 2
  93. #define LEFTARROW 3
  94. #define UPARROW 4
  95. #define DOWNARROW 5
  96.  
  97. #define IOFLAG_FIL_IN    0
  98. #define IOFLAG_KBD_IN    1
  99. #define IOFLAG_SER_IN    2
  100. #define IOFLAG_FIL_OUT    3
  101. #define IOFLAG_PRT_OUT    4
  102. #define IOFLAG_SCR_OUT    5
  103. #define IOFLAG_SER_OUT    6
  104.  
  105. #define TIMEOUT  -3
  106. #define NO_CARRIER -4
  107. #define GOODBYE  -7
  108. #define EXITCHAT  -8
  109.  
  110. #define STAT_STARTUP    0
  111. #define STAT_LOGON    1
  112. #define STAT_LOGOFF    2
  113. #define STAT_GUEST_CALL    3
  114. #define STAT_NEW_CALL    4
  115. #define STAT_VALID_CALL    5
  116. #define STAT_MESSAGE    6
  117. #define STAT_LETTER    7
  118. #define STAT_UPLOAD    8
  119. #define STAT_DOWNLOAD    9
  120. #define STAT_NEW_MEMBER    10
  121. #define STAT_SHUTDOWN    11
  122.  
  123. #define MAX_CONFS 9                  /* Number of conferences */
  124.  
  125. struct Commands {
  126.  UBYTE   AcLvl[100], SerDevUnit;
  127.  char    SerDev[40], NEW_UserPW[15];
  128.  long    OpeningBaud;
  129.  BYTE    TaskPri;
  130.  char    ConfName[MAX_CONFS][60], ConfLoc[MAX_CONFS][60], BBSName[41], BBSLoc[41], SysopName[41];
  131.  UBYTE   PSAcLvl[6], PSRType[6], PSRatio[6];
  132.  long    PSDBytes[6], PSTime[6];
  133.  char    PSCnfAc[6][10], MInit[101], MReset[31], MRing[31], MAnswer[31], MC300[31],
  134.          MC1200[31], MC2400[31], MC4800[31], MC9600[31], MC19200[31];
  135.  short   NumConf;
  136.  char    SysPass[31], RemotePass[31];
  137.  USHORT  BaudTimes[10];
  138.  char    Pad[18];
  139. };
  140.  
  141.  
  142. struct ZModem {
  143.  char    FileName[40], TitleBar[60], ZStat[60];
  144.  long    Filesize, Cps,  Eff, RecPos, ErrorPos, ResumePos;
  145.  ULONG   ApxTime, LastTime;
  146.  char    Pad[2];
  147. };
  148.  
  149. struct TempSysopInfo {
  150.     UWORD        AccessLevel;
  151.     UWORD        RatioType;
  152.     UWORD        Ratio;
  153.     LONG        TimeTotal;
  154.     UBYTE        ConfAc[10];
  155.     };
  156.  
  157. struct User {
  158.  char    Name[31],Pass[9],Location[30],PhoneNumber[13];
  159.  USHORT  Slot_Number;
  160.  USHORT  Sec_Status,
  161.      Sec_Board,                   /* File or Byte Ratio */
  162.      Sec_Library,                 /* Ratio              */
  163.      Sec_Bulletin,                /* Computer Type      */
  164.      Messages_Posted;
  165.  /* Note ConfYM = the last msg you actually read, ConfRead is the same ?? */
  166.  ULONG   NewSinceDate, ConfRead1, ConfRead2, ConfRead3, ConfRead4,
  167.          ConfRead5,  ConfRead6,  ConfRead7,  ConfRead8, ConfRead9;
  168.  char Conference_Access[10];
  169.  USHORT  Uploads, Downloads, ConfRJoin, Times_Called;
  170.  long    Time_Last_On, Time_Used, Time_Limit, Time_Total;
  171.  ULONG   Bytes_Download, Bytes_Upload, Daily_Bytes_Limit, Daily_Bytes_Dld;
  172.  char    Expert;
  173.  ULONG   ConfYM1, ConfYM2, ConfYM3, ConfYM4, ConfYM5, ConfYM6, ConfYM7,
  174.          ConfYM8, ConfYM9;
  175.  long    BeginLogCall;
  176.  UBYTE   Protocol, UUCPA, LineLength, New_User;
  177.  };
  178.  
  179.  
  180. struct RTSUser {
  181.  char pad1[8];
  182.  char    Name[31],Pass[9],Location[30],PhoneNumber[13];
  183.  USHORT  Slot_Number;              /* max 255 should be UBYTE */
  184.  USHORT  Sec_Status,
  185.      Sec_Board,                   /* File or Byte Ratio */
  186.      Sec_Library,                 /* Ratio              */
  187.      Sec_Bulletin,                /* Computer Type      */
  188.      Messages_Posted;
  189.  /* Note ConfYM = the last msg you actually read, ConfRead is the same ?? */
  190.  ULONG   NewSinceDate;
  191.  ULONG   ConfRead[9];
  192.  char    Conference_Access[10];
  193.  USHORT  Uploads, Downloads, ConfRJoin, Times_Called;
  194.  long    Time_Last_On, Time_Used, Time_Limit, Time_Total;
  195.  ULONG   Bytes_Download, Bytes_Upload, Daily_Bytes_Limit, Daily_Bytes_Dld;
  196.  char    Expert;
  197.  ULONG   ConfYM[9];
  198.  UWORD   Area;
  199.  UWORD   ScreenType;
  200.  UBYTE   Protocol, UUCPA, LineLength, New_User;
  201.  char pad2[16];
  202.  };
  203.  
  204. struct OLDUserKeys {                 /* changes to UserKeys (RTS) */
  205.  char    UserName[31];
  206.  long    Number;
  207.  UBYTE   New_User;
  208.  UWORD   UPcps;              /* highest upload cps rate */
  209.  UWORD   DNcps;              /* highest dnload cps rate */
  210.  UWORD   Userflags;          /*                         */
  211.  char    Pad[11];            /* ?? should be 15         */
  212. };
  213.  
  214. struct UserKeys {                 /* changes to UserKeys (RTS) */
  215.  char    UserName[31];
  216.  long    Number;
  217.  UBYTE   New_User;
  218.  UWORD   UPcps;              /* highest upload cps rate */
  219.  UWORD   DNcps;              /* highest dnload cps rate */
  220.  UWORD   Userflags;          /*                         */
  221.  UWORD   baud_rate;          /* last online baud rate   */
  222.  char    Pad[9];             /* ?? should be 15         */
  223. };
  224.  
  225. struct NewUsers
  226. {
  227.    char Name[31];
  228.    char Handle[31];
  229.    char Pass[9];
  230.    char Group[31];
  231.    char PhoneNumber[13];
  232.    char Comment[4][41];
  233.    USHORT Slot_Number;
  234.    USHORT AccessLvl;
  235.    USHORT Area;
  236.    LONG Time_Last_On,Time_Used,Time_Limit,Time_Total;
  237.    char Expert;
  238.    UBYTE Protocol,UUCPA,LineLength, New_User;
  239.    USHORT ModuleAccess;
  240.    USHORT ScreenType;
  241.    USHORT ComputerType;
  242.    int Active;
  243.    int CpsUp;
  244.    int CpsDown;
  245.    LONG Baud;
  246. };
  247.  
  248. struct MailHeader {
  249.     char    Status[1];
  250.     long    MsgNumb;
  251.     char    ToName[31],
  252.         FromName[31],
  253.         Subject[31];
  254.     long    MsgDate,
  255.         Recv;
  256.     char Pad;
  257.     };
  258.  
  259. struct MailStat {
  260.     long    LowestKey,
  261.         HighMsgNum,
  262.         LowestNotDel;
  263.     char Pad[6];
  264.     };
  265.  
  266. struct ConfBase
  267. {
  268.   char Handle[31];
  269.   ULONG NewSinceDate, ConfRead,ConfYM;
  270.   ULONG Bytes_Download,Bytes_Upload;
  271.   ULONG Daily_Bytes_Limit,Daily_Bytes_Dld;
  272.   USHORT Upload,Downloads,RatioType,Ratio,Messages_Posted;
  273.   UWORD Access;
  274.   UWORD Active;
  275. };
  276. struct MyData
  277. {
  278.   int Type,Size,misc1,Version;
  279. };
  280.  
  281. struct MasterData
  282. {
  283.    struct MyData   Code;
  284.    struct ConfBase Conf;
  285. };
  286. /* stupid defines , theres gotta be a better way , will have to 
  287.    consult the Lattice Manual */
  288.  
  289. #define AbortIO(x) AbortIO((struct IORequest *)x)
  290. #define CheckIO(x) CheckIO((struct IORequest *)x)
  291. #define WaitIO(x) WaitIO((struct IORequest *)x)
  292. #define SendIO(x) SendIO((struct IORequest *)x)
  293. #define DoIO(x) DoIO((struct IORequest *)x)
  294. #define BeginIO(x) BeginIO((struct IORequest *)x)
  295.  
  296. #define OpenDevice(a, b, c, d) OpenDevice(a, b, (struct IORequest *)c, d)
  297. #define CloseDevice(x) CloseDevice((struct IORequest *)x)
  298.  
  299. #define DeleteExtIO(x) DeleteExtIO((struct IORequest *)x)
  300.  
  301. #define Tell(x)  Seek(x,0L,OFFSET_CURRENT)
  302.  
  303. #undef PutStr
  304.  
  305. struct StartOption
  306. {
  307.   SHORT LeftEdge;
  308.   SHORT TopEdge;
  309.   SHORT Width;
  310.   SHORT Height;
  311.   int BitPlanes;
  312.   BOOL StatBar;
  313.   BOOL Interlace;
  314.   BOOL DupeCheck;
  315.   BOOL QLogon;
  316.   BOOL TakeCredits;
  317.   BOOL SeenIt;
  318.   BOOL TrapDoor;
  319.   BOOL Iconify;
  320.   BOOL Eall_level;
  321.   BOOL A2232;
  322.   BOOL Toggles[10];
  323.   char Logoff[80];
  324.   char ShutDown[80];
  325.   char CycleLock[80];
  326.   char RamPen[80];
  327.   char BBSConfig[80];
  328.   char FilesNot[80];
  329.   char UserData[80];
  330.   char UserKey[80];
  331.   char OffHook[80];
  332.   char PubScreen[80];
  333.   APTR t;
  334.   APTR s;
  335. };
  336. #define ACS_ACCOUNT_EDITING      0
  337. #define ACS_BULLETINS            1
  338. #define ACS_COMMENT_TO_SYSOP     2
  339. #define ACS_DOWNLOAD             3
  340. #define ACS_UPLOAD               4
  341. #define ACS_ENTER_MESSAGE        5
  342. #define ACS_FILE_LISTINGS        6
  343. #define ACS_JOIN_CONFERENCE      7
  344. #define ACS_NEW_FILES_SINCE      8
  345. #define ACS_PAGE_SYSOP           9
  346. #define ACS_READ_MSG             10
  347. #define ACS_REMOTE_SHELL         11
  348. #define ACS_DISPLAY_USER_STATS   12
  349. #define ACS_VIEW_A_FILE          13
  350. #define ACS_EDIT_USER_INFO       14
  351. #define ACS_EDIT_USER_NAME       15
  352. #define ACS_EDIT_USER_LOCATION   16
  353. #define ACS_EDIT_PHONE_NUMBER    17
  354. #define ACS_EDIT_PASSWORD        18
  355. #define ACS_ZIPPY_TEXT_SEARCH    19
  356. #define ACS_OVERRIDE_CHAT        20
  357. #define ACS_SYSOP_DOWNLOAD       21
  358. #define ACS_SYSOP_VIEW           22
  359. #define ACS_SYSOP_READ           23
  360. #define ACS_KEEP_UPLOAD_CREDIT   24
  361. #define ACS_OVERRIDE_TIMES       25
  362. #define ACS_CLEAR_SCREEN_MSG     26
  363. #define ACS_ALLOW_FREE_RESUMING  27
  364. #define ACS_ONE_TIME_BULLETINS   28
  365. #define ACS_DO_CALLERSLOG        29
  366. #define ACS_SENTBY_FILES         30
  367. #define ACS_DO_UD_LOG            31
  368. #define ACS_SCREEN_TO_FRONT      32
  369. #define ACS_DEFAULT_CHAT_ON      33
  370. #define ACS_EALL_LEVEL           34
  371. #define ACS_DUPE_FILECHECK       35
  372. #define ACS_MSG_EDIT             36
  373. #define ACS_NODE_LIST            37
  374. #define ACS_MSG_LEVEL            38
  375. #define ACS_MSG_EXPERATION       39
  376. #define ACS_DELETE_MSG           40
  377. #define ACS_ATTACH_FILES         41
  378. #define ACS_CUSTOMCOMMANDS       42
  379. #define ACS_JOIN_SUB_CONFERENCE  43
  380. #define ACS_ZOOM_MAIL            44
  381. #define ACS_MCI_MSG              45
  382. #define ACS_EDIT_DIRS            46
  383. #define ACS_EDIT_ANY             47
  384. #define ACS_BREAK_CHAT           48
  385. //#define ADD_BIT(x) newacs[x/16] |= ten[x%16]
  386. //#define REM_BIT(x) newacs[x/16] ^= ten[x%16]
  387. //#define GET_BIT(x) newacs[x/16] |  ten[x%16]
  388.  
  389. #define LVL_ACCOUNT_EDITING      0
  390. #define LVL_COMMENT_TO_SYSOP     1
  391. #define LVL_DOWNLOAD             2
  392. #define LVL_ENTER_MESSAGE        3
  393. #define LVL_FILE_LISTINGS        4
  394. #define LVL_JOIN_CONFERENCE      5
  395. #define LVL_NEW_FILES_SINCE      6
  396. #define LVL_PAGE_SYSOP           7
  397. #define LVL_READ_MSG             8
  398. #define LVL_DISPLAY_USER_STATS   9
  399. #define LVL_UPLOAD               10
  400. #define LVL_VIEW_A_FILE          11
  401. #define LVL_EDIT_USER_INFO       12
  402. #define LVL_REMOTE_SHELL         13
  403. #define LVL_ZIPPY_TEXT_SEARCH    14
  404. #define LVL_OVERRIDE_CHAT        15
  405. #define LVL_EDIT_USER_NAME       16
  406. #define LVL_EDIT_USER_LOCATION   17
  407. #define LVL_EDIT_PHONE_NUMBER    18
  408. #define LVL_EDIT_PASSWORD        19
  409. #define LVL_SENTBY_FILES         20
  410. #define LVL_DEFAULT_CHAT_ON      21
  411. #define LVL_CLEAR_SCREEN_MSG     22
  412. #define LVL_CAPITOLS_in_FILE     23
  413. #define LVL_CHAT_COLOR_SYSOP     24
  414. #define LVL_CHAT_COLOR_USER      25
  415. #define LVL_VARYING_LINK_RATE    26
  416. #define LVL_KEEP_UPLOAD_CREDIT   27
  417. #define LVL_ALLOW_FREE_RESUMING  28
  418. #define LVL_DO_CALLERSLOG        29
  419. #define LVL_DO_UD_LOG            30
  420. #define LVL_OVERRIDE_TIMES       41
  421. #define LVL_BULLETINS            42
  422. #define LVL_SYSOP_READ           43
  423. #define LVL_NODE_NUMBER          44
  424. #define LVL_SCREEN_TO_FRONT      45
  425. #define LVL_ZOO                  46
  426. #define LVL_PKAX                 47
  427. #define LVL_LHARC                48
  428. #define LVL_WARP                 49
  429. #define LVL_ZIP                  50
  430.