changeset 16:281ca8daa911 grumpy-goblin

Traipse 'OpenRPG' {090808-00} Traipse is a distribution of OpenRPG that is designed to be easy to setup and go. Traipse also makes it easy for developers to work on code without fear of sacrifice. 'Grumpy-Goblin' was created as a stablizing branch in an effort to remove bugs from core code. Update Summary: This version is stable. ServerGUI works with very few problems, Update Manager is working quite well, and the software has been improved in overall stability This update cleans print statements, adds the /tmp/tmp.txt placeholder, and removes one major bug that caused errors to appear with the ServerGUI
author sirebral
date Sat, 08 Aug 2009 00:35:09 -0500
parents b6c6ec28ba8a
children 265b987cce4f 57106cf03b14
files orpg/networking/mplay_server.py orpg/networking/mplay_server_gui.py orpg/orpg_version.py upmana/tmp/tmp.txt upmana/updatemana.py
diffstat 5 files changed, 16 insertions(+), 22 deletions(-) [+]
line wrap: on
line diff
--- a/orpg/networking/mplay_server.py	Fri Aug 07 22:06:09 2009 -0500
+++ b/orpg/networking/mplay_server.py	Sat Aug 08 00:35:09 2009 -0500
@@ -2408,17 +2408,15 @@
             self.log_msg("Exception: send_to_all(): " + str(e))
 
     def send_to_group(self, from_id, group_id, data):
-        msg = ("<msg to='all' from='0' group_id='"+group_id+"'><font color='#FF0000'>" + data + "</font>")
-        #data = ServerPlugins.postParseIncoming(data)
+        #data = ("<msg to='all' from='0' group_id='"+str(group_id)+"'><font color='#FF0000'>" + data + "</font>")
+        data = ServerPlugins.postParseIncoming(data) #Function breaks here.
         try:
-            print data
             self.p_lock.acquire()
             keys = self.groups[group_id].get_player_ids()
             self.p_lock.release()
-            print keys
             for k in keys:
                 if k != from_id:
-                    self.players[k].outbox.put(msg)
+                    self.players[k].outbox.put(data)
         except Exception, e:
             traceback.print_exc()
             self.log_msg("Exception: send_to_group(): " + str(e))
--- a/orpg/networking/mplay_server_gui.py	Fri Aug 07 22:06:09 2009 -0500
+++ b/orpg/networking/mplay_server_gui.py	Sat Aug 08 00:35:09 2009 -0500
@@ -224,7 +224,7 @@
     def updateRoom( self, data ):
         (room, room_id, player) = data
         i = self.FindItemData( -1, int(player) )
-        self.SetStringItem( i, 3, room )
+        if i > 0: self.SetStringItem( i, 3, room )
         self.AutoAjust()
 
     def setPlayerRole( self, id, role ):
@@ -262,8 +262,6 @@
             for r in self.roomList:
                 if room == self.roomList[r]: groupID = r
                 else: groupID = 0
-            print self.roomList[groupID]
-            #groupID = self.roomList.get("'"+room+"'"); print groupID
             if menuItem == MENU_PLAYER_BOOT:
                 print "booting player: ", playerID
                 self.main.server.server.del_player( playerID, groupID )
@@ -277,8 +275,7 @@
             elif menuItem == MENU_PLAYER_SEND_ROOM_MESSAGE:
                 print "Send message to room..."
                 msg = self.GetMessageInput( "Send message to room of this player")
-                if len(msg):
-                    self.main.server.server.send_to_group("0", str(groupID), msg )
+                if len(msg): self.main.server.server.send_to_group('0', str(groupID), msg )
 
             elif menuItem == MENU_PLAYER_SEND_SERVER_MESSAGE:
                 print "broadcast a message..."
--- a/orpg/orpg_version.py	Fri Aug 07 22:06:09 2009 -0500
+++ b/orpg/orpg_version.py	Sat Aug 08 00:35:09 2009 -0500
@@ -4,7 +4,7 @@
 #BUILD NUMBER FORMAT: "YYMMDD-##" where ## is the incremental daily build index (if needed)
 DISTRO = "Traipse"
 DIS_VER = "Grumpy Goblin"
-BUILD = "090807-00"
+BUILD = "090808-00"
 
 # This version is for network capability.
 PROTOCOL_VERSION = "1.2"
@@ -17,4 +17,4 @@
 # for the micro
 NEEDS_PYTHON_MAJOR = 2
 NEEDS_PYTHON_MINOR = 5
-NEEDS_PYTHON_MICRO = 4
+NEEDS_PYTHON_MICRO = 2
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/upmana/tmp/tmp.txt	Sat Aug 08 00:35:09 2009 -0500
@@ -0,0 +1,1 @@
+upmana/tmp/
--- a/upmana/updatemana.py	Fri Aug 07 22:06:09 2009 -0500
+++ b/upmana/updatemana.py	Sat Aug 08 00:35:09 2009 -0500
@@ -99,7 +99,7 @@
         orpg.tools.validate.Validate(orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep).config_file(filename, "default_ignorelist.txt")
         self.mana = self.LoadDoc()
         for ignore in self.ignorelist:
