Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

amigo.h

Go to the documentation of this file.
00001 /**********************************************************************
00002 ** Copyright (C) 2000 Trolltech AS.  All rights reserved.
00003 **
00004 ** This file is part of Qtopia Environment.
00005 **
00006 ** This file may be distributed and/or modified under the terms of the
00007 ** GNU General Public License version 2 as published by the Free Software
00008 ** Foundation and appearing in the file LICENSE.GPL included in the
00009 ** packaging of this file.
00010 **
00011 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
00012 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
00013 **
00014 ** See http://www.trolltech.com/gpl/ for GPL licensing information.
00015 **
00016 ** Contact info@trolltech.com if any conditions of this licensing are
00017 ** not clear to you.
00018 **
00019 **********************************************************************/
00020 /*=========================================================================
00021 ===                                                                     ===
00022 === FILE        amigo.h                                                 ===
00023 ===                                                                     ===
00024 === CONTENTS    prototypes for the various AmiGo routines.              ===
00025 ===             added by neilb                                          ===
00026 ===                                                                     ===
00027 =========================================================================*/
00028 
00029 #ifndef __amigo_h
00030 #define __amigo_h
00031 
00032 #include "go.h"
00033 #include "goplayutils.h"
00034 
00035 #ifdef __STDC__
00036 #define PROTO(fp)       fp
00037 #else
00038 #define PROTO(fp)       ()
00039 #endif
00040 
00041 
00042 #ifdef __cplusplus
00043 extern "C" {
00044 #endif
00045 
00046 /* From goplayer.c */
00047 
00048 
00049 
00050 /* Procedures from amigo.c */
00051 
00052 short   Connect PROTO((enum bVal, short, short, short[4], short[4], short *, short * ));
00053 short   Maxlibs PROTO((short, short));
00054 short   Suicide PROTO((enum bVal, short, short));
00055 short   StoneLibs PROTO((short, short));
00056 void    EraseMarks PROTO(());
00057 short   GoPlaceStone PROTO((enum bVal, short, short));
00058 void    GoRemoveStone PROTO((short, short));
00059 void    MergeGroups PROTO((short, short));
00060 void    DeleteGroup PROTO((short));
00061 void    ReEvalGroups PROTO((enum bVal, short, short, short));
00062 void    GroupCapture PROTO((short));
00063 void    FixLibs PROTO((enum bVal, short, short, short));
00064 int     CountUp PROTO((int*, int*));
00065 /*void  main PROTO(());*/
00066 void    goRestart PROTO((int));
00067 void    RelabelGroups PROTO(());
00068 short   CountAndMarkLibs PROTO((short, short));
00069 void    CountLiberties PROTO((short));
00070 void    CheckForEye PROTO((short, short, short[4], short, short *));
00071 void    CountEyes PROTO(());
00072 void    printGroupReport PROTO((short, short));
00073 
00074 
00075 /* killable.c */
00076 
00077 int     tryPlay PROTO(( short, short, short ));
00078 int     sSpanGroup PROTO(( short, short, sPointList * ));
00079 int     spanGroup PROTO(( short, short, pointList *));
00080 int     pause PROTO(());
00081 
00082 int     genState PROTO(());
00083 int     initGPUtils PROTO(());
00084 int     genBord PROTO((enum bVal));
00085 
00086 short   genMove PROTO(( enum bVal, short *, short * ));
00087 short   checkPos PROTO(( short, short, short ));
00088 short   takeCorner PROTO(( short *, short * ));
00089 short   extend PROTO(( short *, short * ));
00090 short   noNbrs PROTO(( short, short ));
00091 short   extend2 PROTO(( short *, short * ));
00092 short   lookForSave PROTO(( short *, short * ));
00093 short   lookForSaveN PROTO(( short *, short * ));
00094 short   lookForKill PROTO(( short *, short * ));
00095 short   doubleAtari PROTO(( short *, short * ));
00096 short   lookForAttack PROTO(( short *, short * ));
00097 short   threaten PROTO(( short *, short * ));
00098 short   connectCut PROTO(( short *, short * ));
00099 short   heCanCut PROTO(( short, short ));
00100 short   safeMove PROTO(( short, short ));
00101 short   extendWall PROTO(( short *, short * ));
00102 short   findAttack2 PROTO(( short *, short * ));
00103 short   blockCut PROTO(( short *, short * ));
00104 short   cutHim PROTO(( short *, short * ));
00105 short   atariAnyway PROTO(( short *, short * ));
00106 short   underCut PROTO(( short *, short * ));
00107 short   dropToEdge PROTO(( short *, short * ));
00108 short   pushWall PROTO(( short *, short * ));
00109 short   reduceHisLiberties PROTO(( short *, short * ));
00110 short   dropToEdge2 PROTO(( short *, short * ));
00111 
00112 
00113 /* goplayutils.c */
00114 
00115 short   saveable PROTO((short, short, short *, short *));
00116 short   killable PROTO((short, short, short *, short *));
00117 int     initBoolBoard PROTO((boolBoard));
00118 int     intersectPlist PROTO((pointList *, pointList *, pointList *));
00119 int     initArray PROTO((intBoard));
00120 int     initState PROTO(());
00121 int     copyArray PROTO((intBoard, intBoard));
00122 int     stake PROTO(());
00123 int     spread PROTO(());
00124 int     respreicen PROTO(());
00125 int     tryPlay PROTO((short, short, short));
00126 int     saveState PROTO(());
00127 int     restoreState PROTO(());
00128 short   tencen PROTO((short, short));
00129 int     genConnects PROTO(());
00130 int     sortLibs PROTO(());
00131 
00132 
00133 /*-- from xinterface.c --*/
00134 void    removestone PROTO((short, short));
00135 void    placestone PROTO((enum bVal, short, short));
00136 
00137 void    intrMoveReport PROTO((enum bVal,char *,char *));
00138 void    intrPrisonerReport PROTO(( short, short ));
00139 
00140 
00141 #ifdef __cplusplus
00142 }
00143 #endif
00144 
00145     
00146 #endif

Generated on Sat Nov 5 16:17:19 2005 for OPIE by  doxygen 1.4.2