Jump to content

[1.4.x] TweakScale v2.3.12(Apr-16)


pellinor

Recommended Posts

5 hours ago, pellinor said:

I have no idea how this database reload does and how a plugin needs to behave to survive it. Is there any documentation about this?

I'm afraid I'm not sure either.  But I really appreciate your willingness to take a look, and if I find anything relevant I'll pass it along.  Thanks for all your hard work on this mod.

Link to comment
Share on other sites

On 23.5.2016 at 10:54 PM, Gordon Dry said:
  • a stock bug
  • a PF bug
  • a PP bug
  • a unknown whatever bug

Or a messed up install (supposing you still have all those exceptions happening).

You could fix those gaps in a text editor, but it would mean shifting the part by an odd amount, maybe in an odd direction. Not something to do manually. To my knowledge the best fix is to reconnect the parts in the editor. And if you have vanishing nodes then try to solve the exceptions first.

An exception literally means that the program comes to a situation where it can not continue, and the only safe thing would be to crash. Then it skips code until finding a "catch" statement, hoping that this has not left an inconsistent mess behind. This can cause all sorts of issues that might not become obvious immediately.

23 hours ago, tsaven said:

Out of curiosity, is there any mod that will show (in the VAB or SPH) what the adjusted output of scaled engines will be?)

I think KER does that. Also RscBuildAid (probably the sum of all engines).

Edited by pellinor
Link to comment
Share on other sites

On May 22, 2016 at 5:54 PM, pellinor said:

@Parallax59 @ss8913 this is a second issue that makes a certain optimisation from last week look suspicious. Could you try to reproduce your issues with the version from before and after that change? (you only need to replace Scale.dll) If you can confirm that this change broke your crafts I'll revert it and push out a new version.

before:
https://github.com/pellinor0/TweakScale/blob/a346b6a2191cc8c0cb94fc194ac1b63804ecb7de/GameData/TweakScale/plugins/

after:
https://github.com/pellinor0/TweakScale/blob/f9a730b17723558469d5b8d634cb10750ed0af49/GameData/TweakScale/plugins/

I cannot confirm that changes between 2.2.11 and 2.2.12 broke anything. I did some more testing and this is what I found with Tweak Scale versions 2.2.11.0 and 2.2.12.0 (the same behavior is seen with either version installed):

Using stock tanks and engines, single stage w/MechJeb .

