Notes on the Server: Since I was using command line parameters for the net code, I just kept these near the top of server.c. Feel free to change them for now. const int HPscalefactor = 1; For human games, you might want to change this to 3 or 5 or so, dividing the HP by that number. This makes games shorter. const int outputlevel=3; This can be set to anything from 0 to 3. It'll adjust the amount of output displayed by the server. Also, you can make adjustments to the server if you wish for training purposes, as long as your client still works with my server. Notes on Coding: (Information on all the different structs and constants used is in globalstuff.h) There are only two functions you REALLY need to edit - the selectplayer and the chooseaction functions in the client. ***************************************** selectplayer - used during the party selection part of the game. int selectplayer(int charav[], character allchar[],int listlength,int parnum,party player,int enumb,party player2) charav[0...listlength-1] is a list of valid character indicies. allchar[0...18] is the list of all the characters. listlength is the number of characters available to you. parnum is the current size of your party. player.members[0...parnum-1] are your current party members. enumb is the current size of the enemy party. player2.members[0...enumb-1] are the current enemy party members. Valid output here is an integer 0 <= c < listlength. This means you want to use player allchar[charav[c]]. Server does bounds checking and will assign you selection 0 if you choose out of bounds. (This doesn't mean you should be lazy about doing it yourself.) Most of the AI gaming stuff we're looking for will go in chooseaction. There is some strategy to picking characters based on who's in what party, but this process doesn't need to be too fancy. ***************************************** chooseaction - used during the attack selection of the game. int chooseaction(int vaction[PARTYSIZE*ATTACKS*PARTYSIZE+1][3],int numacs, party att, party off,int lastmove[3]) vaction[0...numacs-1][0...2] are all the valid actions you can make. vaction[0][0...2] means "wait". The values stored are dummy values. vaction[x][0...2] means player vaction[x][0] performs attack vaction[x][1] on player vaction[x][2]. att is your party off is the enemy party lastmove[0...2] is the last action your enemy took, in case you want to know. Valid output here is an integer 0 <= c < numacs. This means you wish to perform the attack vaction[c][0...3]. Server does bounds checking and will make you wait if you choose out of bounds. ***************************************** There are also other things you can do in your program. Declare more variables (or rename them... the names I came up with late at night really suck and I won't be offended), make some input/output system, the like. Anything that doesn't screw up the server's ability to talk to you is okay. You might want to write something to respond to the end of the game. ***************************************** mechanics.c is a very useful thing. You can't make changes to it, but I'm leaving it uncompiled so you can look at it and steal bits from it if you want. If you would rather treat it as a black box, these are the functions you might find useful. int validactions(int vaction[PARTYSIZE*ATTACKS*PARTYSIZE+1][3],party att, party off) give this function an integer array (full of garbage is fine), and the current states of the attacking and defending parties, and it will fill the array with useful information about what actions are valid and return the number of valid action. void update(int action[PARTYSIZE*ATTACKS*PARTYSIZE+1][3],int anum, party att[], party off[]) give this function the array of valid actions, the index of the one you're considering, and (disposable) copies of the parties in question. It will change the parties to reflect the action. (A lot of functions seem to pass in and out much more information than is really necessary - this was for the sake of the net code.)