Enceos Posted January 14, 2017 Share Posted January 14, 2017 @TheRagingIrishman It will be a native KIS config. Quote Link to comment Share on other sites More sharing options...
Skalou Posted January 14, 2017 Share Posted January 14, 2017 (edited) hi, I would like some infos and help i didn't found for my new mod Ext-Seat-Dummy: 1- Is there a way to apply a different patch depending on the game version? 2- Is it possible to modify only some values on this kind of patch: //attachment rules: stack, srfAttach, allowStack, allowSrfAttach, allowCollision @attachRules = 0,1,1,1,0 //allow to be surface attachable i would like to change only the 1st and 2nd value. 3- More complexe , i there a way to swap some values: //From Physics.cfg DRAG_CUBE { //cube = , X+ , X- , Y+ , Y- , Z+ , Z- ,Bcenter Boundextents. //cube = Default, 0.75,0.92,0.4, 0.75,0.92,0.4, 0.6,0.7,0.4, 0.6,0.97,0.7, 0.85,0.95,0.4, 0.85,0.95,0.4, 0,0,0 0.8,1.1,0.8 // The drag cube kerbals use. cube = Default, 0.75,0.92,0.4, 0.75,0.92,0.4, 0.85,0.95,0.4, 0.85,0.95,0.4, 0.6,0.97,0.7, 0.6,0.7,0.4, 0,0,0 0.8,0.8,1.1 //rotated EvaDragCube //kerbalEVADragCubeString = Default, 0.75,0.92,0.4, 0.75,0.92,0.4, 0.6,0.7,0.4, 0.6,0.97,0.7, 0.85,0.95,0.4, 0.85,0.95,0.4, 0,0,0 0.8,1.1,0.8 // The drag cube kerbals use, Physics.cfg //the first six triplets are X+, X-, Y+, Y-, Z+, Z- faces of the cube. //The numbers are area, drag coefficient, and depth of widest point from the frontmost point at that angle. //The next triplet is the bounds center, the final is the bounds extents. } i would like to copy the drag cube values from the Physics.cfg and change the Y+ by the Z+, etc... Thank you for any help. Edited January 14, 2017 by Skalou Quote Link to comment Share on other sites More sharing options...
Sigma88 Posted January 14, 2017 Share Posted January 14, 2017 1- not that I know of. you might be able to get away with some weird thing but it's not simple 2- yes @attachRules[0] = 1 // to change the first element to "1" @attachRules[1] = 1 // to change the second element to "1" 3- yes suppose you have cube = A, B, F, D, E, C and you want to order it alphabetically.. you just do this: @cube = #$cube[0]$,$cube[1]$,$cube[5]$,$cube[3]$,$cube[4]$,$cube[2]$ Quote Link to comment Share on other sites More sharing options...
Skalou Posted January 14, 2017 Share Posted January 14, 2017 Amazing, thank you very much! As the 3 is Ok, i need a lot less the 1 i think. Quote Link to comment Share on other sites More sharing options...
Skalou Posted January 14, 2017 Share Posted January 14, 2017 (edited) I have some other questions i can't answer myself, i also found this in the documentation: Quote Please note that regex generation is often tricky and requires some experimentation to get right. It is assumed that if you want to use this feature you're well versed with how regexps work, including the various variants. Please refer to the .net documentaton and/or copious other documentation available on the Internet. I won't support questions about 'how do I do a regex to do xxx' on the list, you'll have to figure it out or look for help elsewhere. So i will continue to ask help on my thread here: Edited January 14, 2017 by Skalou Quote Link to comment Share on other sites More sharing options...
Galileo Posted January 16, 2017 Share Posted January 16, 2017 I am struggling with a MM cfg to disable all Strategia strategies. anybody have an example i can steal? if its possible? I'm asking because i am writing my own strategies for GPP and i just want to use Strategia as the framework. I understand the basics of Module Manager but not enough to just make the changes needed, I would rather just write my own and disable the default ones in Strategia If i need to take this elsewhere, I will so i don't clog up this already busy thread. or just pm me. Thanks in advance Quote Link to comment Share on other sites More sharing options...
Aelfhe1m Posted January 17, 2017 Share Posted January 17, 2017 (edited) 21 hours ago, Galileo said: I am struggling with a MM cfg to disable all Strategia strategies. anybody have an example i can steal? if its possible? I'm asking because i am writing my own strategies for GPP and i just want to use Strategia as the framework. I understand the basics of Module Manager but not enough to just make the changes needed, I would rather just write my own and disable the default ones in Strategia If i need to take this elsewhere, I will so i don't clog up this already busy thread. or just pm me. Thanks in advance If you want to nuke everything and start from the ground up then use this but afterwards you'd need to redefine everything: // remove default strategia strategies !STRATEGY[*]:AFTER[Strategia] {} !STRATEGY_BODY_EXPAND[*]:AFTER[Strategia] {} !STRATEGY_LEVEL_EXPAND[*]:AFTER[Strategia] {} !CONTRACT_TYPE[STG_*]:AFTER[Strategia] {} Edited January 17, 2017 by Aelfhe1m Fixed after testing Quote Link to comment Share on other sites More sharing options...
Sigma88 Posted January 17, 2017 Share Posted January 17, 2017 59 minutes ago, Aelfhe1m said: If you want to nuke everything and start from the ground up then use this but afterwards you'd need to redefine everything: // remove default strategia strategies !STRATEGY[*]:AFTER[Strategia] {} !STRATEGY_BODY_EXPAND[*]:AFTER[Strategia] {} !STRATEGY_LEVEL_EXPAND[*]:AFTER[Strategia] {} !CONTRACT_TYPE[STG_*]:AFTER[Strategia] {} Does mm allow to create new root nodes using :AFTER[MOD] ? because I thought it did not allow that Quote Link to comment Share on other sites More sharing options...
Galileo Posted January 17, 2017 Share Posted January 17, 2017 14 minutes ago, Sigma88 said: Does mm allow to create new root nodes using :AFTER[MOD] ? because I thought it did not allow that yeah that the issue im having now Quote Link to comment Share on other sites More sharing options...
Aelfhe1m Posted January 17, 2017 Share Posted January 17, 2017 @Sigma88 and @Galileo I hadn't considered that aspect. However you can work around it. One way would be to delete each individual Stategia value by name like in Strategia's own StockStrategyDisabler config or you could use a guard variable in your own new strategies and alter the delete statements to skip any nodes with that variable (please excuse the stupid example): // define a new strategy STRATEGY { name = HotShots protectedStrategy = true // this is the important line with the guard variable title = Hot Shots desc = For people that really like messing about in high performance vehicles. department = Crewed Missions } // remove default strategia strategies !STRATEGY[*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} !STRATEGY_BODY_EXPAND[*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} !STRATEGY_LEVEL_EXPAND[*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} !CONTRACT_TYPE[STG_*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} Spoiler Quote Link to comment Share on other sites More sharing options...
Galileo Posted January 17, 2017 Share Posted January 17, 2017 1 minute ago, Aelfhe1m said: @Sigma88 and @Galileo I hadn't considered that aspect. However you can work around it. One way would be to delete each individual Stategia value by name like in Strategia's own StockStrategyDisabler config or you could use a guard variable in your own new strategies and alter the delete statements to skip any nodes with that variable (please excuse the stupid example): // define a new strategy STRATEGY { name = HotShots protectedStrategy = true // this is the important line with the guard variable title = Hot Shots desc = For people that really like messing about in high performance vehicles. department = Crewed Missions } // remove default strategia strategies !STRATEGY[*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} !STRATEGY_BODY_EXPAND[*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} !STRATEGY_LEVEL_EXPAND[*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} !CONTRACT_TYPE[STG_*]:HAS[~protectedStrategy[]]:AFTER[Strategia] {} Hide contents this is perfect thanks! Quote Link to comment Share on other sites More sharing options...
Pappystein Posted January 17, 2017 Share Posted January 17, 2017 I am working to add some items to a mod's existing CFG files via MM during game load. These are not standard parts or Global resources as defined by Squad but rather, external data points in a .cfg file. The CFG file is structured similar to a list of Modules and I am trying to add more of these "modules" Two questions, to extend this list, could I just do the following and have it run after MOST of the other MM files have already parsed? +ResourceDevice:FINAL { @ResourceDeviceName = UniqueResourceGroupName RESOURCE { resource = FirstUniqueResource ratio = 1 } RESOURCE { resource = SecondUniqueResource ratio = 3.75 } Second question is easy. How do I put the Hidden comments in? Quote Link to comment Share on other sites More sharing options...
Aelfhe1m Posted January 17, 2017 Share Posted January 17, 2017 11 minutes ago, Pappystein said: Second question is easy. How do I put the Hidden comments in? The spoiler button (looks like an eye) Spoiler Quote Link to comment Share on other sites More sharing options...
DerekL1963 Posted January 18, 2017 Share Posted January 18, 2017 A basic, and probably stupid question, I want to move a bunch of parts between tech tree nodes... @PART[fuelTank3-2] { TechRequired=start } Moves one part... But I can't seem to figure out how to include multiple parts in the same file. Laugh and point as you will, but then please enlighten me. Quote Link to comment Share on other sites More sharing options...
Merkov Posted January 18, 2017 Share Posted January 18, 2017 42 minutes ago, DerekL1963 said: A basic, and probably stupid question, I want to move a bunch of parts between tech tree nodes... @PART[fuelTank3-2] { TechRequired=start } Moves one part... But I can't seem to figure out how to include multiple parts in the same file. Laugh and point as you will, but then please enlighten me. I could be wrong, but unless the parts you want to move all have something in common that you can target by using the * filter, I think you have to do what you did above for each part you want to move. There's some documentation about halfway down this page that goes into details: https://github.com/sarbian/ModuleManager/wiki/Module-Manager-Handbook but I don't think those will help with what you're trying to do. Quote Link to comment Share on other sites More sharing options...
DerekL1963 Posted January 18, 2017 Share Posted January 18, 2017 3 hours ago, Merkov said: I could be wrong, but unless the parts you want to move all have something in common that you can target by using the * filter, I think you have to do what you did above for each part you want to move. No, they pretty much have nothing in common... I figured that I'd have to handle each part individually, but can't figure out how to format it. (I.E. have it all in one file rather than a bunch of files, one for each part.) Quote Link to comment Share on other sites More sharing options...
blowfish Posted January 18, 2017 Share Posted January 18, 2017 4 hours ago, DerekL1963 said: A basic, and probably stupid question, I want to move a bunch of parts between tech tree nodes... @PART[fuelTank3-2] { TechRequired=start } Moves one part... But I can't seem to figure out how to include multiple parts in the same file. Laugh and point as you will, but then please enlighten me. Few things You probably want @TechRequired = start since the part already has TechRequired. Otherwise it will just add another TechRequired value to the node (which one will take priority isn't well defined) You can put as many patches as you want in the same file, e.g. @PART[part1] { ...} @PART[part2] { ... } You can target multiple parts with the same patch. e.g. @PART[part1|part2|part3] { ... } (note that this syntax only works for top level nodes though) Alternately, there might be some identifying feature of all the parts you want to target. Then you can use a HAS block to filter them Quote Link to comment Share on other sites More sharing options...
DerekL1963 Posted January 18, 2017 Share Posted January 18, 2017 3 hours ago, blowfish said: Few things You probably want @TechRequired = start since the part already has TechRequired. Otherwise it will just add another TechRequired value to the node (which one will take priority isn't well defined) You can put as many patches as you want in the same file, e.g. @PART[part1] { ...} @PART[part2] { ... } You can target multiple parts with the same patch. e.g. @PART[part1|part2|part3] { ... } (note that this syntax only works for top level nodes though) Alternately, there might be some identifying feature of all the parts you want to target. Then you can use a HAS block to filter them So, for #2 like this (I am not a programmer of any sort...) @PART[part1] { ... } @PART[part2] { ... } I don't get #3 at all. Thanks! Quote Link to comment Share on other sites More sharing options...
blowfish Posted January 18, 2017 Share Posted January 18, 2017 6 hours ago, DerekL1963 said: So, for #2 like this (I am not a programmer of any sort...) @PART[part1] { ... } @PART[part2] { ... } Yes. No need to indent the brackets though 6 hours ago, DerekL1963 said: I don't get #3 at all. It would look like this: @PART[part1|part2] { .... } Notice the vertical bar | separating the names of parts. This patch will affect part1 and part2 Quote Link to comment Share on other sites More sharing options...
DerekL1963 Posted January 18, 2017 Share Posted January 18, 2017 Thanks much! Quote Link to comment Share on other sites More sharing options...
sarbian Posted January 21, 2017 Author Share Posted January 21, 2017 To whoever asked on IRC how to have all science part available from the start but did not wait for someone to answer : @PART[*]:HAS[@MODULE[ModuleScienceExperiment]]:Final { @TechRequired = start } Quote Link to comment Share on other sites More sharing options...
MacLuky Posted January 23, 2017 Share Posted January 23, 2017 Hi I want to add a 1.8m heatshield, something tells me this is super easy with mm (as apposed to copy paste of stock files) but I can't get it to work, any examples? regards Chris Quote Link to comment Share on other sites More sharing options...
linuxgurugamer Posted January 23, 2017 Share Posted January 23, 2017 41 minutes ago, MacLuky said: Hi I want to add a 1.8m heatshield, something tells me this is super easy with mm (as apposed to copy paste of stock files) but I can't get it to work, any examples? regards Chris Why don't you show us what you've tried and isn't working. Quote Link to comment Share on other sites More sharing options...
IronCretin Posted January 24, 2017 Share Posted January 24, 2017 I'm trying to rescale antenna ranges for a rescaled solar system, but it isn't working. Any advice? @PART[*]:HAS[@MODULE[ModuleDataTransmitter]]:NEEDS[Sigma]:FINAL { @description ^= :$:... Range adjusted (#$@SigmaDimensions/Rescale$x) ...: @MODULE[ModuleDataTransmitter] { @antennapower *= #$@SigmaDimensions/Rescale$ } } @CUSTOMBARNKIT:NEEDS[Sigma]:FINAL { @TRACKING { @DSNRange,* *= #$@SigmaDimensions/Rescale$ } } Quote Link to comment Share on other sites More sharing options...
garwel Posted January 24, 2017 Share Posted January 24, 2017 (edited) I think I'm making some silly mistake, but I can't make MM apply any patches. I'm testing it with a very simple modtest.cfg file: @PART[mk1Pod] { @mass = 3 } I put the file inside GameData folder, I have the latest ModuleManager dll there too. But when I launch KSP, the pod's mass remains the same. During the load, MM posts a message saying "0 patches applied". The log has this line, however: Config(@PART[mk1Pod]) /modtest/@PART[mk1Pod] What am I doing wrong? EDIT: Output log Edited January 24, 2017 by garwel 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.