Jump to content

[KSP >= 1.3.0] TweakScale - Under Lisias' Management - 2.4.8.8 - 2024-1117


Lisias

Recommended Posts

Just now, linuxgurugamer said:

Never feel afraid to ask a question.  If you are working on a mod and get stuck, I can usually take a few minutes to take a look.  May take a little while, after all, RL comes first.  But if you put it up in github, I (and others) can always pull it down to take a look.

Thanks! I appreciate the help. I'm sure I'll get the hang of it after a little practice. Just have to do the steps properly. And for some reason, the order isn't necessarily obvious.

Link to comment
Share on other sites

Just now, linuxgurugamer said:

But if you put it up in github, I (and others) can always pull it down to take a look.

@AmpCat - and do what you do, always take a deep breath when someone pinpoints a bug on your code. You will fail, you will miss obvious things, and that's the price we pay for doing new things, or updating old things to cope with new things. :)

Speaking on the Devil:

I leaked a tyop :blush: on the .Version file for TweakScale that ended up borking CKAN. The tool I was relying to check this revealled itself too much tolerant for compliance, besides being way convenient for end users (I don't need to update the ZIP files, that tool overcome the typo and manage to still go on fine, something hard to complain, I say).

Link to comment
Share on other sites

Well i think i fumbled through Stunt 4 on my windows 10 machine(i have very little coding and modding experience.)  Using latest KSPe dlls 2019 dll's and 4.6 .net (Using visual studio 2017) i compiled Scale.dll and Scale_Redist.dll and placed them into the mods folder.

Doing bout the same thing as what you experienced before, two white boxes overlapped by the debug button.  You can press them and sometimes it would decrease part size (Couldn't increase).  Hopefully someone else runs the stunt 4 just to make sure, like I said i believe I did it right (since it compiled and the mod was at least present in the game)  I love this mod and wanted to try and help.  Hope you can figure out whats going on without too much stress.

Link to comment
Share on other sites

Well, took a while, but finally got visual studio up and running, compiling a hello world (for both a part module and runtime mod), and I'm thoroughly confused as to what kept it from working the whole time. But it works now.

I'll see if I can get TweakScale to compile on my comp now.

Link to comment
Share on other sites

@Lisias I tried to compile your project from earlier with the four stunts, and cloned the github repo. When trying to build the project in VS, I get several missing files:

Severity	Code	Description	Project	File	Line	Suppression State	Suppression State
Error	CS2001	Source file 'C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale_TweakableEverything\..\Version.cs' could not be found.	Scale_TweakableEverything	C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale_TweakableEverything\CSC	1		Active
Error	CS2001	Source file 'C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale_Redist\..\Version.cs' could not be found.	Scale_Redist	C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale_Redist\CSC	1		Active
Error	CS2001	Source file 'C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale\..\Version.cs' could not be found.	Scale	C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale\CSC	1		Active
Error	CS2001	Source file 'C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale\..\Configuration.cs' could not be found.	Scale	C:\Users\Robert\OneDrive\Documents\GitHub\TweakScale\Source\Scale\CSC	1		Active

Are these needed and just missing?

Link to comment
Share on other sites

3 minutes ago, AmpCat said:

@Lisias I tried to compile your project from earlier with the four stunts, and cloned the github repo. When trying to build the project in VS, I get several missing files:

<CUT by me>

Are these needed and just missing?

Uuugh…. I completely forgot to mention. Sorry!!!

Click on right-button over Version.tt and Configuration.tt (both inside Properties). They are templates that will generate these two files.

Link to comment
Share on other sites

And then 'Run this tool' I imagine. Much better! Kinda. Now I'm missing KSPe , KSPAddon, TimedMessageBox.. and countless others :p

Sorry, I'm sorta new at these newfangled tools. I'm used to an embedded IDE and standard C. Much simpler.

Link to comment
Share on other sites

19 minutes ago, AmpCat said:

And then 'Run this tool' I imagine. Much better! Kinda. Now I'm missing KSPe , KSPAddon, TimedMessageBox.. and countless others :p

Sorry, I'm sorta new at these newfangled tools. I'm used to an embedded IDE and standard C. Much simpler.

You are borking one step ahed, It's an improvement! :D

The magic word is "References".  Right click on "References" and navigate to the rightmost Tab. There you will be able to browse to the DLLs place on your machine. Don't mind, now, about breaking something on other's machines if you change something on yours. You need to make the thing work first on your machine, then we settle up a way to make things work on everybody's machine - it's easy, but I never bored about because I was developing alone until the moment! :P 

 

2 hours ago, Cynro said:

Well i think i fumbled through Stunt 4 on my windows 10 machine(i have very little coding and modding experience.)  Using latest KSPe dlls 2019 dll's and 4.6 .net (Using visual studio 2017) i compiled Scale.dll and Scale_Redist.dll and placed them into the mods folder.

Doing bout the same thing as what you experienced before, two white boxes overlapped by the debug button.  You can press them and sometimes it would decrease part size (Couldn't increase).  Hopefully someone else runs the stunt 4 just to make sure, like I said i believe I did it right (since it compiled and the mod was at least present in the game)  I love this mod and wanted to try and help.  Hope you can figure out whats going on without too much stress.

 Thank you very much. I needed to get MacOS out of the equation. It's interesting, but last year when I was messing with UbioWelding, my first "client" :D complained he weren't being able to run the thing on his machine, while obviously I was on mine. When he sent me the log, I became baffled because that did not made sense, that freaking binary was running fine here. And them I remembered my times on Win16 coding and the first issues of the DLL hell. :D Using the Windows libraries (and not the MacOS ones) to compile against solved the problem.

Since "gato escaldado tem medo de água fria :P I choose to ask for confirmation against this.

Thanks again!

Link to comment
Share on other sites

17 minutes ago, IronKerbal said:

@Lisias I think you frogot to add the latest version of TweakScale to CKAN

Worst. I fixed the problem but forgot to tell about. Sorry, guys. I'm asking what to do on CKAN thread.

On the bright side, I managed to find a working workaround in the mean time. Still trying to make the thing functional, this widget is way less convenient that the lost UI_ScaleEdit. But at least, it's something.

E0cMuc4.png

UI_FloatRange is the name, and thanks to @zer0Kerbal for using it - I plain searched the CSharp libraries for every thingy that extends UI_Control and gone "hunt" on GitHub to see who else is using it. :) 

Link to comment
Share on other sites

On 10/23/2019 at 10:42 PM, Commodoregamer118 said:

That way to re-scale the parts is way better.

Because when i try to scale some parts its just impossible to scale to a specific number.

For example:135%

Most of the time, you are scaling things to predefined slots. 0.625, 2.5, 5m , etc. And at this moment this is lost.

E4eD7ar.png

Do you see what I mean? :) (ok, this is code still targeting the older widget - but you got it)

In a way or another, I got it. You want a finer increment! on the thing! This is the current dev version running on KSP 1.7.3, what do you think?

xNQRR3v.png

And that "<<" and ">>" buttons make a lot of difference on the day to day rocket building!

— — — — 

The current code is here:

https://github.com/net-lisias-ksp/TweakScale/tree/pub/bug/180_FloatRange

Guys, I need to slow down a bit this thing. Work comes first, but I neglect it somewhat this week and now I need to give it the proper attention. I'm working with very supportive co-workers, and they are also helping on this by giving me some slack, but there's a limit and I don't want to cross it.

I will respond as the time allows. I usually have some 5 to 10 minutes timeframes scattered on the day.

Edited by Lisias
post edit.
Link to comment
Share on other sites

2 hours ago, Lisias said:

You are borking one step ahed, It's an improvement! :D

The magic word is "References".  Right click on "References" and navigate to the rightmost Tab. There you will be able to browse to the DLLs place on your machine. Don't mind, now, about breaking something on other's machines if you change something on yours. You need to make the thing work first on your machine, then we settle up a way to make things work on everybody's machine - it's easy, but I never bored about because I was developing alone until the moment! :P 

Agreed, but where do I find those references? Are there other DLLs for KSPe and whatnot? Which additional DLLs do I need?

Link to comment
Share on other sites

4 hours ago, Lisias said:

UI_FloatRange is the name, and thanks to @zer0Kerbal for using it - I plain searched the CSharp libraries for every thingy that extends UI_Control and gone "hunt" on GitHub to see who else is using it. :) 

