# HG changeset patch # User sirebral # Date 1272691425 18000 # Node ID cd4ac7e46d3cf571c198ca80d18f2d92e27afc14 # Parent b8091ede042a24fa1aaa1dd5fdc7e758ed6dde3c Traipse Alpha 'OpenRPG' {100501-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. 'Ornery-Orc' continues the trend of 'Grumpy' and adds fixes to the code. 'Ornery-Orc's main goal is to offer more advanced features and enhance the productivity of the user. Update Summary (Patch-2) Moved to Beta!! New Features: New Namespace method with two new syntaxes New Namespace Internal is context sensitive, always! New Namespace External is 'as narrow as you make it' New Namespace FutureCheck helps ensure you don't receive an incorrect node New PluginDB access for URL2Link plugin New to Forms, they now show their content in Design Mode New to Update Manager, checks Repo for updates on software start New to Mini Lin node, change title in design mode New to Game Tree, never lose a node, appends a number to the end of corrupted trees New to Server GUI, Traipse Suite's Debug Console Updates: Update to White Board layer, uses a pencil image for color button Update to Grid Layer, uses a grid image for color button Update to Chat Window, size of drop down menus Update to default lobby message Update to template Text node Fixes: Fix to Server GUI startup errors Fix to Server GUI Rooms tab updating Fix to Chat and Settings if non existant die roller is picked Fix to Dieroller and .open() used with .vs(). Successes are correctly calculated Fix to Alias Lib's Export to Tree, Open, Save features Fix to alias node, now works properly Fix to Splitter node, minor GUI cleanup Fix to Backgrounds not loading through remote loader Fix to Node name errors Fix to rolling dice in chat Whispers Fix to Splitters Sizing issues Fix to URL2Link plugin, modified regex compilation should remove memory leak Fix to mapy.py, a roll back due to zoomed grid issues Fix to whiteboard_handler, Circles work by you clicking the center of the circle Fix to Servers parse_incoming_dom which was outdated and did not respect XML Fix to a broken link in the server welcome message Fix to InterParse and logger requiring traceback Fix to Update Manager Status Bar Fix to failed image and erroneous pop up Fix to Mini Lib node that was preventing use Fix to plugins that parce dice but did not call InterParse Fix to nodes for name changing by double click Fix to Game Tree, node ordering on drag and drop corrected Fix to Game Tree, corrupted error message was not showing Fix to Update Manager, checks for internet connection Fix to Update Manager, Auto Update corrections diff -r b8091ede042a -r cd4ac7e46d3c orpg/chat/chatwnd.py --- a/orpg/chat/chatwnd.py Fri Apr 30 11:37:37 2010 -0500 +++ b/orpg/chat/chatwnd.py Sat May 01 00:23:45 2010 -0500 @@ -502,7 +502,7 @@ wx.WXK_F9: 'event.GetKeyCode() == wx.WXK_F9', wx.WXK_F10: 'event.GetKeyCode() == wx.WXK_F10', wx.WXK_F11: 'event.GetKeyCode() == wx.WXK_F11', wx.WXK_F12: 'event.GetKeyCode() == wx.WXK_F12'} #Alias Lib stuff - self.defaultAliasName = 'Use Real Name' + self.defaultAliasName = 'Real Name' self.defaultFilterName = 'No Filter' self.advancedFilter = False self.lastSend = 0 # this is used to help implement the player typing indicator @@ -827,7 +827,7 @@ def build_alias(self): self.aliasSizer = wx.BoxSizer(wx.HORIZONTAL) - self.aliasList = wx.Choice(self, wx.ID_ANY, size=(100, 25), choices=[self.defaultAliasName]) + self.aliasList = wx.Choice(self, wx.ID_ANY, size=(120, 25), choices=[self.defaultAliasName]) self.aliasButton = createMaskedButton( self, dir_struct["icon"] + 'player.gif', 'Refresh list of aliases from Game Tree', wx.ID_ANY, '#bdbdbd' ) diff -r b8091ede042a -r cd4ac7e46d3c orpg/mapper/grid_handler.py --- a/orpg/mapper/grid_handler.py Fri Apr 30 11:37:37 2010 -0500 +++ b/orpg/mapper/grid_handler.py Sat May 01 00:23:45 2010 -0500 @@ -40,7 +40,10 @@ self.grid_snap = wx.CheckBox(self, wx.ID_ANY, " Snap") self.grid_size = wx.TextCtrl(self, wx.ID_ANY, size=(32,-1) ) self.grid_ratio = wx.TextCtrl(self, wx.ID_ANY, size=(32,-1) ) - self.color_button = wx.Button(self, wx.ID_ANY, "Color", style=wx.BU_EXACTFIT) + #self.color_button = wx.Button(self, wx.ID_ANY, "Color", style=wx.BU_EXACTFIT) + self.color_button = createMaskedButton(self, dir_struct["icon"]+'grid.gif', + 'Grid Color', wx.ID_ANY, '#bdbdbd', + wx.BITMAP_TYPE_GIF) self.apply_button = wx.Button(self, wx.ID_OK, "Apply", style=wx.BU_EXACTFIT) self.color_button.SetBackgroundColour(wx.BLACK) self.color_button.SetForegroundColour(wx.WHITE) diff -r b8091ede042a -r cd4ac7e46d3c orpg/mapper/whiteboard_handler.py --- a/orpg/mapper/whiteboard_handler.py Fri Apr 30 11:37:37 2010 -0500 +++ b/orpg/mapper/whiteboard_handler.py Sat May 01 00:23:45 2010 -0500 @@ -57,14 +57,16 @@ def build_ctrls(self): base_layer_handler.build_ctrls(self) - self.color_button = wx.Button(self, wx.ID_ANY, "Pen Color", style=wx.BU_EXACTFIT) + self.color_button = createMaskedButton(self, dir_struct["icon"]+'draw.gif', + 'Pen Color', wx.ID_ANY, '#bdbdbd', + wx.BITMAP_TYPE_GIF) self.color_button.SetBackgroundColour(wx.BLACK) self.color_button.SetForegroundColour(wx.WHITE) self.drawmode_ctrl = wx.Choice(self, wx.ID_ANY, choices = ["Freeform", "Polyline","Text", "Cone", "Circle"]) self.drawmode_ctrl.SetSelection(0) #always start showing "Freeform" self.radius = wx.TextCtrl(self, wx.ID_ANY, size=(32,-1) ) self.radius.SetValue("15") - self.live_refresh = wx.CheckBox(self, wx.ID_ANY, " Live Refresh") + self.live_refresh = wx.CheckBox(self, wx.ID_ANY, " Dynamic") self.live_refresh.SetValue(True) self.widthList= wx.Choice(self, wx.ID_ANY, size= wx.Size(40, 20), choices=['1','2','3','4','5','6','7','8','9','10']) @@ -78,7 +80,7 @@ self.sizer.Add(self.radius, 0, wx.EXPAND|wx.ALL, 2) self.sizer.Add(wx.Size(10,25)) self.sizer.Add(self.live_refresh, 0, wx.EXPAND) - self.sizer.Add(wx.Size(20,25)) + self.sizer.Add(wx.Size(10,25)) self.sizer.Add(self.color_button, 0, wx.EXPAND) self.sizer.Add(wx.Size(20,25)) self.Bind(wx.EVT_MOTION, self.on_motion) diff -r b8091ede042a -r cd4ac7e46d3c orpg/orpg_version.py --- a/orpg/orpg_version.py Fri Apr 30 11:37:37 2010 -0500 +++ b/orpg/orpg_version.py Sat May 01 00:23:45 2010 -0500 @@ -4,7 +4,7 @@ #BUILD NUMBER FORMAT: "YYMMDD-##" where ## is the incremental daily build index (if needed) DISTRO = "Traipse Alpha" DIS_VER = "Ornery Orc" -BUILD = "100430-01" +BUILD = "100501-00" # This version is for network capability. PROTOCOL_VERSION = "1.2" diff -r b8091ede042a -r cd4ac7e46d3c orpg/templates/default_LobbyMessage.html --- a/orpg/templates/default_LobbyMessage.html Fri Apr 30 11:37:37 2010 -0500 +++ b/orpg/templates/default_LobbyMessage.html Sat May 01 00:23:45 2010 -0500 @@ -1,40 +1,38 @@ - - - - - - - - -
-
-
- - - - - - - -
- Many thanks goes to all of those who contributed! -
- The developers in alphabetical order are: -
- Thomas Baleno, Andrew Bennett, Lex Berezhny, Ted Berg, - Bernhard Bergbauer, Chris Blocher ,Ben Collins-Sussman, Robin Cook, Greg Copeland, - Chris Davis, Michael Edwards, Andrew Ettinger, Dj Gilcrease, Todd Faris, - Christopher Hickman, Paul Hosking, Scott Mackay, Brian Manning, - Jesse McConnell, Brian Osman, Rome Reginelli, Christopher Rouse, Dave Sanders, Mark Tarrabain, - David Byron, David, Vrabel, and Tyler Starke. -
- This product is licensed under the GNU GPL License. -
-
- - + + + + + + + + + +
+ Welcome to an OpenRPG Server +
+ Add a message here. +
+ The OpenRPG Project +
+ Who is this force? +
+ Here is an example Room Message that can be easily modified to fit the needs of your server. + The room message has two rows and two cells. One row is for headers, and one row is for cells. + The main area here can be an introduction, and the side area to the right can contain a game schedule. +