-            shutil.copy(ignore, orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep)
+            shutil.copy(ignore, orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep +ignore.split('/')[len(ignore.split('/')) - 1])
         hg.clean(self.repo, self.current)
         for ignore in self.ignorelist:
             shutil.copyfile(orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep + ignore.split('/')[len(ignore.split('/')) - 1], ignore)
@@ -195,7 +195,7 @@
         self.filelist.SetValue('')
         self.filelist.AppendText("Files that will change\n\n")
         self.changelog.SetValue('')
-        changelog = "Traipse 'OpenRPG' Update Manager.\n\nThis is Dev Build 0.6.9(stable) of the Update Manager. This version is nearly 100% functional. Users can now add repositories of OpenRPG, choose from different branches available from those repositories, and add files to an ignore list.\n\nThe Update Manager is divided into tabs, Updater, Repos, Manifest, and Control. \n\nUpdater: Set your update type on startup; Auto, None. Select a package of changes from a branch and update.\n\nRepos: Collect repositories of different projects. Set a name then assign it a URL. Refresh repositories in your list or delete them from your list.\n\nManifest: A complete list of all the files in your current change set. Check files off that you want to be safe from future updates.\n\nControl: Incomplete. Future revisions will allow users to update to specific revision branchs and delete branches from their computer.\n\nThis is a good start. Enjoy the freedom!!"
+        changelog = "Traipse 'OpenRPG' Update Manager.\n\nThis is Dev Build 0.7 (open beta) of the Update Manager. This version is nearly 100% functional. Users can now add repositories of OpenRPG, choose from different branches available from those repositories, and add files to an ignore list.\n\nThe Update Manager is divided into tabs, Updater, Repos, Manifest, and Control. \n\nUpdater: Set your update type on startup; Auto, None. Select a package of changes from a branch and update.\n\nRepos: Collect repositories of different projects. Set a name then assign it a URL. Refresh repositories in your list or delete them from your list.\n\nManifest: A complete list of all the files in your current change set. Check files off that you want to be safe from future updates.\n\nControl: Incomplete. Future revisions will allow users to update to specific revision branchs and delete branches from their computer.\n\nThis is a good start. Enjoy the freedom!!"
         self.changelog.AppendText(changelog + '\n')
         self.filelist.AppendText("Traipse 'OpenRPG'\n\n Currently selected branch: " + branch + "\n\nFile List: When Control is completed this field will display a list of files that will be affected by your selection of branch.  The window to the left will display the description of the branch.\n\nDescription: Stable releases will have a formated Description that displays the Build Number, a summary of the branch, and a summary of the changes in the selected changeset.")
 
@@ -477,7 +477,7 @@
         self.open_rpg.add_component("dir_struct", orpg.dirpath.dir_struct)
         self.validate = orpg.tools.validate.Validate()
         self.open_rpg.add_component("validate", self.validate)
-        self.updater = updaterFrame(self, "OpenRPG Update Manager 0.6.9 (open beta)", self.open_rpg, self.manifest, self.main)
+        self.updater = updaterFrame(self, "OpenRPG Update Manager 0.7 (open beta)", self.open_rpg, self.manifest, self.main)
         if self.manifest.GetString("updatemana", "auto_update", "") == 'on' and self.main == False:
             self.AutoUpdate(); self.OnExit()
         else: pass
@@ -504,15 +504,13 @@
             self.filename = orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + filename
             orpg.tools.validate.Validate(orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep).config_file(filename, "default_ignorelist.txt")
             self.mana = self.LoadDoc()
-            for ignore in self.ignorelist: #Checked or not, if it is here, it is ignored.
-                try: shutil.copy(ignore, orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep)
-                except: pass
+            for ignore in self.ignorelist:
+                shutil.copy(ignore, orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep +ignore.split('/')[len(ignore.split('/')) - 1])
             hg.clean(self.repo, self.current)
             for ignore in self.ignorelist:
-                try: shutil.copyfile(orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep + ignore.split('/')[len(ignore.split('/')) - 1], ignore)
-                except: pass
-                try: os.remove(orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep + ignore.split('/')[len(ignore.split('/')) - 1])
-                except: pass
+                print ignore.split('/')[len(ignore.split('/')) - 1]
+                shutil.copyfile(orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep + ignore.split('/')[len(ignore.split('/')) - 1], ignore)
+                os.remove(orpg.dirpath.dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep + ignore.split('/')[len(ignore.split('/')) - 1])
         else: print 'No default repository set, skipping Auto Update!'
 
     def LoadDoc(self):