Thank you, but all the credit goes to the original author @Orum.

Isn't it ironic you have been looking at that code already? sometimes old and dusty saves the day. :P

 

4 hours ago, Lisias said:

And that "<<" and ">>" buttons make a lot of difference on the day to day rocket building!

well - it is a kludge, but take what ODFC does with buttons (NEXT PREV) and use that???? won't be on the same line - but... probably would work, just not a pretty. To remove the clutter, could group the tweakscale controls; albiet not necessary because on in editor scene(s).

 

3 hours ago, AmpCat said:

Agreed, but where do I find those references? Are there other DLLs for KSPe and whatnot? Which additional DLLs do I need?

check out ODFC on github - it is simple enough that it might help. master branch.

Link to comment
Share on other sites

Though I am quite new to ksp modding myself I would like to try and help out a bit where I can. It looks like you have found a workaround with UI_FloatRange, and the finer increment is something I have always wanted as well! I will take a stab at compiling for a 1.7.3 install and report back.

Big thanks @Lisias for heading up one the the most important mods the game has. Hope you don't mind another newbie fumbling around your carefully written code :P

Link to comment
Share on other sites

1 hour ago, count_Zer0 said:

.Big thanks @Lisias for heading up one the the most important mods the game has. Hope you don't mind another newbie fumbling around your carefully written code :P