If you have created a Wiki or forums, be sure and put links to those as well.

+
+ Thomas Baleno, Andrew Bennett, Lex Berezhny, Ted Berg, + Bernhard Bergbauer, Chris Blocher, Ben Collins-Sussman, Robin Cook, Greg Copeland, + Chris Davis, Michael Edwards, Andrew Ettinger, Dj Gilcrease, Todd Faris, + Christopher Hickman, Paul Hosking, Scott Mackay, Brian Manning, + Jesse McConnell, Brian Osman, Rome Reginelli, Christopher Rouse, Dave Sanders, Mark Tarrabain, + David Byron, David Vrabel, and Tyler Starke. +

And of course, the Community!

+

Many thanks to all who contributed!

+
+ diff -r b8091ede042a -r cd4ac7e46d3c orpg/templates/feature.xml --- a/orpg/templates/feature.xml Fri Apr 30 11:37:37 2010 -0500 +++ b/orpg/templates/feature.xml Sat May 01 00:23:45 2010 -0500 @@ -1,6 +1,7 @@ - - Welcome to Traipse OpenRPG. + + + Welcome to Traipse OpenRPG. This small user manual should help users learn about the details of OpenRPG that are often times obscure. @@ -17,14 +18,19 @@ Adding to the Manual: Do you see something that could be explained eaiser? Report the problem as a bug and it will be added to the manual. - - The Chat window is a basic HTML Parser. It understands all basic HTML tags including table, td, tr, span, font, to name a few. + + + + The Chat window is a basic HTML Parser. It understands all basic HTML tags including table, td, tr, span, font, to name a few. The chat includes a set of commands. You can learn about the commands by entering /help The chat also has Settings in the Chat menu that allow you see a Chat Time Index, Images, or strip the HTML and see raw text. - - The Tabs: + + + + + The Tabs: The Map is divided into 7 tabs. They are Background, Grid, Miniatures, Whiteboard, Fog, and General. There are 6 layers to the map, one tab for each layer except General. When you select one of the tabs you may access that map layer and it's settings. You may only select tabs based on your role. @@ -56,8 +62,54 @@ Fog: The fog layer hides the entire map from the prying eyes of players. - - Quick Help: + + + + + Persistant users who wanted the stability of Traipse and the ease of Namespace have described to me how they envision Namespace should work. When I heard this I immediately realized that my method provided the aspects users wanted, but not simplicity in design this method would provide. The Traipse Namespace is a little different than Standard but it offers more stability in it's approach + + There are two methods provided with the Traipse Namespace, and these two allow you to a great deal of control when you choose to use Namespace to reference your nodes. + +There is only one difference in how these two methods work, so once you get the hang of Namespace, you will always know how it works. The difference is, External starts looking from the Game Tree and gets more narrow where as Internal starts from the node it is inside and searchs backwards getting more broad. + + + Namespace Internal: +(Syntax) !=Node=! + +Usage: When you use Namespace Internal the software finds the tree map of the node and searches for the top node. Once that node is found it will iterate through the node and look for the reference you have assigned. If it cannot find it in that node, then it will iterate through the map, finding all successive nodes and searching them + + Namespace Internal is completely context sensitive. You can assign a reference using the Namespace Internal method and it will always find the correct PC Sheet to search in. + +Namespace Internal must be used from within a node. + +Namespace External: +(Syntax) !&Top Node::Node&! + +Usage: Namespace External is a different approach to Namespace. With Namespace External you can use the syntax in chat or in other nodes to cross reference nodes. Instead of External being context sensitive, External uses a broadscope that you can narrow down. + + It is really easy to narrow down External. External doesn't work like a string, it works like a lightning bolt. To get a good example open up the 4e PC Sheet node that comes with Traipse and try some different commands in chat. + +<b>1:</b> !&4e PC Sheet::Slot 1&! +<b>2:</b> !&4e PC Sheet::Belt:: Slot 1&! +<b>3:</b> !&4e PC Sheet::Inventory&! +<b>4:</b> !&4e PC Sheet::Inventory::Slot 1&! + + Did you see what happened with the last two? Thankfully there is more than one way to get a node! + +(Create a 4e PC Sheet node from the Templates and press Send ---v to try it) + + + Grids can now be called from by adding a Row, Column to the end of the grid reference. + +Example: !&Abilities::2,2&! + + + Quick Help: + +Designer Note: +=== +For the life span of Ornery Orc the new Child, Parent, Root reference will exist, but in Pious the reference system will not transfer. This is because of the way the new Namespace works. Namespace will become the exclusive referencing system +=== The referencing system is an update to the Core of how the Game Tree works. In it's current state I understand the syntax is difficult to pick up. Here are some tips to help you grasp the syntax further @@ -114,86 +166,69 @@ In the OpenRPG Core model your Game Tree has a lot more freedom, but only if you grant it, which I always felt was a design flaw. Comparably, with Traipse you can access any data on the Game Tree, no matter where the location. This freedom will help with future design and I feel it also frees up the hands of the GM who does not need to Index, un-Index, Namespace, un-Namspace the various creatures he or she may have in a Game Tree. - - <b>Root Reference</b> + + + <b>Root Reference</b> Works at the tree level. Must be exact. <b>Root Reference 1:</b> !@Reference Examples::Group::Child@! -<b>Root Reference 2:</b> !@Reference Examples::Grid::(2,1)@! - - <b>Grid Reference</b> +<b>Root Reference 2:</b> !@Reference Examples::Grid::2,1@! + + + <b>Grid Reference</b> Works by looking at the (Row, Column) of a Grid. -<b>Grid Reference 1:</b> !@Reference Examples::Grid::(1,1)@! -<b>Grid Reference 2:</b> !!Grid::(1,1)!! - - <b>Child Reference</b> +<b>Grid Reference 1:</b> !@Reference Examples::Grid::1,1@! +<b>Grid Reference 2:</b> !!Grid::1,1!! + + + <b>Child Reference</b> Works at the current tree location. <b>Child Reference 1:</b> !!Group::Child!! <b>Child Reference 2:</b> !!Group::Group_2::Child_2!! - - <b>Parent Reference</b> + + + <b>Parent Reference</b> Works by indexing the tree map of the node with the Reference. Allows you to start from a 'Parent'. <b>Parent Reference 1:</b> !!Group::Group_2::Child_2!! <b>Parent Reference 2:</b> !#Bonus Nodes::Deck::Draw#! - - - - !#Group::Child#! - - - !#Group::Child#! - - Child Node Data - - - - 0 - 0 - - - !!Group::Child!! - 0 - - - - - - With the new additions to the Game Tree using nodes has never been easier nor has it ever been more fluid. Included here is a list of the additions to the Game Tree referencing model as well as some tips on how to make the Game Tree work the way it was intended. - -Grid Nodes: - Grid nodes are now reference-able with the coordinates of the grid. Example: !@Grid::(1,1)@! -The example will return the top left most cell data. The grid understands coordinates like this (Row, Column) - - Grid nodes can reference node data just like any other node can. With a new added feature grids are even more useful. By using a new die rolling syntax you can draw just the number of the modified roll. While this will not pass during game play, you can use it with the grid node to create a random chart. The new die roll syntax is [#XdY]. # works just like q, yet it returns only the modified die result. - - Here is an example with a 3 x 3 Grid -Example: !@Grid::([#1d3], [#1d3])@! - -The result will be a random event from the grid. - -Bonus Node Included: A 52 Card Deck with 4 columns and 13 rows. (4 * 13 = 52) - -List Nodes: - List nodes now have a check box that allows users to send the content as a macro. List nodes are a prime reference holder because users can place a lot of references into one small node. - - For the best results from a list node my tip to users would be to create a list node and place it next to the character sheet they are using, inside a the PC Sheet. The list will then use the Child Referencing syntax, but the PC Sheet can go anywhere in the tree and the player will have easy access to all the references. - -(List Nodes inside a Tool created PC sheet vanish when moved, or I would recommend the list be placed inside these sheets also.) - - Here is an example of a Fortitude save inside the recommended list node: !!Fort::Check!! - -Text Nodes: - Text nodes remain little changed. I agree with all the 1.7.1 users who tell me, if it's not broke don't fix it. With that in mind I have some good tips for text nodes. - - Text nodes can be used in conjunction with the new grid features to create random encounters. A GM could place a list of text nodes into a folder and the grid could reference the nodes. - - Text nodes also work great when you need to have story text at hand that you don't want to type out during play. Create chapters with folder nodes and add the adventure text to different nodes. You can then use a List Node or a Grid Node to reference the different chapters. - -Bonus Node Included: A small book node with 1 Chapter and 3 Parts. Traipse node referencing is unlike other distributions of OpenRPG. The Game Tree mapping is a fluid map that changes with the location of your nodes. This allows you to create a reference node that will stay with your character sheet, and if you change the location of your character sheet the reference will still work. + + + + + !#Group::Child#! + + + + !#Group::Child#! + + + + + Child Node Data + + + + + + 0 + 0 + + + !!Group::Child!! + 0 + + + + + + + + + Traipse node referencing is unlike other distributions of OpenRPG. The Game Tree mapping is a fluid map that changes with the location of your nodes. This allows you to create a reference node that will stay with your character sheet, and if you change the location of your character sheet the reference will still work. (Note: Renaming your node causes problems with the tree mapping until you restart the software. You can just move the node and the software will reset the Game Tree map) @@ -245,8 +280,46 @@ Examples: !@Kammen-Pai::Cast::Ray of Frost@! -!@Kammen-Pai::Feat::Ability Focus@! - In Traipse starting a server has never been easier. The setup is as easy as 1., 2., 3 +!@Kammen-Pai::Feat::Ability Focus@! + + + With the new additions to the Game Tree using nodes has never been easier nor has it ever been more fluid. Included here is a list of the additions to the Game Tree referencing model as well as some tips on how to make the Game Tree work the way it was intended. + +Grid Nodes: + Grid nodes are now reference-able with the coordinates of the grid. Example: !@Grid::(1,1)@! +The example will return the top left most cell data. The grid understands coordinates like this (Row, Column) + + Grid nodes can reference node data just like any other node can. With a new added feature grids are even more useful. By using a new die rolling syntax you can draw just the number of the modified roll. While this will not pass during game play, you can use it with the grid node to create a random chart. The new die roll syntax is [#XdY]. # works just like q, yet it returns only the modified die result. + + Here is an example with a 3 x 3 Grid +Example: !@Grid::([#1d3], [#1d3])@! + +The result will be a random event from the grid. + +Bonus Node Included: A 52 Card Deck with 4 columns and 13 rows. (4 * 13 = 52) + +List Nodes: + List nodes now have a check box that allows users to send the content as a macro. List nodes are a prime reference holder because users can place a lot of references into one small node. + + For the best results from a list node my tip to users would be to create a list node and place it next to the character sheet they are using, inside a the PC Sheet. The list will then use the Child Referencing syntax, but the PC Sheet can go anywhere in the tree and the player will have easy access to all the references. + +(List Nodes inside a Tool created PC sheet vanish when moved, or I would recommend the list be placed inside these sheets also.) + + Here is an example of a Fortitude save inside the recommended list node: !!Fort::Check!! + +Text Nodes: + Text nodes remain little changed. I agree with all the 1.7.1 users who tell me, if it's not broke don't fix it. With that in mind I have some good tips for text nodes. + + Text nodes can be used in conjunction with the new grid features to create random encounters. A GM could place a list of text nodes into a folder and the grid could reference the nodes. + + Text nodes also work great when you need to have story text at hand that you don't want to type out during play. Create chapters with folder nodes and add the adventure text to different nodes. You can then use a List Node or a Grid Node to reference the different chapters. + +Bonus Node Included: A small book node with 1 Chapter and 3 Parts. + + + + + In Traipse starting a server has never been easier. The setup is as easy as 1., 2., 3 1. You will need to first start the Server GUI or the basic text based Server at least once so your software creates the server_ini.xml files in your myfiles directory. You can start it once and quit. @@ -257,174 +330,282 @@ 3. This is the hardest step. You need to make sure your selected port is forwarded by your router and open to your firewall. That's it! You can now start the server and register it to the meta for all users to enjoy! - - - - - - - - - - - - - - - - <br /> + + + + + + + + + + + + + + + + + + + + + + + <br /> <b>Chapter 1 Part 1</b> <br /><br /> An introduction to your adventure module can be placed here. - - <br /> + + + <br /> <b>Chapter 1 Part 2</b> <br /><br /> The adventurers have come this far. - - <br /> + + + <br /> <b>Chapter 1 Part 3</b> <br /><br /> Is this the end already? - - - - - AS - AD - ACAH - - KS - KD - KCKH - QSQDQCQHJSJDJCJH10S10D10C10H9S9D9C9H8S8D8C8H7S7D7C7H6S6D6C6H5S5D5C5H4S4D4C4H3S3D3C3H2S2D2C2H - - - - - !!52 Card Deck::([#1d13], [#1d4])!! - - - - - - - - - - !!Set 1::Enc 1!! - !!Set 2::Enc 1!! - - !!Set 1::Enc 2!! - !!Set 2::Enc 2!! - !!Set 1::Enc 3!! - - - - - - Hoot Hoot. It's an owl. - - Set 2 Random Encounter. - - - Dark Elves. Watch out! - - Kobolds a plenty. - - A Wandering Minotaur - - - - - - - - - - - + + + + + + + + AS + AD + AC + AH + + + KS + KD + KC + KH + + + QS + QD + QC + QH + + + JS + JD + JC + JH + + + 10S + 10D + 10C + 10H + + + 9S + 9D + 9C + 9H + + + 8S + 8D + 8C + 8H + + + 7S + 7D + 7C + 7H + + + 6S + 6D + 6C + 6H + + + 5S + 5D + 5C + 5H + + + 4S + 4D + 4C + 4H + + + 3S + 3D + 3C + 3H + + + 2S + 2D + 2C + 2H + + + + + + + + !=52 Card Deck::([#1d13], [#1d4])=! + + + + + + + + + + + + + !=Set 1::Enc 1=! + !=Set 2::Enc 1=! + + + !=Set 1::Enc 2=! + !=Set 2::Enc 2=! + + + !=Set 1::Enc 3=! + + + + + + + + + + Hoot Hoot. It's an owl. + + + Set 2 Random Encounter. + + + + + Dark Elves. Watch out! + + + Kobolds a plenty. + + + A Wandering Minotaur + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - + + + - - - - - - - - - - - - - - - + + - - - - + + - - - - - + + - - + + - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file + + + + + + + + + \ No newline at end of file diff -r b8091ede042a -r cd4ac7e46d3c orpg/templates/nodes/textctrl.xml --- a/orpg/templates/nodes/textctrl.xml Fri Apr 30 11:37:37 2010 -0500 +++ b/orpg/templates/nodes/textctrl.xml Sat May 01 00:23:45 2010 -0500 @@ -1,1 +1,1 @@ -Text \ No newline at end of file +Text \ No newline at end of file diff -r b8091ede042a -r cd4ac7e46d3c upmana/updatemana.py --- a/upmana/updatemana.py Fri Apr 30 11:37:37 2010 -0500 +++ b/upmana/updatemana.py Sat May 01 00:23:45 2010 -0500 @@ -83,26 +83,34 @@ self.Bind(wx.EVT_TIMER, self.OnTimer, self.timer) def OnTimer(self, event): + statbar.SetStatusText('Checking For Updates') self.count = self.count + 1 self.buttons['progress_bar'].SetValue(self.count) if self.count == 100: self.timer.Stop() - statbar.SetStatusText('Checking For Updates') + statbar.SetStatusText('No Updates Available') def UpdateCheck(self): self.timer.Start(100) self.count = 3 self.buttons['progress_bar'].SetValue(3) - doUpdate = commands.incoming(self.ui, self.repo, - manifest.GetString('default', 'repo', ''), force=True, bundle=False) - if doUpdate: - statbar.SetStatusText('No Updates Available') + try: + doUpdate = commands.incoming(self.ui, self.repo, + manifest.GetString('default', 'repo', ''), + force=True, bundle=False) + if doUpdate: + statbar.SetStatusText('No Updates Available') + self.buttons['progress_bar'].SetValue(100) + self.timer.Stop() + else: + statbar.SetStatusText('Refresh Repo For Updated Source') + self.buttons['progress_bar'].SetValue(100) + self.timer.Stop() + except: + statbar.SetStatusText('No Connection Found') self.buttons['progress_bar'].SetValue(100) self.timer.Stop() - else: - statbar.SetStatusText('Refresh Repo For Updated Source') - self.buttons['progress_bar'].SetValue(100) - self.timer.Stop() + def ToggleAutoUpdate(self, event): if self.buttons['auto_check'].GetValue() == True: @@ -149,11 +157,11 @@ os.removedirs(temp+dir1) def LoadDoc(self): - ignore = open(self.filename) + manifest = open(self.filename) self.ignorelist = [] - for i in ignore: self.ignorelist.append(str(i [:len(i)-1])) - manifest = ignore.readlines() - ignore.close() + ignore = manifest.readlines() + for i in ignore: print i; self.ignorelist.append(str(i[:len(i)-1])) + manifest.close() def Finish(self, evt=None): component.get('upmana-win').OnClose(None) @@ -611,11 +619,11 @@ dlg.Destroy(); pass def LoadDoc(self): - ignore = open(self.filename) + manifest = open(self.filename) self.ignorelist = [] - for i in ignore: self.ignorelist.append(str(i [:len(i)-1])) - manifest = ignore.readlines() - ignore.close() + ignore = manifest.readlines() + for i in ignore: print i; self.ignorelist.append(str(i[:len(i)-1])) + manifest.close() def get_packages(self, type=None): #Can be cleaner @@ -747,24 +755,24 @@ class updateApp(wx.App): def OnInit(self): - self.main = False - + self.main = False; self.autoUpdate = False; self.noUpdate = False logger._set_log_to_console(False) logger.note("Updater Start") component.add('validate', validate) self.updater = updaterFrame(self, "OpenRPG Update Manager 1.2", component, manifest, self.main) if manifest.GetString("updatemana", "auto_update", "") == 'on' and self.main == False: - self.AutoUpdate(); self.OnExit() + self.AutoUpdate(); self.OnExit(); self.autoUpdate = True else: pass if manifest.GetString('updatemana', 'no_update', '') == 'on' and self.main == False: - self.OnExit() + self.OnExit(); self.noUpdate = True else: pass - try: - self.updater.Show() - self.updater.Fit() - except: pass - if not self.main: self.updater.page1.UpdateCheck() + if not (self.autoUpdate or self.noUpdate): + try: + self.updater.Show() + self.updater.Fit() + if not self.main: self.updater.page1.UpdateCheck() + except: pass return True def AutoUpdate(self): @@ -773,13 +781,16 @@ self.c = self.repo.changectx('tip') self.current = self.repo.dirstate.branch() - capture = manifest.GetString('updaterepo', 'default', '') + capture = manifest.GetString('default', 'repo', '') if capture != '': - commands.pull(self.ui, self.repo, capture, rev='', update=False, force=True) + try: commands.pull(self.ui, self.repo, capture, rev='', update=False, force=True) + except: + wx.MessageBox('No Connection Found. Skipping Auto Update!', 'Info') + return filename = 'ignorelist.txt' self.filename = dir_struct["home"] + 'upmana' + os.sep + filename component.get('validate').config_file(filename, "default_ignorelist.txt") - self.mana = self.LoadDoc() + self.mana = self.LoadDoc(); ignored = [] temp = dir_struct["home"] + 'upmana' + os.sep + 'tmp' + os.sep for ignore in self.ignorelist: if len(ignore.split('/')) > 1: @@ -788,25 +799,27 @@ dir1 += ignore.split('/')[gets] + os.sep gets += 1 os.makedirs(temp+dir1) - shutil.copy(ignore, temp + dir1 + ignore.split('/')[len(ignore.split('/')) - 1]) + ignoredfile = temp + dir1 + ignore.split('/')[len(ignore.split('/')) - 1] + ignored.append(ignoredfile) + shutil.copy(ignore, ignoredfile) hg.clean(self.repo, self.current) for ignore in self.ignorelist: - shutil.copyfile(temp + ignore.split('/')[len(ignore.split('/')) - 1], ignore) - os.remove(temp + ignore.split('/')[len(ignore.split('/')) - 1]) + shutil.copyfile(ignored.index(ignore), ignore) + os.remove(ignored.index(ignore)) if len(ignore.split('/')) > 1: gets = 0; dir1 = '' while gets != len(ignore.split('/'))-1: dir1 += ignore.split('/')[gets] + os.sep gets += 1 os.removedirs(temp+dir1) - else: wx.MessageBox('No default Rpository set. Skipping Auto Update!', 'Info') + else: wx.MessageBox('Default Repo Not Found. Skipping Auto Update!', 'Info') def LoadDoc(self): - ignore = open(self.filename) + manifest = open(self.filename) self.ignorelist = [] - for i in ignore: self.ignorelist.append(str(i [:len(i)-1])) - manifest = ignore.readlines() - ignore.close() + ignore = manifest.readlines() + for i in ignore: print i; self.ignorelist.append(str(i[:len(i)-1])) + manifest.close() def OnExit(self): imported = ['manifest', 'orpg.dirpath', 'orpg.orpgCore', 'orpg.orpg_version',