complynx Posted September 3, 2015 Share Posted September 3, 2015 Thank you for your answer.For the first two cases, I can use regexps nevertheless, but is there any other solution?In case of splitting parsing into two cases depending on just recently added variable?For the second case, maybe there is a better solution to distinguish these situations: to use regexp variable extraction or to use escape sequence?If the dollar sign is appeared twice it will be replaced as dollar sign, otherwise it is considered as a variable.And a variable replacement is to be done before regexp or other expression.So for my case the solution would be:@var_to_update ^= #:^.*$$:$$0;$var_to_paste$:and the process in the parser:1) Is there a hash at the right side?2) If no hash, skip to 43) Find every /\$([^\$]*)\$/ and replace with var referenced by the first match if it is not empty, else replace with $4) Do the expression stuff. In this case regexp replacement. Quote Link to comment Share on other sites More sharing options...
Kerbas_ad_astra Posted September 5, 2015 Share Posted September 5, 2015 For my "SMURFF" addon, I'm working on a patch that increases SRBs Isp by 40 seconds. Here's what I've got so far:@PART[*]:HAS[@RESOURCE[SolidFuel]]:FOR[SMURFF]{ [...] @MODULE[ModuleEngines*]:HAS[@PROPELLANT[SolidFuel]] { key0 = #$atmosphereCurve/key,0[1, ]$ //get the keys -- the second element of the first space-separated list called "key". key1 = #$atmosphereCurve/key,1[1, ]$ @key0 += 40 //modify values -- add 40 seconds to bring Kickback close to Space Shuttle SRBs. @key1 += 40 @atmosphereCurve //Unfortunately, this will wipe any tangents until I figure out a way to identify which keys have tangents and which don't. SRBs usually don't have any, but the "1" key of RLA Stockalike's SRBs do. { @key,0 = #$key,0[0, ]$ $../key0$ //$key,0[2, ]$ $key,0[3, ]$ @key,1 = #$key,1[0, ]$ $../key1$ //$key,1[2, ]$ $key,1[3, ]$ } } [...]}I can extract the current specific impulses and modify them (even if the atmosphereCurve has tangents), but putting them back in is the tricky part, because I don't know of a way to know in advance if a key has two elements or four. The patch above, as it stands, will just squash any tangents; if I uncomment out the second half of each line, then keys that have tangents will keep them, but keys that don't will have their elements duplicated (e.g. key = 0 285 0 285 0 285). I've tried playing with regexes (e.g. @MODULE[ModuleEngines*]:HAS[@PROPELLANT[solidFuel],@atmosphereCurve:HAS[#key,1[1.\d+.*]]] to try to filter out only engines whose second key is more than "1 [number]") but those don't seem to work in HAS blocks (not that I was really expecting them to, but it would have been a pleasant surprise if they did).Is there a way to figure out in advance how many elements are in a character-separated list? Quote Link to comment Share on other sites More sharing options...
sarbian Posted September 5, 2015 Author Share Posted September 5, 2015 djnattyd : can you try this one ModuleManager-2.6.9.zip and put your log somewhere ?Kerbas_ad_astra : nope. I should maybe report an empty string when the value is not found. Quote Link to comment Share on other sites More sharing options...
sarbian Posted September 6, 2015 Author Share Posted September 6, 2015 I am on crush mode at work and then on holiday from September the 10th to October the 12th.That means MM (and my other mods) are on hold until I am back from Japan Quote Link to comment Share on other sites More sharing options...
RobertJPowell Posted September 6, 2015 Share Posted September 6, 2015 Enjoy your holiday Sarbian Quote Link to comment Share on other sites More sharing options...
tmikesecrist3 Posted September 7, 2015 Share Posted September 7, 2015 have a good time sarbian Quote Link to comment Share on other sites More sharing options...
Kerbas_ad_astra Posted September 9, 2015 Share Posted September 9, 2015 I guess this is a bad time for a bug report, but here goes (it can wait until you're back): Module Manager doesn't play nice with full-screen OpenGL.Reproduction steps:1. Stock KSP plus Module Manager, set to fullscreen and opening with -force-opengl launch option.2. Attempt to open "Settings" from the main menu.3. KSP hangs on the loading screen.If PartDatabase.cfg or settings.cfg is deleted before startup (i.e. regenerated by KSP), then the issue doesn't occur.Adding -popupwindow to the launch options (and disabling full-screen) also works around the issue.Have fun on vacation, sarbian -- see you in October! Quote Link to comment Share on other sites More sharing options...
FiiZzioN Posted September 9, 2015 Share Posted September 9, 2015 I guess this is a bad time for a bug report, but here goes (it can wait until you're back): Module Manager doesn't play nice with full-screen OpenGL.Reproduction steps:1. Stock KSP plus Module Manager, set to fullscreen and opening with -force-opengl launch option.2. Attempt to open "Settings" from the main menu.3. KSP hangs on the loading screen.If PartDatabase.cfg or settings.cfg is deleted before startup (i.e. regenerated by KSP), then the issue doesn't occur.Adding -popupwindow to the launch options (and disabling full-screen) also works around the issue.Have fun on vacation, sarbian -- see you in October!So that's why I can't modify my settings without using a fully stock version of KSP and transferring over the settings file...Huh... nice to know! Thanks for figuring this out, as I was just dealing with it. Quote Link to comment Share on other sites More sharing options...
Starwaster Posted September 10, 2015 Share Posted September 10, 2015 I guess this is a bad time for a bug report, but here goes (it can wait until you're back): Module Manager doesn't play nice with full-screen OpenGL.Reproduction steps:1. Stock KSP plus Module Manager, set to fullscreen and opening with -force-opengl launch option.2. Attempt to open "Settings" from the main menu.3. KSP hangs on the loading screen.If PartDatabase.cfg or settings.cfg is deleted before startup (i.e. regenerated by KSP), then the issue doesn't occur.Adding -popupwindow to the launch options (and disabling full-screen) also works around the issue.Have fun on vacation, sarbian -- see you in October!I was unable to repro using your provided steps. KSP loads and the settings menu opens for me as expected.You really need to provide a log file with a report like this. Quote Link to comment Share on other sites More sharing options...
ainamogel Posted September 10, 2015 Share Posted September 10, 2015 I'm sorry if this is completely obvious, but is there some way to see the results of MM's actions on .cfg file without running KSP and seeing the effect in the game? That is, is there an easy way to see what the .cfg file would like after MM is done operating on it?Thanks so much,Ainamogel Quote Link to comment Share on other sites More sharing options...
DocMop Posted September 10, 2015 Share Posted September 10, 2015 I guess this is a bad time for a bug report, but here goes (it can wait until you're back): Module Manager doesn't play nice with full-screen OpenGL.Reproduction steps:1. Stock KSP plus Module Manager, set to fullscreen and opening with -force-opengl launch option.2. Attempt to open "Settings" from the main menu.3. KSP hangs on the loading screen.If PartDatabase.cfg or settings.cfg is deleted before startup (i.e. regenerated by KSP), then the issue doesn't occur.Adding -popupwindow to the launch options (and disabling full-screen) also works around the issue.Have fun on vacation, sarbian -- see you in October!I have that same problem, thought it would be a general problem with OpenGL O.oDoes it work when you ALT+ENTER (toggle fullscreen) in the main menu before you hit "Settings"? Have to test that. Quote Link to comment Share on other sites More sharing options...
sarbian Posted September 10, 2015 Author Share Posted September 10, 2015 1) test with https://ksp.sarbian.com/jenkins/job/ModuleManager/lastSuccessfulBuild/artifact/ModuleManager-2.6.9.zip2) post the full output_log.txt (see this post)ainamogel : MM create a cache file in GameData just after running (so in the loading screen) that show the state of the config after patching Quote Link to comment Share on other sites More sharing options...
ainamogel Posted September 10, 2015 Share Posted September 10, 2015 ainamogel : MM create a cache file in GameData just after running (so in the loading screen) that show the state of the config after patchingAwesome!Thanks!Ainamogel Quote Link to comment Share on other sites More sharing options...
Kerbas_ad_astra Posted September 10, 2015 Share Posted September 10, 2015 Results from testing (including trying alt-enter before entering settings)2.6.8, nonresponsive when going directly to settings: https://gist.github.com/Kerbas-ad-astra/b51226e0aa0b6d974a00#file-output_log_268_fullscreen_unresponsive-txt2.6.8, alt-enter, could enter settings and return: https://gist.github.com/Kerbas-ad-astra/b51226e0aa0b6d974a00#file-output_log_268_fullscreen_altenter-txt2.6.9, nonresponsive when going directly to settings: https://gist.github.com/Kerbas-ad-astra/b51226e0aa0b6d974a00#file-output_log_269_fullscreen_nonresponsive-txt2.6.9, alt-enter, could enter settings and return: https://gist.github.com/Kerbas-ad-astra/b51226e0aa0b6d974a00#file-output_log_269_fullscreen_altenter-txtI wanted to see what would happen if I tried pressing alt-enter after going to settings (i.e. while it hangs on the loading screen), but the issue's just stopped happening (for 2.6.8 as well as 2.6.9). No mods on the test install right now (just Module Manager and KSP 1.0.4 with OpenGL), so there must be some weird system thing going on. If the issue starts happening again, I'll try Alt-Enter after the game hangs, and tell you what happens. Quote Link to comment Share on other sites More sharing options...
sarbian Posted September 10, 2015 Author Share Posted September 10, 2015 Nothing out of the ordinary in any of those logs. I see your KSP is under C:\Program Files (x86). Try moving the KSP dir outside "C:\Program Files (x86)" (Create a C:\Game or something like that and moove the game from there). It may be a strange Anti Virus or Windows Protection interaction. 36H before the plane ! Work is done ! Woooo Quote Link to comment Share on other sites More sharing options...
Kerbas_ad_astra Posted September 10, 2015 Share Posted September 10, 2015 I think I was mistaken -- it's alt-tabbing that's the issue, independent of Module Manager (i.e. stock KSP is affected) and install location. (I may have thought ModuleManager was to blame since I am more likely to alt-tab away from the game when it's installed, whether I have other mods or not.) When I don't alt-tab away from the game during loading, settings opens fine. Alt-tabbing away during loading makes it show the black screen when settings is opened, as does alt-tabbing away from and then back to the settings window (only while fullscreen, no -popupwindow, OpenGL). Toggling fullscreen mode with Alt-Enter clears the black screen and shows the settings properly. Sorry for the confusion! Quote Link to comment Share on other sites More sharing options...
Tarheel1999 Posted September 11, 2015 Share Posted September 11, 2015 I think I was mistaken -- it's alt-tabbing that's the issue, independent of Module Manager (i.e. stock KSP is affected) and install location. (I may have thought ModuleManager was to blame since I am more likely to alt-tab away from the game when it's installed, whether I have other mods or not.) When I don't alt-tab away from the game during loading, settings opens fine. Alt-tabbing away during loading makes it show the black screen when settings is opened, as does alt-tabbing away from and then back to the settings window (only while fullscreen, no -popupwindow, OpenGL). Toggling fullscreen mode with Alt-Enter clears the black screen and shows the settings properly. Sorry for the confusion!IIRC alt-tabbing with the full screen setting is a known problem. Quote Link to comment Share on other sites More sharing options...
Starwaster Posted September 11, 2015 Share Posted September 11, 2015 alt-tabbing is like Russian Roulette. It might cause no problems at all or it might crash the application (whichever fullscreen app du jour). Or cause graphical glitches in the game. (L4D2 tends to result in black skinned zombies and transparency issues)Pre KSP 1.0 it would throw lots of errors if in DX mode.In general, do it at your own risk. If you get away with it, 'more power to you' . If you crash and burn "I told you so" Quote Link to comment Share on other sites More sharing options...
crush3dice Posted September 11, 2015 Share Posted September 11, 2015 Heyi am running ksp 1.0.4, a clean reinstall of it now and for some reason module manager only loads on 2.6.6 or lower... In version 2.6.7 or 2.6.8 it just doesnt load and only says "ModuleManager" in the loading bar forever. Any idea how i could fix that or what i could be doing wrong? Thx Quote Link to comment Share on other sites More sharing options...
Tarheel1999 Posted September 11, 2015 Share Posted September 11, 2015 Heyi am running ksp 1.0.4, a clean reinstall of it now and for some reason module manager only loads on 2.6.6 or lower... In version 2.6.7 or 2.6.8 it just doesnt load and only says "ModuleManager" in the loading bar forever. Any idea how i could fix that or what i could be doing wrong? ThxProvide logs and read this: http://forum.kerbalspaceprogram.com/threads/92229-How-To-Get-Support-%28READ-FIRST%29?p=1380976&viewfull=1#post1380976 Quote Link to comment Share on other sites More sharing options...
deepfield Posted September 14, 2015 Share Posted September 14, 2015 (edited) Using anything above 2.6.6 is freezing displaying nothing but "Module Manager" in the loading bar. The random quotes do continue changing though.Tested versions 2.6.7-2.6.10 All with the same results. output_log.txt: https://www.dropbox.com/s/ijpxabowgn9tq4i/output_log.txt?dl=0ksp.log: https://www.dropbox.com/s/bxyt1rj9v61zs0c/KSP.log?dl=0[EXC 09:12:09.315] IOException: Sharing violation on path C:\Users\Deepfield\Desktop\KSP RSS\KSP.exe System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, FileOptions options) System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share) System.IO.File.Open (System.String path, FileMode mode, FileAccess access) ModuleManager.MMPatchLoader.FileSHA (System.String filename) ModuleManager.MMPatchLoader.PrePatchInit () ModuleManager.MMPatchLoader+<ProcessPatch>c__Iterator0.MoveNext ()Mods:KSP: 1.0.4 (Win32) - Unity: 4.6.4f1 - OS: Windows 7 Service Pack 1 (6.1.7601) 64bitFilter Extensions - 2.4.1Advanced Jet Engine - 2.4.1B9 Aerospace Procedural Parts - 0.40Community Resource Pack - 0.4.4Connected Living Space - 1.1.3.1Deadly Reentry - 7.2.2Ferram Aerospace Research - 0.15.5.1Firespitter - 7.1.4Kerbal Attachment System - 0.5.4Kerbal Joint Reinforcement - 3.1.4Kerbal Inventory System - 1.2.2KSP-AVC Plugin - 1.1.5ModularFlightIntegrator - 1.1.1Procedural Parts - 1.1.7RealChute - 1.3.2.3RealismOverhaul - 10.3.1RealSolarSystem - 10.2RemoteTech - 1.6.8Saturatable RW - 1.10.2SolverEngines - 1.11TestFlight - 1.3.1.1TextureReplacer - 2.4.8TAC Life Support - 0.11.1.20TweakScale - 2.2.1 Edited September 14, 2015 by deepfield Quote Link to comment Share on other sites More sharing options...
NathanKell Posted September 14, 2015 Share Posted September 14, 2015 Don't run KSP from your desktop, that has limited permissions. Make a folder under C:\, like 'Games', and put the KSP folder there. Quote Link to comment Share on other sites More sharing options...
Gaalidas Posted September 14, 2015 Share Posted September 14, 2015 New in the computer industry: keep your file structure safe by downgrading to an all-natural, environment-friendly, and sometimes even green desktop solution in the form of your very own stone tablet complete with a hand-made chisel and hammer combo pack. Never deal with computer viruses again! The only viruses that'll attack you are the gooey slimy kind. (warranty void if kicked, rolled, spat on, used for target practice, used to sacrifice your neighbors to a deity, dipped in water, submerged in lava, left in the weather for any more than 3 years unattended, or touched by viscous slime. Acid exposure has not been reported on, as no one has survived. Can be used as pillow or recreational copulation surface when not in use in its intended form.) Quote Link to comment Share on other sites More sharing options...
deepfield Posted September 14, 2015 Share Posted September 14, 2015 Right on. Moving it did solve the problem. For years I've stored 2-3 games that I heavily mod and access the folder of frequently and never once had an issue until now with UAC. What is MM doing that UAC is blocking it?I've never heard of storing large files on your desktop causing windows to slow down. Nothing is "stored on a desktop" It's just in a folder on your hard drive. The only thing I can think of that would have an effect on that would be search indexer? Quote Link to comment Share on other sites More sharing options...
NathanKell Posted September 14, 2015 Share Posted September 14, 2015 MM is an unsigned dll loaded by KSP, so Windows freaks when it tries to write files. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.