Welcome! And no, i don't mind at all. I need some more people borking here, so I can try to hide my owns! :sticktongue:

Link to comment
Share on other sites

1 hour ago, count_Zer0 said:

,and the finer increment is something I have always wanted as well! I will take a stab at compiling for a 1.7.3 install and report back.

The increment can be tricky. There are so many pixels available on that slider, you can't have more increments than pixels, and people with different screen resolutions will obviously have different "clickable increments" available.

This can make things a bit hairy to settle. I think that most complains about the scaling control are, indeed, related to how much pixels the dude have available to click.

For example, if you define an increment of 100 steps, but have only 70 pixels on the widget, it's evident that you will not be able to get about 30 of that steps (perhaps more, due two pixel hitting the same increment due rounding errors).

Edited by Lisias
Hate touch screens
Link to comment
Share on other sites

I just dropped by to thank you for an amazing job on this mod.  I've only been playing since 1.73, and about 2 months ago at that.  I played for a week before I discovered mods.  Then I found yours.  I only wish I had the talent you all have, because these little hacks and tweaks you do make the game so much more enjoyable.  Though I must say my poor i7 7700k is almost beyond it's limit as it is at times, and these mods sure make the fps low............. but then I am also a graphics person, so I refuse to turn down the specs... :P  Thank you a million from all of us. :)

Link to comment
Share on other sites

3 hours ago, Lisias said:

The increment can be tricky. There are so many pixels available on that slider, you can't have more increments than pixels, and people with different screen resolutions will obviously have different "clickable increments" available.

This can make things a bit hairy to settle. I think that most complains about the scaling control are, indeed, related to how much pixels the dude have available to click.

For example, if you define an increment of 100 steps, but have only 70 pixels on the widget, it's evident that you will not be able to get about 30 of that steps (perhaps more, due two pixel hitting the same increment due rounding errors).

Yes, I can see how that could be a problem, particularly since there is no way to tell the number of pixels any given screen would have in the slider. Entering the size as text would be the ideal solution for all scale fields, have the graphic slider increment set to something simple like 10% chunks between the common part sizes (0.625, 1.25,..). I feel you on the "<<" and ">>" being gone, they are are huge help.

I probably shouldn't be getting too many big ideas before I really know how the UI works, sometimes the simple things are especially challenging.

Link to comment
Share on other sites

I've been following this talk of what's going on because I find it fascinating (I've done some coding, but nothing crazy), but seeing the scaling made me wonder: The new expansion allowed users to hit the # and directly type in the wanted number (for angles or what not) and while I've not started up 1.8 yet to see if its still there, would you be able to implement that if the arrows to change size don't work out?

~~ Edit ~~

count_Zero, your post popped up after I hit post! HA, same idea, good show :)

Edited by Azic Minar
similar train of thought
Link to comment
Share on other sites

5 hours ago, Lisias said:

The increment can be tricky. There are so many pixels available on that slider, you can't have more increments than pixels, and people with different screen resolutions will obviously have different "clickable increments" available.