Scaling down, the same delta-V is listed in MechJeb on the pad as in VAB. However when returning to VAB it shows I have the amount of propellants I am supposed to have, but can add much more fuel and oxidizer to bring the total up to the original without the mass changing.  Now going back to the pad I have a huge delta-V available, larger than the original (because fuel mass doesn't go up but the volume available to burn does).

Scaling up doesn't preserve what you do in VAB.  I upscale my tank and note the delta-V in MechJeb.  Now go to the pad and my delta-V shrinks terribly.  Looking at my fuel at the pad it resets it back to stock values while the tanks are apparently full, but the mass is that of the tweaked tank with the mass of the increased fuel even though it won't burn it.  Basically this is the opposite of the downscale.

In the latter case, returning to VAB changes nothing.  But if I now tweak the tank back to stock size the propellants re-scale to much smaller than stock.

I have a heavily modded install, so this may take some time if there is some unwanted interaction going on.  But I have to ask the naive question, can a different mod interfere with Tweak Scale on this level even though it is apparently not being used with such a simple test on stock parts?  I know that some mods bundle other mods with them and often not up-to-date. I have of course checked for that and appear to be clean.

Update:  This is not Tweak Scale, it may be an interaction though, so I am trying to figure it out.  I started clean with Tweak Scale and MechJeb as the only mods and the tanks, propellants, delta-V all turned out ok.  Sorry if I worried anyone.  If I take the time to figure out what went wrong I will let you know.

Edited by Parallax59
update
Link to comment
Share on other sites

1 hour ago, Parallax59 said:

I cannot confirm that changes between 2.2.11 and 2.2.12 broke anything. I did some more testing and this is what I found in both Tweak Scale versions 2.2.11.0 and 2.2.12.0

Thanks, this already helps a lot.

1 hour ago, Parallax59 said:

I have to ask the naive question, can a different mod interfere with Tweak Scale on this level even though it is apparently not being used with such a simple test on stock parts?

Yes, because I don't consider this apparent at all, especially in a heavily modded install. There are many modules that can end up on the same part with TweakScale, and will manipulate the same things. For example FAR, modularFuelTanks/realFuels, a variety of fuel switches, or even kOS (which also modifies part mass). Also, exceptions can cause code to be skipped (see my post above), which could in principle also cause all sorts of "reverting" problems.

Could you upload a minimal craft file that reproduces the bug for you? A one-part craft would be enough, just so I can see what modules are on that part in your install.

A game log would also be helpful.

So, to sum up the most obvious symptoms from your report:

* downscaled tank: launch, revert to VAB
  => fuel amount is ok, but maxAmount is reverted

* upscaled tank: just launch
  => maxAmount reverts (rest might be a consequence)

Sounds very much like a new interaction problem with one of the fuel tank mods. Which of course does not mean it's their fault.

Edited by pellinor
Link to comment
Share on other sites

I found the culprit, it was something called Cryo Tanks, which is a subfolder of the Cryogenic Engines mod version 0.3.2.  In any event, here are the parts I used:

Tank:  Rockomax -X200-32 Fuel Tank (2.5 m)

MechJeb 2 (AR 202 case) (module SPU)

LV-T30 "Reliant" Liquid Fuel Engine

You do need all 3 parts to readily see the problem in the delta-V reported by MechJeb.  Attached (if it works) is the .craft file.

file:///Applications/KSP_osx/saves/TweakScaleTest/Ships/VAB/TweakTestArticle.craft

As you can see, I can't seem to upload files... I am new to the forum, so haven't figured everything out yet.  But any stock tank, stock engine, w/MechJeb (to see the delta-V) will exhibit this behavior if the Cryo Tanks subset of the Cryogenic Engines mod version 0.3.2 is installed.

I hope this helps you guys out.

Edited by Parallax59
additional question
Link to comment
Share on other sites

So did you test with a minimum install or are still supposing that your other mods have no influence? Cryotanks has its own boiloff module but it also patches parts with fuelswitches (so the result is likely to depend on which other mods are installed). And did you look what modules are on that tank? Craft file are just regular text files, you can copy&paste text from there into a forum post (use spoiler tags if copying more than a few lines).

I'll look into this as soon as I can, but not sure if I'll find the time before next monday.

@Parallax59 Did a quick test and found that cryoEngines bundles an outdated version of B9PartSwitch (v1.1.4). The current version v1.2 explicitely says "TweakScale integration" in the changelog. Does updating B9PartSwitch solve your issue?

I can reproduce that v1.1.4 does not work with TweakScale. Just switching first scale and then tank type in the editor is enough for fuel amounts to revert.

Edit: I can't recommend KSP-AVC enough, just starting KSP was enough to see what was wrong with the install.

Edited by pellinor
Link to comment
Share on other sites

@pellinor  Updating the B9PartSwitch seems to have done the trick.  Thanks!  I used to install KSP-AVC, but it used to complain about itself and until recently I couldn't find an update.  I have it now though.  If that would have saved all this time to figure it out, it sure would have been worth it.  The good news in all of this is that TweakScale works as intended and it is one of my most relied-upon mods!

 

Link to comment
Share on other sites

There is bug with resized crew cabins...

IndexOutOfRangeException: [PartCrewManifest Error]: seat index out of range: i = 2 while Mark2Cockpit has 1 seats
  at PartCrewManifest.AddCrewToSeat (.ProtoCrewMember crew, Int32 seatIndex) [0x00000] in <filename unknown>:0

  at KSP.UI.CrewAssignmentDialog.GetManifest () [0x00000] in <filename unknown>:0

  at EditorLogic.launchVessel () [0x00000] in <filename unknown>:0

  at KRASH.LaunchGUI.LaunchSim () [0x00000] in <filename unknown>:0

  at KRASH.LaunchGUI.drawRightSelectorWindow (SelectionType type) [0x00000] in <filename unknown>:0

  at KRASH.LaunchGUI.drawSelectorWindow (Int32 id) [0x00000] in <filename unknown>:0

  at UnityEngine.GUI.CallWindowDelegate (UnityEngine.WindowFunction func, Int32 id, UnityEngine.GUISkin _skin, Int32 forceRect, Single width, Single height, UnityEngine.GUIStyle style) [0x00000] in <filename unknown>:0
 
(Filename:  Line: -1)

KRASH is here, because I wanted to put ship on orbit using this simulation mod.

Edited by raxo2222
Link to comment
Share on other sites

On 20-5-2016 at 10:44 PM, pellinor said:

Fixed in the dev version. Looks like the panel mechanics have become a bit more complex and I need to scale a different variable now.

Thank you for looking into the issue!

However, strangely, the functionality of rescaled solar panels is still compromised. In flight, when right clicking on the solar panels you can see the output of the solar panel in the pop-up context menu being correctly scaled with the size of the solar panel. However, when checking the batteries, they still fill up at the rate of the standard-sized solar panels, regardless of the panel scaling. So even though the panel output is correctly calculated in the VAB, in the solar panel context menu in flight, it does not acualy produce the predicted amount of energy.

Thank you again for your efforts,
Rombrecht

Link to comment
Share on other sites

  • 2 weeks later...

Is anyone else getting a bug with inverted interiors wheen using TweakScale? This is what I got at first:

Spoiler

11hc4uh.png

Note that the door should be where Bill's butt is. Switching to internal view gives an extreme close up of Bill's forehead. I re-installed the game, and had no problem. When I installed TweakScale again, I got the same issue.

Edited by Cosmic_Farmer
Link to comment
Share on other sites

Hey guys, I found a bug, I think. When after reload the craft file, clicking right button on resized tanks force them switch back to stock fuel amount (size stays correct)?

If you reload that rocket with resized tank, but don't right click that tank and launch it - tank will have right fuel ammount, but stock maxAmmount... :(

 

Have anyone seen this bug, or it's just some wierd conflict in my >180 mods build?

PS This is with last version of B9PartSwitch v1.4.1

Edited by ZobrAA
Link to comment
Share on other sites

On 4.6.2016 at 11:54 AM, Rombrecht said:

However, strangely, the functionality of rescaled solar panels is still compromised. In flight, when right clicking on the solar panels you can see the output of the solar panel in the pop-up context menu being correctly scaled with the size of the solar panel. However, when checking the batteries, they still fill up at the rate of the standard-sized solar panels, regardless of the panel scaling. So even though the panel output is correctly calculated in the VAB, in the solar panel context menu in flight, it does not acualy produce the predicted amount of energy.

Thanks for noticing. I switched to yet another of those numerous undocumented float values and it seems to work now (fixed in the dev version).

On 14.6.2016 at 5:38 PM, Cosmic_Farmer said:

Note that the door should be where Bill's butt is. Switching to internal view gives an extreme close up of Bill's forehead. I re-installed the game, and had no problem. When I installed TweakScale again, I got the same issue.

Is the part scaled? TweakScale should not touch that transform for unscaled parts (v2.2.12 or dev version). Even for a scaled pod I can not reproduce it. Could you upload the craft that causes this?

On 16.6.2016 at 2:08 AM, siliconworm said:

When the wheels are scaled up, they don't appear to be touching the ground. This makes the gaming experience really bad, can you please fix it?

Unfortunately no, I have no idea what to do with those wheel modules. Obviously Squad fixed it for the "rescaleFactor", so as a workaround you can define your own scaled wheels this way. However I have received no answer to my question if whatever they do can also be done by TweakScale after loading the part in flight. Might also not be worth their time since the wheel code will again change a lot for KSP1.2.

Link to comment
Share on other sites

On 15.6.2016 at 4:43 PM, ZobrAA said:

Hey guys, I found a bug, I think. When after reload the craft file, clicking right button on resized tanks force them switch back to stock fuel amount (size stays correct)?

Also happens for me, reproduction:

* take new stock LFO tank
* rescale (amount scales)
* switch tank type (ok)
* switch tank type back to LFO => amount resets to unscaled values

Edit: opened an issue for B9PartSwitch.

On 31.5.2016 at 11:36 PM, Mine_Turtle said:

Is scaling for b9 cockpits not supported yet?

I'd like to get crew scaling stable before adding more crewed parts. But feel free to write your own custom patches.

Edited by pellinor
Link to comment
Share on other sites

1 hour ago, dboi88 said:

Here's a re-compile for 1.1.3 done by @Warezcrawler

I've installed and tested and everything seems to be working fine . . . this should tide everyone over until @pellinor has the time to take a proper look.

https://drive.google.com/open?id=0B8MQtxvD6CVRbHUxbndxU1JNTG8

enjoy!

Are  you sure that is the recompiled file?  When I start KSP it says both ProceduralParts and Scale are incompatibile after putting that scale.dll in.

 

Link to comment
Share on other sites

17 minutes ago, armegeddon said:

Are  you sure that is the recompiled file?  When I start KSP it says both ProceduralParts and Scale are incompatibile after putting that scale.dll in.

Yes but it is nothing more than a recompile of the source code, there is nothing changed so it'll still have the old version numbers ect. It's a working version for anyone who can't wait for an official release but there could be any number of bugs that would require the author to fix, seems completely fine to me so far though.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...