Skip to content

Commit

Permalink
Added TacLib as a git submodule.
Browse files Browse the repository at this point in the history
  • Loading branch information
taraniselsu committed Dec 21, 2013
1 parent 11a3f60 commit 5c168dc
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 29 deletions.
2 changes: 1 addition & 1 deletion .gitignore
@@ -1,4 +1,4 @@
GameData/ThunderAerospace/**/*.dll
GameData/**/*.dll
GameData/ThunderAerospace/*_*.*.txt

#################
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
@@ -0,0 +1,3 @@
[submodule "TacLib"]
path = TacLib
url = https://github.com/taraniselsu/TacLib.git
21 changes: 9 additions & 12 deletions Readme.txt → Readme.md
@@ -1,15 +1,15 @@
A Fuel Balancer from Thunder Aerospace Corporation (TAC),
designed by Taranis Elsu.
TAC Fuel Balancer
===================

A Fuel Balancer from Thunder Aerospace Corporation (TAC), designed by Taranis Elsu.

For use with the Kerbal Space Program, http://kerbalspaceprogram.com/

This mod is made available under the Attribution-NonCommercial-ShareAlike 3.0 (CC BY-NC-SA
3.0) creative commons license. See the LICENSE.txt file.
This mod is made available under the Attribution-NonCommercial-ShareAlike 3.0 (CC BY-NC-SA 3.0) creative commons license. See the LICENSE.txt file.

Source code can be found at https://github.com/taraniselsu/TacFuelBalancer


===== Features =====
### Features
* Transfer a resource into a part, drawing an equal amount from each other part.
* Transfer a resource out of a part, transferring an equal amount into each other part.
* Dump a resource out of a part. Note that the resource is lost, never to be found.
Expand All @@ -27,8 +27,7 @@ This system does not consume power itself, but the vessel is required to have po
required to be controllable (have a probe core or at least one Kerbal on-board). Otherwise,
everything is disabled.


===== How to use =====
### How to use
Open the GUI using the button along the screen edge. It defaults to the top right-hand corner,
but can be dragged to anywhere along any edge.

Expand All @@ -46,8 +45,7 @@ Click the "S" button to bring up the settings menu.
Click the "?" button to bring up the help/about menu.
Click the "X" button to close the window.


===== Settings =====
### Settings
* Maximum Fuel Flow Rate - controls how quickly fuel is transferred around. This limits each
action to only transfer up to the selected amount.
* Fuel Warning Level - warns (yellow) when a resource drops below this percentage of capacity.
Expand All @@ -60,6 +58,5 @@ Click the "X" button to close the window.
are set to Out. Note that this can cause the resource level in a part to rise until it evens out
with the other parts, then it will start decreasing again.


===== Installation procedure =====
### Installation procedure
1) Copy everything in the GameData directory to the {KSP}/GameData directory.
5 changes: 0 additions & 5 deletions Release Checklist.txt

This file was deleted.

12 changes: 6 additions & 6 deletions Source/FuelBalanceController.cs
Expand Up @@ -50,7 +50,7 @@ class FuelBalanceController : MonoBehaviour

void Awake()
{
Debug.Log("TAC Fuel Balancer [" + this.GetInstanceID().ToString("X") + "][" + Time.time + "]: Awake");
this.Log("Awake");
configFilename = IOUtils.GetFilePathFor(this.GetType(), "FuelBalancer.cfg");

settings = new Settings();
Expand All @@ -69,7 +69,7 @@ void Awake()

void Start()
{
Debug.Log("TAC Fuel Balancer [" + this.GetInstanceID().ToString("X") + "][" + Time.time + "]: Start");
this.Log("Start");
Load();

icon.SetVisible(true);
Expand All @@ -80,7 +80,7 @@ void Start()

void OnDestroy()
{
Debug.Log("TAC Fuel Balancer [" + this.GetInstanceID().ToString("X") + "][" + Time.time + "]: OnDestroy");
this.Log("OnDestroy");
icon.SetVisible(false);
Save();
}
Expand All @@ -104,14 +104,14 @@ void FixedUpdate()
{
if (!FlightGlobals.ready)
{
Debug.Log("TAC Fuel Balancer [" + this.GetInstanceID().ToString("X") + "][" + Time.time + "]: FlightGlobals are not valid yet.");
this.Log("FlightGlobals are not valid yet.");
return;
}

Vessel activeVessel = FlightGlobals.fetch.activeVessel;
if (activeVessel == null)
{
Debug.Log("TAC Fuel Balancer [" + this.GetInstanceID().ToString("X") + "][" + Time.time + "]: No active vessel yet.");
this.Log("No active vessel yet.");
return;
}
else if (activeVessel.isEVA)
Expand Down Expand Up @@ -248,7 +248,7 @@ private void OnIconClicked()

private void RebuildLists(Vessel vessel)
{
Debug.Log("TAC Fuel Balancer [" + this.GetInstanceID().ToString("X") + "][" + Time.time + "]: Rebuilding resource lists.");
this.Log("Rebuilding resource lists.");

List<string> toDelete = new List<string>();
foreach (KeyValuePair<string, ResourceInfo> resourceEntry in resources)
Expand Down
13 changes: 8 additions & 5 deletions Source/TacFuelBalancer.csproj
Expand Up @@ -51,16 +51,19 @@
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="..\..\TacLib\Source\Icon.cs">
<Compile Include="..\TacLib\Source\Icon.cs">
<Link>Icon.cs</Link>
</Compile>
<Compile Include="..\..\TacLib\Source\PopupWindow.cs">
<Compile Include="..\TacLib\Source\Logging.cs">
<Link>Logging.cs</Link>
</Compile>
<Compile Include="..\TacLib\Source\PopupWindow.cs">
<Link>PopupWindow.cs</Link>
</Compile>
<Compile Include="..\..\TacLib\Source\Utilities.cs">
<Compile Include="..\TacLib\Source\Utilities.cs">
<Link>Utilities.cs</Link>
</Compile>
<Compile Include="..\..\TacLib\Source\Window.cs">
<Compile Include="..\TacLib\Source\Window.cs">
<Link>Window.cs</Link>
</Compile>
<Compile Include="MainWindow.cs" />
Expand All @@ -72,7 +75,7 @@
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="..\..\TacLib\Source\CommonProperties.proj" />
<Import Project="..\TacLib\Source\CommonProperties.proj" />
<PropertyGroup>
<AssemblyMajorVersion>2</AssemblyMajorVersion>
<AssemblyMinorVersion>1</AssemblyMinorVersion>
Expand Down
1 change: 1 addition & 0 deletions TacLib
Submodule TacLib added at e6eeaa

0 comments on commit 5c168dc

Please sign in to comment.