-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
32 changed files
with
151 additions
and
513 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,56 +1,20 @@ | ||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<ModMetaData> | ||
<name>Research Tree</name> | ||
<author>Fluffy</author> | ||
<url>https://ludeon.com/forums/index.php?topic=16120</url> | ||
<targetVersion>0.19.1996</targetVersion> | ||
<description>A better research tree. | ||
|
||
<size=24>Features</size> | ||
|
||
automatically generated to maximize readability*. | ||
shows research projects, buildings, plants and recipes unlocked by each research project. | ||
projects can be queued, and colonists will automatically start the next project when the current research project completes. | ||
search functionality to quickly find research projects. | ||
|
||
<size=24>FAQ</size> | ||
<i>Can I add/remove this from an existing save?</i> | ||
You can add it to existing saves without problems. Removing this mod will lead to some errors when loading, but these should not affect gameplay - and will go away after saving. | ||
|
||
<i>Why is research X in position Y?</i> | ||
Honestly, I have no idea. The placement of projects (nodes) is automated to minimize the number of crossings between dependancies (edges), and reduce the total length of these edges. There are many possible scenarios in which this can lead to placements that may appear non-optimal. Sometimes they really are non-optimal, sometimes they just appear to be so. See also the <i>technical</i> section below for more information. | ||
|
||
<i>Can I use this with mod X</i> | ||
Most likely, yes. Added researches and their requirements are automatically parsed and the tree layout will be updated accordingly. ResearchPal implements a lot of the same functionality as this mod, and the research queue will likely not work correctly if both mods are loaded. | ||
|
||
<i>This looks very similar to ResearchPal</i> | ||
Yep. ResearchPal is based on a legacy version of this mod that was kept up-to-date by SkyArkAngel in the HCSK modpack. I haven’t worked on this mod in a long time, but I recently had some spare time and decided to give it another go. Feel free to use whichever you like better (ResearchPal has an entirely different layout algorithm). You can run both mods side by side to check out the different tree layouts, but be aware that the research queue will not work correctly if both mods are loaded. | ||
|
||
<size=24>Known Issues</size> | ||
|
||
The vertical labels for tech levels are drawn in the wrong location when UI scale is not 1. This is a known problem for me, the same issue appears in my Work Tab mod. As soon as I have a working solution, I’ll go and fix it. | ||
Layouts are not perfect, if you have experience with graph layouts - please do feel free to look at the source code, and/or implement a Sugiyama layout algorithm for me that runs in C# .NET 3.5 (Mono 2.0). | ||
|
||
<size=24>Technical</size> | ||
So how does this all work? | ||
|
||
Creating an optimal layout is a known problem in the area of <i>Graph Theory</i>. There’s serious mathematicians who’ve spent years of their live trying to figure out this problem, and numerous solutions exist. The group of solutions most relevant to our research tree (a <i>directed acyclic graph</i>, or <i>DAG</i>) is that derived from Sugiyama’s work. Generally speaking, these algorithms have four steps; | ||
|
||
|
||
layering (set the <i>x</i> coordinates of nodes, enforcing that follow-up research is always at a higher x position than any of its prerequisites, this is a fairly straightforward heuristic) | ||
crossing reduction (set the <i>y</i> coordinates of nodes such that there is a minimal amount of intersections of connections between nodes) | ||
edge length reduction (set the <i>y</i> coordinates of nodes such that the length of connections between nodes is minimal) | ||
horizontal alignment (set the <i>y</i> coordinates of nodes such that the connections between nodes are straight as much as possible) | ||
|
||
The final step is the hardest, but also the most important to create a visually pleasing tree. Sadly, I’ve been unable to implement two of the most well known algorithms for this purpose; | ||
|
||
|
||
Brandes, U., & Köpf, B. (2001, September). Fast and simple horizontal coordinate assignment. | ||
Eiglsperger M., Siebenhaller M., Kaufmann M. (2005) An Efficient Implementation of Sugiyama’s Algorithm for Layered Graph Drawing. | ||
Luckily, the crossing reduction and edge length reduction steps partially achieve the goals of the final step. The final graph is not as pretty as it could be, but it’s still pretty good - in most scenarios. | ||
|
||
<size=24>Version</size> | ||
This is version 2.15.465, for RimWorld 0.19.1996. | ||
|
||
</description> | ||
</ModMetaData> | ||
<name>ResearchPal</name> | ||
<author>notfood</author> | ||
<url>https://ludeon.com/forums/index.php?topic=33593.0</url> | ||
<targetVersion>0.19.0</targetVersion> | ||
<description>Smooth painless research | ||
# Features | ||
- automatically generated to maximize readability*. | ||
- shows research projects, buildings, plants and recipes unlocked by each research project. | ||
- projects can be queued, and colonists will automatically start the next project when the current research project completes. | ||
- search functionality to quickly find research projects. | ||
- helptab integration, right click the researches for extra information. | ||
|
||
# Credits: | ||
All the work by Fluffy | ||
Some optimizations by NotFood | ||
Previous updates by NotFood and Skyarkangel | ||
</description> | ||
</ModMetaData> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
946390822 |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,44 @@ | ||
<?xml version="1.0" encoding="UTF-8" ?> | ||
<LanguageData> | ||
|
||
<Fluffy.ResearchTree>ResearchTree</Fluffy.ResearchTree> | ||
|
||
<Fluffy.ResearchTree.AllowsBuildingX>Enables construction {0}</Fluffy.ResearchTree.AllowsBuildingX> | ||
<Fluffy.ResearchTree.AllowsCraftingX>Enables recipe {0}</Fluffy.ResearchTree.AllowsCraftingX> | ||
<Fluffy.ResearchTree.AllowsSowingXinY>Enables planting {0} in {1}</Fluffy.ResearchTree.AllowsSowingXinY> | ||
<Fluffy.ResearchTree.AllowsPlantingX>Enables growing {0}</Fluffy.ResearchTree.AllowsPlantingX> | ||
|
||
<Fluffy.ResearchTree.LClickReplaceQueue>Left-Click to replace queue</Fluffy.ResearchTree.LClickReplaceQueue> | ||
<Fluffy.ResearchTree.LClickRemoveFromQueue>Left-Click to remove from queue</Fluffy.ResearchTree.LClickRemoveFromQueue> | ||
<Fluffy.ResearchTree.SLClickAddToQueue>Shift-Left-Click to add to queue</Fluffy.ResearchTree.SLClickAddToQueue> | ||
<Fluffy.ResearchTree.CLClickDebugInstant>(DEBUG) Ctrl-Left-Click to instantly complete</Fluffy.ResearchTree.CLClickDebugInstant> | ||
<Fluffy.ResearchTree.RClickForDetails>Right click for details</Fluffy.ResearchTree.RClickForDetails> | ||
|
||
<Fluffy.ResearchTree.Requires>Requires</Fluffy.ResearchTree.Requires> | ||
<Fluffy.ResearchTree.LeadsTo>Leads to</Fluffy.ResearchTree.LeadsTo> | ||
|
||
<Fluffy.ResearchTree.QueuedNode>Already queued node</Fluffy.ResearchTree.QueuedNode> | ||
<Fluffy.ResearchTree.MissingFacilities>Missing {0}</Fluffy.ResearchTree.MissingFacilities> | ||
|
||
<Fluffy.ResearchTree.NoResearchFound>no research found</Fluffy.ResearchTree.NoResearchFound> | ||
<Fluffy.ResearchTree.NothingQueued>no research queued</Fluffy.ResearchTree.NothingQueued> | ||
<Fluffy.ResearchTree.NextInQueue>Next in queue: {0}</Fluffy.ResearchTree.NextInQueue> | ||
|
||
<Fluffy.ResearchTree.BuildingResearchTree>Building Research Tree</Fluffy.ResearchTree.BuildingResearchTree> | ||
<Fluffy.ResearchTree.PreparingTree.Setup>Preparing research nodes</Fluffy.ResearchTree.PreparingTree.Setup> | ||
<Fluffy.ResearchTree.PreparingTree.CrossingReduction>Reducing crossings</Fluffy.ResearchTree.PreparingTree.CrossingReduction> | ||
<Fluffy.ResearchTree.PreparingTree.Layout>Finalizing layout</Fluffy.ResearchTree.PreparingTree.Layout> | ||
<Fluffy.ResearchTree.RestoreQueue>Restoring queue</Fluffy.ResearchTree.RestoreQueue> | ||
|
||
<Fluffy.ResearchTree.ShowNotificationPopup>Show Notification Popup</Fluffy.ResearchTree.ShowNotificationPopup> | ||
<Fluffy.ResearchTree.ShowNotificationPopupTip>Whenever you finish research, pause and show the default notification.</Fluffy.ResearchTree.ShowNotificationPopupTip> | ||
<Fluffy.ResearchTree.ShouldSeparateByTechLevels>Group Researches by Tech Level</Fluffy.ResearchTree.ShouldSeparateByTechLevels> | ||
<Fluffy.ResearchTree.ShouldSeparateByTechLevelsTip>Otherwise use a more dense layout (REQUIRES RESTART)</Fluffy.ResearchTree.ShouldSeparateByTechLevelsTip> | ||
<Fluffy.ResearchTree.ShouldPauseOnOpen>Pause on Display</Fluffy.ResearchTree.ShouldPauseOnOpen> | ||
<Fluffy.ResearchTree.ShouldPauseOnOpenTip>Whenever the game should pause when the research tab is displayed.</Fluffy.ResearchTree.ShouldPauseOnOpenTip> | ||
<Fluffy.ResearchTree.ShouldResetOnOpen>Reset on Display</Fluffy.ResearchTree.ShouldResetOnOpen> | ||
<Fluffy.ResearchTree.ShouldResetOnOpenTip>Clear filtering and reset scroll position.</Fluffy.ResearchTree.ShouldResetOnOpenTip> | ||
<ResearchPal>ResearchPal</ResearchPal> | ||
|
||
<ResearchPal.AllowsBuildingX>Enables construction {0}</ResearchPal.AllowsBuildingX> | ||
<ResearchPal.AllowsCraftingX>Enables recipe {0}</ResearchPal.AllowsCraftingX> | ||
<ResearchPal.AllowsSowingXinY>Enables planting {0} in {1}</ResearchPal.AllowsSowingXinY> | ||
<ResearchPal.AllowsPlantingX>Enables growing {0}</ResearchPal.AllowsPlantingX> | ||
|
||
<ResearchPal.LClickReplaceQueue>Left-Click to replace queue</ResearchPal.LClickReplaceQueue> | ||
<ResearchPal.LClickRemoveFromQueue>Left-Click to remove from queue</ResearchPal.LClickRemoveFromQueue> | ||
<ResearchPal.SLClickAddToQueue>Shift-Left-Click to add to queue</ResearchPal.SLClickAddToQueue> | ||
<ResearchPal.CLClickDebugInstant>(DEBUG) Ctrl-Left-Click to instantly complete</ResearchPal.CLClickDebugInstant> | ||
<ResearchPal.RClickForDetails>Right click for details</ResearchPal.RClickForDetails> | ||
|
||
<ResearchPal.Requires>Requires</ResearchPal.Requires> | ||
<ResearchPal.LeadsTo>Leads to</ResearchPal.LeadsTo> | ||
|
||
<ResearchPal.QueuedNode>Already queued node</ResearchPal.QueuedNode> | ||
<ResearchPal.MissingFacilities>Missing {0}</ResearchPal.MissingFacilities> | ||
|
||
<ResearchPal.NoResearchFound>no research found</ResearchPal.NoResearchFound> | ||
<ResearchPal.NothingQueued>no research queued</ResearchPal.NothingQueued> | ||
<ResearchPal.NextInQueue>Next in queue: {0}</ResearchPal.NextInQueue> | ||
|
||
<ResearchPal.BuildingResearchTree>Building Research Tree</ResearchPal.BuildingResearchTree> | ||
<ResearchPal.PreparingTree.Setup>Preparing research nodes</ResearchPal.PreparingTree.Setup> | ||
<ResearchPal.PreparingTree.CrossingReduction>Reducing crossings</ResearchPal.PreparingTree.CrossingReduction> | ||
<ResearchPal.PreparingTree.Layout>Finalizing layout</ResearchPal.PreparingTree.Layout> | ||
<ResearchPal.PreparingTree.RestoreQueue>Restoring queue</ResearchPal.PreparingTree.RestoreQueue> | ||
|
||
<ResearchPal.ShowNotificationPopup>Show Notification Popup</ResearchPal.ShowNotificationPopup> | ||
<ResearchPal.ShowNotificationPopupTip>Whenever you finish research, pause and show the default notification.</ResearchPal.ShowNotificationPopupTip> | ||
<ResearchPal.ShouldSeparateByTechLevels>Group Researches by Tech Level</ResearchPal.ShouldSeparateByTechLevels> | ||
<ResearchPal.ShouldSeparateByTechLevelsTip>Otherwise use a more dense layout (REQUIRES RESTART)</ResearchPal.ShouldSeparateByTechLevelsTip> | ||
<ResearchPal.ShouldPauseOnOpen>Pause on Display</ResearchPal.ShouldPauseOnOpen> | ||
<ResearchPal.ShouldPauseOnOpenTip>Whenever the game should pause when the research tab is displayed.</ResearchPal.ShouldPauseOnOpenTip> | ||
<ResearchPal.ShouldResetOnOpen>Reset on Display</ResearchPal.ShouldResetOnOpen> | ||
<ResearchPal.ShouldResetOnOpenTip>Clear filtering and reset scroll position.</ResearchPal.ShouldResetOnOpenTip> | ||
|
||
<Fluffy.ResearchTree.NeedsRestart>Research settings changed, restart RimWorld to apply the change.</Fluffy.ResearchTree.NeedsRestart> | ||
<Fluffy.ResearchTree.ResearchFinished>Finished research: {0}</Fluffy.ResearchTree.ResearchFinished> | ||
<ResearchPal.NeedsRestart>Research settings changed, restart RimWorld to apply the change.</ResearchPal.NeedsRestart> | ||
<ResearchPal.ResearchFinished>Finished research: {0}</ResearchPal.ResearchFinished> | ||
</LanguageData> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# RimWorld-ResearchPal | ||
|
||
[![Version](https://img.shields.io/badge/Rimworld-A19-green.svg)](http://rimworldgame.com/) | ||
[![License: CC BY-NC-SA 4.0](https://img.shields.io/badge/License-CC%20BY--NC--SA%204.0-blue.svg)](http://creativecommons.org/licenses/by-nc-sa/4.0/) | ||
|
||
Smooth painless research | ||
|
||
# Features | ||
- automatically generated to maximize readability*. | ||
- shows research projects, buildings, plants and recipes unlocked by each research project. | ||
- projects can be queued, and colonists will automatically start the next project when the current research project completes. | ||
- search functionality to quickly find research projects. | ||
- helptab integration, right click the researches for extra information. | ||
|
||
# FAQ | ||
### *Can I add/remove this from an existing save?* | ||
|
||
You can add it to existing saves without problems. Removing this mod will lead to some errors when loading, but these should not affect gameplay - and will go away after saving. | ||
|
||
### *Why is research X in position Y?* | ||
|
||
Lonely unconnected researches will be found on top. The rest follows a stacking algorithm. | ||
|
||
### *Can I use this with mod X* | ||
|
||
Should work with everything, even alongside ResearchTree. They'll have different queues though. | ||
|
||
### *This looks very similar to ResearchTree* | ||
|
||
This is a fork, Fluffy's ResearchTree is the upstream project, there are minor but important differences between those two projects. | ||
ResearchPal offers a denser layout and builds it as RimWorld starts. Less scrolling for the user and in my experience no slowdowns or lag. | ||
|
||
# Technical | ||
It's all magic. Fluffy knows the how, I just adapt things. See their [GitHub](https://github.com/FluffierThanThou/ResearchTree/#Technical). | ||
|
||
# License | ||
All original code in this mod is licensed under the [MIT license](https://opensource.org/licenses/MIT). Do what you want, but give me credit. | ||
All original content (e.g. text, imagery, sounds) in this mod is licensed under the [CC-BY-SA 4.0 license](http://creativecommons.org/licenses/by-sa/4.0/). | ||
|
||
Parts of the code in this mod, and some content may be licensed by their original authors. If this is the case, the original author & license will either be given in the source code, or be in a LICENSE file next to the content. Please do not decompile my mods, but use the original source code available on [GitHub](https://github.com/FluffierThanThou/ResearchTree/), so license information in the source code is preserved. | ||
|
||
# Feeling grateful? | ||
[Buy Fluffy a coffee](https://ko-fi.com/fluffymods). They did most of the work. | ||
|
||
|
||
## Credits: | ||
All the work by Fluffy | ||
|
||
Some optimizations by NotFood | ||
|
||
Previous updates by NotFood and Skyarkangel |
Oops, something went wrong.