This can make things a bit hairy to settle. I think that most complains about the scaling control are, indeed, related to how much pixels the dude have available to click.

For example, if you define an increment of 100 steps, but have only 70 pixels on the widget, it's evident that you will not be able to get about 30 of that steps (perhaps more, due two pixel hitting the same increment due rounding errors).

 

59 minutes ago, count_Zer0 said:

Yes, I can see how that could be a problem, particularly since there is no way to tell the number of pixels any given screen would have in the slider. Entering the size as text would be the ideal solution for all scale fields, have the graphic slider increment set to something simple like 10% chunks between the common part sizes (0.625, 1.25,..). I feel you on the "<<" and ">>" being gone, they are are huge help.

I probably shouldn't be getting too many big ideas before I really know how the UI works, sometimes the simple things are especially challenging.

 

49 minutes ago, Azic Minar said:

I've been following this talk of what's going on because I find it fascinating (I've done some coding, but nothing crazy), but seeing the scaling made me wonder: The new expansion allowed users to hit the # and directly type in the wanted number (for angles or what not) and while I've not started up 1.8 yet to see if its still there, would you be able to implement that if the arrows to change size don't work out?

~~ Edit ~~

count_Zero, your post popped up after I hit post! HA, same idea, good show :)

Well from a UI perspective I think there are no many choices to solve this.

- The # <digit number> is obviously a good way to tell tweakscale exactlty what you want but can be time consuming before getting the appropriate setting for the buid as you have to re-type a number for each try.

- There would be another way by adding more buttons like this but it would involve more code.

191025094429424541.png

The >> button does the same, the > button helps the user to make an increment without clicking inside the scale bar.

Link to comment
Share on other sites

I finally realized why so many complains about TweakScale not working. Manual installers, sometimes, doesn't knows how to check for KSP compatibility on CurseForge!

So I wrote an article on my site's Support page - and decided to copy&paste it too here, for your convenience:

Spoiler

How to check TweakScale (and any other Add'On) KSP Compatibility on CurseForge

On the CurseForge main page for the Add'On, on this link for TweakScale, you will get something like this

CurseForge TweakScale Main Page

You will find the latest KSP version supported by the releases on this page, as this detail shows:

Max KSP version supported detail

On the Files link (in yellow above), you can get the listing of every release for the Add'On. TweakScale, at the present time, has these ones:

Current Releases for an Add'On

In Green the place where the latest KSP Version is supported, as well a counter telling how many KSP versions the release supports. Yep, you had read right - TweakScale supports 13 KSP Versions on the same binary (1.7.3 plus 12).

In Yellow, more links that will lead you to the Details page of the Release, with detailed :) information about it:

Detailed Informtion for a Release Release

At least TweakScale provides a very detailed Change Log too, explaining what had changed and advising any precautions you should have while updating.

Please help to spread the word. :)

Link to comment
Share on other sites

Lisias, I am getting this fatal error again on the Z-200 Battery Bank. You had helped me a few months ago resolve this problem but it's occurring again and the fix I applied previously doesn't seem to be working. Here are screenshots of my log showing the error and my ModuleManager.ConfigCache showing what I did last time. Tweakscale has updated and so I thought that might have been the issue. I let CKAN do the update and I applied the fix to the configcache file and it still is giving me the error.

Quote

[TweakScale] WARNING: **FATAL** Found a showstopper problem on batteryBankMini (Z-200 Rechargeable Battery Bank).
 
(Filename: C:/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)

[TweakScale] ERROR: **FATAL** Part batteryBankMini (Z-200 Rechargeable Battery Bank) has a fatal problem due having duplicated properties - see issue [#34]( https://github.com/net-lisias-ksp/TweakScale/issues/34 ).

Quote

MODULE
        {
            name = TweakScale
            type = stack
            defaultScale = 0.625
            %type = RealismOverhaulStackSolid

 

Link to comment
Share on other sites

I still can't even get this game to start since 1.8. I'm stubbornly not removing my mods, instead waiting and hoping for some mod updates that might fix my problem. The thought of losing all the stuff I've built just makes me ........................... I recently installed a mod called Madlad which I guess checks for bad mods during start up. Boy it sure doesn't like Tweakscale. Throws out in your face messages about not proceeding with it in it's current version.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...