yongedevil Posted June 14, 2015 Share Posted June 14, 2015 (edited) YongeTech Tech Trees Pluginversion: 1.3last tested with Kerbal v1.0.4Kerbal Stuff LinkSource on GitHubAbout the ModThe Tech Trees Plugin provides support to make creating and using custom tech trees easier.Allows part unlocks to be listed in the TechTree ConfigNode rather than having to edit every Part ConfigNode.Adds support for using custom textures to create icons for the tech tree.Adds a tree selection window to let the player select a tree for each new game.InstallationCopy the contents of GameData into the Kerbal GameData folder.Known IssuesThis mod tracks parts by their name field. This means it does not work properly when multiple parts have the same name.Both this mod and ModuleManager (on version 2.6.5 as of this writing) attempt to edit the tech tree of the current game. This mod's changes should have priority.If you would like to disable the option to select a tech tree and the conflict with ModuleManager change the "allowTreeSelection" field in PluginData/YongeTech_TechTreesExpansion/config.xml from '1' to '0'. This will keep support for the TechTree ConfigNode additions and custom icon support, but remove the option to select a tech tree.Tech TreesYongeTech: Great Big Sky – Wide and shallow tech tree. Feel free to use as an example on how to setup a tech tree with this mod.Using a Tech TreeWhen starting a new Science or Career game a window will appear asking you to select a tech tree to use. Pick a tree from the drop-down list and below it will show the description and some stats for that tree.Total Cost and Total Nodes are the total cost to researcher all nodes on the tree and the total number of nodes in the tree. These numbers exclude hidden nodes. The tiers for the nodes are those nodes that can be researched at that tier of the Research and Development facility.Creating a Tech TreeCreate a new TechTree ConfigNode and place in your mod. This mod will locate and add any TechTree ConfigNodes to the list automatically.The TechTree should be setup like normal with some additions shown in the code below:TechTree{ title = Sample TechTree description = An incomplete TechTree showing the basic setup unlockAllStartParts = True RDNode { ... Unlocks { part = solidBooster_sm part = probeStackAdapter part = standardNoseCone part = sensorThermometer part = basicFin } } ...}TechTree ConfigNode:title: The name of the tree. Displayed in the tech tree selection window when starting a new game. (approximately a 45 character limit)description - Single paragraph description of the tree for the player. Displayed in the tech tree selection window when starting a new game. (approximately a 400 character limit)unlockAllStartParts: (optional) If set to True the mod will unlock all parts attached to the starting node(s), that is all RDNodes with an entryCost of 0. This is only relevant if No Entry Purchase Required on Research is disabled in difficulty settings.Unlocks ConfigNode:part: name of a part to unlock with the parent RDNode.Custom Icon TexturesThe mod will create icons for use in a tech tree from any png or tga files it finds in folders named “RDSimpleIconsâ€Â. The icons will have the same name as the image file, without the extension. .../RDSimpleIcons/customIcon_tech.png will become "icon = customIcon_tech"Tech Tree ConverterThe YongeTech Tech Tree Converter helps convert existing tech trees by filling in the Unlocks nodes for all techs. It will add all parts that:Have a TechRequired of that node.Are not listed in another tech node's Unlock section.It writes the filled out TechTree to a txt file in the mod's directory. It performs this conversion for all TechTrees installed, and it also dose not name the output files in any meaningful way. It is necessary to inspect the output files to locate the correct tree and then add the title and description fields to it.LicencePermission is hereby granted, free of charge, to any person obtaining a copyof this software and associated documentation files (the "Software"), to dealin the Software without restriction, including without limitation the rightsto use, copy, modify, merge, publish, distribute, sublicense, and/or sellcopies of the Software, and to permit persons to whom the Software isfurnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included inall copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS ORIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THEAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHERLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS INTHE SOFTWARE. Edited July 2, 2015 by yongedevil updated to v1.3 Link to comment Share on other sites More sharing options...
cvod Posted June 14, 2015 Share Posted June 14, 2015 Looks great. Only question, how does this aid in creating tech trees? Is it just by supporting a simpler file format? Link to comment Share on other sites More sharing options...
yongedevil Posted June 14, 2015 Author Share Posted June 14, 2015 Yes, the main intent for the mod is to avoid having to setup edits for each individual PART node. As an added benefit though, with the part unlocks stored in with the TechTree it is easy to have multiple trees installed and pick one to be active. Link to comment Share on other sites More sharing options...
cvod Posted June 14, 2015 Share Posted June 14, 2015 Originally I wasnt sure what good changing the format would be, but that's a really good idea. Link to comment Share on other sites More sharing options...
Probus Posted June 14, 2015 Share Posted June 14, 2015 Sounds like a good idea. I will give it a try and give you some feedback.Thanks for doing this. Link to comment Share on other sites More sharing options...
Mulbin Posted June 14, 2015 Share Posted June 14, 2015 Hah... I wish this was available last month before I laid out my module manager file!! Great mod! Link to comment Share on other sites More sharing options...
yongedevil Posted June 16, 2015 Author Share Posted June 16, 2015 I made a small update to the mod (v1.1) to fix undoing other mod's changes to the TechRequired field. This was causing a problem with the unlocks for additional features in MechJeb.I don't have much else planned for this mod now, but I have a short list of features that should be possible. I can look at adding the following if there is demand for them:Option to link a texture to the tech tree for the selection window. This would give the player a visual cue to remember each tree. This could be a small logo, or a link to open a larger image such as a preview of the tech tree.Option to move all parts that are, by default, unlocked by one tech to another. This would allow creating tech trees without worrying about mod parts getting lost in the missing techs.Tech tree debug tools. This would be an option to enable debug messages for a tech tree and could check for some problems such as:Missing default tech nodes, which can cause parts added to those node by mods to not show up unless the parts are specifically reassigned.Parts whose TechRequired doesn’t exist in the tree. Basically the above problem but only checks installed parts.Unknown part values in the Unlocks. These can be legitimate if you add support for mod parts not currently installed, but they could also be typos.Duplicate part values in the Unlocks.And I am sorry I wasn't able to get the mod out sooner. I put this aside due to the ModuleManager conflict for about a month (28 days according to commit logs) because it seamed it might be a dead end. Normally I don't have a problem with being incompatible with another mod that does the same thing (both this mod and ModuleManager edit the TechTree for saved games), but ModuleManager dose too many other very useful things to ask people to uninstall for this mod. In the end though, the workaround was one of those simple solutions that make you feel like an idiot for not seeing sooner. Link to comment Share on other sites More sharing options...
Wolf Baginski Posted June 21, 2015 Share Posted June 21, 2015 One small UI tweak would be good. There's nothing on that start-screen to indicate there's a drop-down menu to list the available tech trees, nothing to show that there is an alternative available.I don't think I see this every time, but the same symbol as used on a Windows scroll-bar is common. That's in Unicode, at U+25BC and called the Black Down-Pointing Triangle. â–¼ The first time I tried the plug-in I did wonder if the other tech tree had been installed properly. Link to comment Share on other sites More sharing options...
yongedevil Posted June 23, 2015 Author Share Posted June 23, 2015 (edited) Updated to v1.2 with an arrow for the dropdown button. Thank you Wolf Baginski.Also made sure the stock tree will always be first in the list.EDIT (2015-06-24): Updated to v1.2.1 to fix and error where the plugin crashed if given two parts with the same name. It still won't handle the parts correctly, but it won't crash. Edited June 24, 2015 by yongedevil update to v1.2.1 Link to comment Share on other sites More sharing options...
micha030201 Posted June 30, 2015 Share Posted June 30, 2015 Feature suggestion: automatic node positioning depending on parent nodes. Link to comment Share on other sites More sharing options...
Wolf Baginski Posted July 1, 2015 Share Posted July 1, 2015 I'm working on YongeTech versions of the Stock tree (more as a reference source) and the Community Tech Tree.Thread here: http://forum.kerbalspaceprogram.com/threads/127408-Using-the-YongeTech-tech-tree-plug-inSince most Tech Trees seem to contain the Stock Tree and add to it, having a full YongeTech version of the stock tree seems useful as a resource, even with YongeTech able to use the stock tree.I have some testing yet to do, before I release test versions. Link to comment Share on other sites More sharing options...
yongedevil Posted July 2, 2015 Author Share Posted July 2, 2015 Feature suggestion: automatic node positioning depending on parent nodes.I'm sorry, but I think it is too complex a problem for me. However, if anyone knows of any simple solutions I can take a look at it.I'm working on YongeTech versions of the Stock tree (more as a reference source) and the Community Tech Tree.That seams like a very good idea and it got me thinking that it would be handy to have the game print out a list of parts attached to a tech node, which led to the realization that it should be quite simple to just have the game print out a complete TechTree node and fill in the Unlocks node with parts automatically. Basically it could convert from the Stock or a ModuleManager tree into a YongeTech tree.If this is as easy as I think it is I will have something rudimentary tomorrow (out tonight, holiday). And apologies to you Wolf Baginski since it sounds like you've done a lot of this work already. Link to comment Share on other sites More sharing options...
micha030201 Posted July 2, 2015 Share Posted July 2, 2015 I'm sorry, but I think it is too complex a problem for me. However, if anyone knows of any simple solutions I can take a look at it.Maybe simpler positioning then? For Tech Tree creator to specify column and row, not absolute position. Link to comment Share on other sites More sharing options...
yongedevil Posted July 2, 2015 Author Share Posted July 2, 2015 First, a updated to v1.3. This adds support for .dds icon textures.Second, the Tech Tree Converter is working. This will fill out the Unlocks node for any installed tech trees by adding all parts that:Have a TechRequired of that node.Are not listed in another tech node's Unlock section.The output is written to files inside the ConvertedTrees directory.To use install the tech tree you wish to convert and start Kerbal. The Tech Trees Plugin does not have to be installed for this. Once the main menu loads you can quit and look inside ConvertedTrees for the output. Find the tree you were trying to convert, sorry about not giving them meaningful names. You will have to add the "title" and "description" fields and renamed the file to .cfg.This is obviously limited to converting one tree at a time, and it is not the fastest process in the world. I suggest removing the plugin when done with it, or at least setting the "enable" field in the config.xml file to 0. Link to comment Share on other sites More sharing options...
yongedevil Posted July 3, 2015 Author Share Posted July 3, 2015 Maybe simpler positioning then? For Tech Tree creator to specify column and row, not absolute position.That certainly qualifies a simple solution.I've done some experiments to see how nodes can be moved around and it looks like it might not be possible to do so without editing the file. Having the game edit the .cfg files is not the best practice. Another option is a separate program to do the coordinate conversions, which honestly isn't really worth the effort for such a simple task. However, it wouldn't take much effort to add such a feature to the Converter. It wouldn't be the most user friendly solution but the plugin already exists to assist in creating TechTrees.Would that still be useful enough to be of interest? You would have to launch Kerbal to generate the output file with the converted positions before releasing the tech tree. Link to comment Share on other sites More sharing options...
micha030201 Posted July 4, 2015 Share Posted July 4, 2015 Would that still be useful enough to be of interest? You would have to launch Kerbal to generate the output file with the converted positions before releasing the tech tree.I think yes. You still need to launch KSP before releasing the TechTree, just to check. Link to comment Share on other sites More sharing options...
Merill Posted August 26, 2015 Share Posted August 26, 2015 OhhIt seem to be a useful mod (so much better syntax than stock). I wish this existed months ago..I have a feature request: - to be able to define multiple tree (with unique id) and be able to assign one (other than the default) at a savegame (via a ScenarioModule field, for example)Use-case: to create scenario with dedicated small tech tree, in the same game installation than normal games (i don"t want to force people to clone their ksp for each scenario i make).(When/if i have time, i may look into it to add this feature, it shouldn't be too hard) Link to comment Share on other sites More sharing options...
Probus Posted January 30, 2016 Share Posted January 30, 2016 (edited) @yongedevilThis is awesome, awesome, awesome! Especially when used with the "Kerbal Mod Admin" mod. I've been doing everything in Notepad++. Needless to say it was taking forever. Any chance we could get a recompile to 1.0.5? Edited January 30, 2016 by Probus I forgot to say please :) Link to comment Share on other sites More sharing options...
linuxgurugamer Posted July 3, 2017 Share Posted July 3, 2017 I've recompiled this for 1.3, available here (for now): https://www.dropbox.com/s/4spej1uy367xayn/RecompiledFor1.3.zip?dl=0 Since @yongedevil hasn't been around since February, I'll consider adopting this in a little while. for this, this is a recompile only, no testing done. Link to comment Share on other sites More sharing options...
Kermanzooming Posted May 13, 2018 Share Posted May 13, 2018 Hey @linuxgurugamer, would you consider doing a recompile for 1.4 for this tool? That would be incredibly helpful for @Probus so he hasn't to start from scratch for Engineering Tech Tree. I would love to do it myself but I'm completely lost on even how to start... Link to comment Share on other sites More sharing options...
linuxgurugamer Posted May 13, 2018 Share Posted May 13, 2018 Already been done Link to comment Share on other sites More sharing options...
Kermanzooming Posted May 16, 2018 Share Posted May 16, 2018 On 5/13/2018 at 10:50 PM, linuxgurugamer said: Already been done You are completely right, I missed the new thread. Posting here the URL for those like me that were not aware of it: Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now