Quick Note
Createpatch is a script that uses a svn location to update the tmmokit folder, the distrib folder, and the patchfile svn location. If you are installing the kit from scratch with nothing else on the server the easiest thing to do is simply click on the initialsetup.bat file in the install folder and it will setup the patchfiles and kitfiles svn for you. Once this is done you can use the createpatch file without any modifications as long as the kit install is c:\tmmokit as it is hard coded into the file. If you do not want to do this or want to use another location please read a bit further down to get more information on how to modify the script.
Basics
Createpatch uses a script to pull changes from a svn location (kitfiles by default) and publish it to the patchfiles svn to be used by the patching process, distrib folder for creating a client installer, and to the tmmokit folder to update the server with the new files. It also takes care of running genesis to update the databases and runs upgrade.bat to upgrade the databases afterwards. Literally you shut down the server processes, run this file, and start it back up and everything should be good to go.
In order to run createpatch you need to copy whatever changes you want to show up to the kitfiles svn. If you ran the initialsetup.bat file it will create this svn location and publish all of the basic files you need to it and commit the changes. After that you simply add the files to the svn. By default using the initialsetup.bat file the usernames and passwords to get entry are the same as the one for your game, so those are user:admin password:mypassword for full access and user:starter password:mmo for read access. It should only have the basic published files in there initially. You will want to add your mud folder and other files in there as you go along. All you do is copy the changes to this svn, commit then, and run the script to push the changes out. So lets say you download the AFX bits and want to add them. You would copy over the files needed in testgame.mmo and put them in the appropriate place, commit to svn, and then run the createpatch.bat file to update everything. As you start to work with more than 1 person this will be a perferred method of working as it allows multiple people to share and update what they are doing and it creates a bit of redundancy as well.
Running the Script
The first time you run the script you simply want to type this in the command line.
createpatch 0
This will use revision 0 from the kitfiles svn which is empty and will go through the process of creating all of the patch files you need. The first time running this should take a bit as it copies all of the files over that is needed and submits the ones that are already there. The next it only sends the basic updates so it will take less time.
After you have done this you only need to run this process once you have updated the kitfiles svn with actual files. You will want to specify which revisions you want to use. Examples below:
createpatch 1 <-- Use Revision 1 createpatch 2:5 <-- Use Revisions 2 through 5
You can get the revision information by looking at the logs. This will take care of adding and deleting any files that you have changed.
Things to watch for
* Changes to gamesettings.py and main.cs you will want to change back to your server specific settings after the patch
* You might get a few warnings if files are deleted and you are doing multiple revisions that once had that file
* Make sure to update your kitfiles location before running the patch as it will use the existing files in the location
Creating the kitfiles svn without using the script
You might not want to run the script to screw everything up, so here is what you need to do to get it running. Enter this from the command line.
c: cd c:\svnrepo svnadmin create kitfiles
Then open up c:\svnrepop\svnaccess.txt and add this to the bottom
[kitfiles:/] admin = rw starter = r
After that restart the Apache Service and type this again in the command line. Please note the username and password below, if you changed it use whatever you changed it to. As well as the location of the distrib folder in tmmokit might need to be changed if you have it somewhere else.
cd c:\mygame svn checkout http://127.0.0.1/svn/kitfiles kitfiles --username admin --password mypassword xcopy c:\tmmokit\distrib\common c:\mygame\kitfiles\trunk /e /h /y /i cd \ cd mygame cd kitfiles svn add --force * svn commit -m "Revision"
Using your own svn location for kitfiles or patchfiles
You will need to know a bit about the location and name of the svn. It is recommended that there is at least one level of folders before the files you want such as a trunk folder or a branch folder. In order to put in new values you need to open up the createpatch.bat file and make a handful of changes.
* All of the svn2folder calls to have their 3 options changed as noted below. Please make sure to use a / instead of a \ and the options must end with a /
* The first line is the location of the svn files on the server.
* The 2nd part is the part that is going to be clipped from the svn information so the files can be copied to the appropriate path. I would follow how it is setup as the example and replace /trunk with your file structure up to the files.
* The 3rd part is the destination for the files. This will be the tmmokit directory or the patchfiles directory
* Change any other reference to patchfiles to another svn location if you wish to use something besides patchfiles for storing the patches.[br]]
* If you want to use another patch for the server files besides c:\tmmokit change those references as well.
