Mercurial > traipse_dev
comparison orpg/gametree/nodehandlers/core.py @ 159:033887bb8a86 alpha
Traipse Alpha 'OpenRPG' {091126-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 (Keeping up with Beta)
New Features:
Added Bookmarks
Added 'boot' command to remote admin
Added confirmation window for sent nodes
Minor changes to allow for portability to an OpenSUSE linux OS
Miniatures Layer pop up box allows users to turn off Mini labels, from FlexiRPG
Zoom Mouse plugin added
Images added to Plugin UI
Switching to Element Tree
Map efficiency, from FlexiRPG
Added Status Bar to Update Manager
New TrueDebug Class in orpg_log (See documentation for usage)
Portable Mercurial
Tip of the Day added, from Core and community
New Reference Syntax added for custom PC sheets
New Child Reference for gametree
New Gametree Recursion method, mapping, context sensitivity, and effeciency..
New Features node with bonus nodes and Node Referencing help added
Fixes:
Fix to Text based Server
Fix to Remote Admin Commands
Fix to Pretty Print, from Core
Fix to Splitter Nodes not being created
Fix to massive amounts of images loading, from Core
Fix to Map from gametree not showing to all clients
Fix to gametree about menus
Fix to Password Manager check on startup
Fix to PC Sheets from tool nodes. They now use the tabber_panel
Fixed Whiteboard ID to prevent random line or text deleting.
Modified ID's to prevent non updated clients from ruining the fix. *Whiteboard
from Core not showing*
default_manifest.xml renamed to default_upmana.xml
Fix to Update Manager; cleaner clode for saved repositories
author | sirebral |
---|---|
date | Thu, 26 Nov 2009 14:24:19 -0600 |
parents | bf799efe7a8a |
children | 0dde29a41614 |
comparison
equal
deleted
inserted
replaced
157:e564a01d1324 | 159:033887bb8a86 |
---|---|
51 class node_handler: | 51 class node_handler: |
52 """ Base nodehandler with virtual functions and standard implmentations """ | 52 """ Base nodehandler with virtual functions and standard implmentations """ |
53 def __init__(self,xml,tree_node): | 53 def __init__(self,xml,tree_node): |
54 self.xml = xml | 54 self.xml = xml |
55 self.mytree_node = tree_node | 55 self.mytree_node = tree_node |
56 self.tree = open_rpg.get_component('tree') | 56 self.tree = component.get('tree') |
57 self.frame = open_rpg.get_component('frame') | 57 self.frame = component.get('frame') |
58 self.chat = open_rpg.get_component('chat') | 58 self.chat = component.get('chat') |
59 self.drag = True | 59 self.drag = True |
60 self.myeditor = None # designing | 60 self.myeditor = None # designing |
61 self.myviewer = None # prett print | 61 self.myviewer = None # prett print |
62 self.mywindow = None # using | 62 self.mywindow = None # using |
63 # call version hook | 63 # call version hook |
379 </nodehandler> | 379 </nodehandler> |
380 """ | 380 """ |
381 def __init__(self,xml,tree_node): | 381 def __init__(self,xml,tree_node): |
382 node_handler.__init__(self,xml,tree_node) | 382 node_handler.__init__(self,xml,tree_node) |
383 self.file_node = self.xml[0] | 383 self.file_node = self.xml[0] |
384 self.frame = open_rpg.get_component('frame') | 384 self.frame = component.get('frame') |
385 | 385 |
386 def on_ldclick(self,evt): | 386 def on_ldclick(self,evt): |
387 file_name = self.file_node.get("name") | 387 file_name = self.file_node.get("name") |
388 self.tree.insert_xml(open(orpg.dirpath.dir_struct["nodes"] + file_name,"r").read()) | 388 self.tree.insert_xml(open(orpg.dirpath.dir_struct["nodes"] + file_name,"r").read()) |
389 return 1 | 389 return 1 |
411 </nodehandler> | 411 </nodehandler> |
412 """ | 412 """ |
413 def __init__(self,xml,tree_node): | 413 def __init__(self,xml,tree_node): |
414 node_handler.__init__(self,xml,tree_node) | 414 node_handler.__init__(self,xml,tree_node) |
415 self.file_node = self.xml[0] | 415 self.file_node = self.xml[0] |
416 self.frame = open_rpg.get_component('frame') | 416 self.frame = component.get('frame') |
417 | 417 |
418 def on_ldclick(self,evt): | 418 def on_ldclick(self,evt): |
419 file_name = self.file_node.get("url") | 419 file_name = self.file_node.get("url") |
420 file = urllib.urlopen(file_name) | 420 file = urllib.urlopen(file_name) |
421 self.tree.insert_xml(file.read()) | 421 self.tree.insert_xml(file.read()) |
442 """ clones childe node and insert it at top of tree | 442 """ clones childe node and insert it at top of tree |
443 <nodehandler name='?' module='core' class='min_map' /> | 443 <nodehandler name='?' module='core' class='min_map' /> |
444 """ | 444 """ |
445 def __init__(self,xml,tree_node): | 445 def __init__(self,xml,tree_node): |
446 node_handler.__init__(self,xml,tree_node) | 446 node_handler.__init__(self,xml,tree_node) |
447 self.map = open_rpg.get_component('map') | 447 self.map = component.get('map') |
448 self.mapdata = self.xml[0] | 448 self.mapdata = self.xml.find('map') |
449 | 449 |
450 def on_ldclick(self,evt): | 450 def on_ldclick(self,evt): |
451 if (component.get('session').my_role() != component.get('session').ROLE_GM): | |
452 component.get('chat').InfoPost("You must be a GM to use this feature") | |
453 return | |
451 self.map.new_data(tostring(self.mapdata)) | 454 self.map.new_data(tostring(self.mapdata)) |
455 component.get('session').send(tostring(self.mapdata)) | |
456 self.map.canvas.send_map_data() | |
452 return 1 | 457 return 1 |