wowgetoffyourcellphone Posted February 22, 2018 Report Share Posted February 22, 2018 (edited) Good job on the entity viewer @s0600204! Here are a few things I've come across after its implementation: 1. Error when trying to view a paired tech: ERROR: JavaScript error: globalscripts/Templates.js line 539 TypeError: templateName.split is not a function removeFiltersFromTemplateName@globalscripts/Templates.js:539:9 init@gui/reference/viewer/viewer.js:66:21 showTemplateDetails@gui/session/selection_panels.js:1181:1 g_SelectionPanels.Research.setupButton/button.onPressRight@gui/session/selection_panels.js:804:5 ERROR: GUI page 'page_viewer.xml': Failed to call init() function There is no error when right-clicking erstwhile paired techs in the Struct Tree, only while in-game from the UI . 2. I think right-clicking an 'Upgrade' option, as for the Defense Tower upgrade for Sentry Towers [Stone Towers from Wooden Towers in DE], the viewer should load the information for the upgrade entity, not the source entity. You probably agree. 3. Bug: After 'Upgrading' a unit or building, right-clicking that new unit or building loads the original unit or building's information, not the new information for the Upgraded entity. So, for instance, if I upgrade a tower from Wooden to Stone, right-clicking the new Stone Tower's portrait gives me the viewer panel of the Wooden Tower, not the new Stone Tower and all the stats are for the Wooden Tower. Again though, it's great to see the viewer finally in the game. It'll help a lot of players. Plus, when all the History information is added back in people will enjoy reading about the items in the game. I would suggest a few extended features for the viewer, but I think items 1-3 above suffice for now. Edited February 22, 2018 by wowgetoffyourcellphone 3 Quote Link to comment Share on other sites More sharing options...
s0600204 Posted February 22, 2018 Report Share Posted February 22, 2018 1 - Fixed 2 - Unable to duplicate (or I'm misunderstanding you). 3 - Unable to duplicate. (In vanilla 0AD) Building a "Sentry Tower", upgrading it to "Defence Tower", then right-clicking the big entity icon: Template Viewer appears displaying stats of the "Defence Tower". 2 1 Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted February 25, 2018 Author Report Share Posted February 25, 2018 On 2/22/2018 at 3:31 PM, s0600204 said: 2 - Unable to duplicate (or I'm misunderstanding you). 3 - Unable to duplicate. (In vanilla 0AD) Building a "Sentry Tower", upgrading it to "Defence Tower", then right-clicking the big entity icon: Template Viewer appears displaying stats of the "Defence Tower". 2 and 3 seem to be the same issue just manifesting in different ways. I have found out what is happening. If the 'Upgraded' entity inherits from the original entity, then the Viewer only gets the information from the original entity--it doesn't see the upgrade entity as a new entity. If the 'Upgrade' entity parent is a new parent [template_structure_xxx] then the viewer updates the information accordingly. hmm. Can test this in DE by viewing the upgrade units for the Maiden Archer. The Maiden Fire Archer's parent is the Maiden Archer, and thus the viewer does not display the new information. The Maiden Swordsman's parent is a new base template [swordsman instead of archer], and thus the viewer displays the Maiden Swordsman correctly. Quote Link to comment Share on other sites More sharing options...
s0600204 Posted March 1, 2018 Report Share Posted March 1, 2018 Got it. Try it now. 3 Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted March 2, 2018 Author Report Share Posted March 2, 2018 6 hours ago, s0600204 said: Got it. Try it now. Works. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.