|
Atrinik Client 2.5
|
00001 /************************************************************************ 00002 * Atrinik, a Multiplayer Online Role Playing Game * 00003 * * 00004 * Copyright (C) 2009-2011 Alex Tokar and Atrinik Development Team * 00005 * * 00006 * Fork from Daimonin (Massive Multiplayer Online Role Playing Game) * 00007 * and Crossfire (Multiplayer game for X-windows). * 00008 * * 00009 * This program is free software; you can redistribute it and/or modify * 00010 * it under the terms of the GNU General Public License as published by * 00011 * the Free Software Foundation; either version 2 of the License, or * 00012 * (at your option) any later version. * 00013 * * 00014 * This program is distributed in the hope that it will be useful, * 00015 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00016 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 00017 * GNU General Public License for more details. * 00018 * * 00019 * You should have received a copy of the GNU General Public License * 00020 * along with this program; if not, write to the Free Software * 00021 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * 00022 * * 00023 * The author can be reached at admin@atrinik.org * 00024 ************************************************************************/ 00025 00030 #include <global.h> 00031 00032 #ifndef SCRIPTS_H 00033 #define SCRIPTS_H 00034 00036 enum CmdFormat 00037 { 00039 ASCII, 00041 SHORT_ARRAY, 00043 INT_ARRAY, 00045 SHORT_INT, 00047 MIXED, 00049 STATS, 00051 NODATA 00052 }; 00053 00055 struct script 00056 { 00058 char *name; 00059 00061 char *params; 00062 00064 char cmd[HUGE_BUF]; 00065 00066 #ifndef WIN32 00067 00068 int out_fd; 00069 00071 int in_fd; 00072 #else 00073 HANDLE out_fd; 00074 HANDLE in_fd; 00075 #endif 00076 00078 int cmd_count; 00079 00080 #ifndef WIN32 00081 00082 pid_t pid; 00083 #else 00084 DWORD pid; 00085 00087 HANDLE process; 00088 #endif 00089 00091 char **events; 00092 00094 int events_count; 00095 }; 00096 00097 #endif
1.7.4