Twitchi Posted November 2, 2017 Share Posted November 2, 2017 (edited) @Aelfhe1m Thanks very much dude.. I will defiantly keep in mind the white space thing, going through all your fixes I started from the bottom first (cos I'm sooo random ) and turns out the data node was the only thing I needed to remove No idea as to the reason why yet.. just doing stuff and seeing what happens.. I'll figure correlation at some point next "issue" that I am honestly not sure if it is even doable or not.. so I want the player to kill Jeb.. horrific I know, But I have had enough of his front seat jumping ways. In the params I thought I could make this happen by having a NOT param around the HasAstronaught unfortunately this just gives me the standard kill jeb to lose scenario, the opposite of what I want any ideas on how to do this? Edit : small caffeine break inspired me to try this without the "completeInSequence = true" despite the wiki saying this is important.. its not, it does in fact stop it working as I intended Edited November 2, 2017 by Twitchi Quote Link to comment Share on other sites More sharing options...
chrisl Posted November 2, 2017 Share Posted November 2, 2017 I'm looking at the RP-0 (v0.54) "LifeSupportStation". I have two stations in my career game: Skylab orbiting Earth and Salyut-7 orbiting the Moon. The Salyut-7 station is currently unoccupied and has at least 75% of it's starting life support resources, but my Skylab station is starting to run low. Right now it's down to 16% food, 30% water and 77% oxygen. But the "LifeSupportStation" contract will not come up as an option. So I pulled up the contract to try and figure out what the issue was. I'm pretty sure I see the first problem. There is a DATA type setup as follows: DATA { type = Vessel requiredValue = true uniquenessCheck = GROUP_ACTIVE targetVessel1 = AllVessels().Where(v => v.VesselType() == Station && v.FreeDockingPorts()>0 && (v.ResourceCapacity(Food) / v.ResourceQuantity(Food))>0.26 || (v.ResourceCapacity(Water) / v.ResourceQuantity(Water))>0.26 || (v.ResourceCapacity(Oxygen) / v.ResourceQuantity(Oxygen))>0.26).SelectUnique() title = Must have an open Docking Port and 25% or less of Life Support Supplies } The v.ResourceCapcity() and v.ResourceQuantity() pieces are wrong, I believe. As written, if the food capacity of my station is 5000 and I currently have 500 food, that's going to give a result of 5000 / 50 which is 100 and therefore "100 > 0.26" would absolutely be true. I'm pretty sure it needs to be rewritten as (v.ResourceQuantity()\v.ResourceCapacity()) < 0.26. However, when I do that, both stations become viable options and the amount of resources I'm supposed to being is always 0. There is a second DATA section which is supposed to calculate the amount of life support resources you need to take with you to complete the contract: DATA { type = int foodSpace = Round(@/targetVessel1.ResourceCapacity(Food) - @/targetVessel1.ResourceQuantity(Food)) waterSpace = Round(@/targetVessel1.ResourceCapacity(Water) - @/targetVessel1.ResourceQuantity(Water)) oxygenSpace = Round(@/targetVessel1.ResourceCapacity(Oxygen) - @/targetVessel1.ResourceQuantity(Oxygen)) title = Get empty space for Life Support } No matter what I do, those three variables (foodSpace, waterSpace and oxygenSpace) are always set to 0. I've tried changing the DATA type to double since that is apparently what ResourceCapacity and ResourceQuantity are supposed to return but that had no effect. I tried removing the Round() function but that didn't help. I'm assuming that the first DATA type is actually getting some kind of results for ResourceCapacity and ResourceQuantity since the contract doesn't return a divide by 0 error. Can you take a look at this contract and see what might be the problem? Quote Link to comment Share on other sites More sharing options...
Twitchi Posted November 3, 2017 Share Posted November 3, 2017 (edited) Hey guys.. so I have a situation where all the conditions are met for my contract to be offered, but alas I still am not able to take them. I used to think the cooldownDuration on the CompleteContract requirement might be to blame for this but after playing about have been convinced this is not so A bit of forum searching points me to some mythical RNG based selection process turning over in the background.. but is there any way to over ride this and make it immediately available? I'm typing this before going to bed and don't have the time to check right now but would turning off the other contracts (I forget which flag turns off contact groups right now) and having very few contracts to choose from be a dirty way to make this happen? Thanks for any assistance Edited November 3, 2017 by Twitchi forgot my manners :P Quote Link to comment Share on other sites More sharing options...
Electrocutor Posted November 3, 2017 Share Posted November 3, 2017 (edited) I've noticed that anytime there is an error in the scripting of a Contract Pack cfg file, the Contract Configurator goes ballistic with null refs and then starts randomly showing and hiding many contracts about every 5 seconds. One of my Contract Packs' contracts includes the following which causes it to go haywire. Does anyone know what's wrong with this line? targetBody1 = ReturnedFromBodies().Where(body => @/stations.Where(v => v.CelestialBody() == body).Count() == 0).SelectUnique() DATA { title = Find the stations stations = AllVessels().Where(v => v.VesselType() == Station) requiredValue = false type = List<Vessel> } The programmer in me says that Contract.stations is null when the player has not created any spacestations yet (instead of being a 0 count list), thus trying to execute a linq Where clause on it causes a nullref, but I've no experience with making contracts for CC, so perhaps that is not the case? Edited November 4, 2017 by Electrocutor Quote Link to comment Share on other sites More sharing options...
Waxing_Kibbous Posted November 6, 2017 Share Posted November 6, 2017 I'm having a similar problem, the contracts UI is very active, contracts are jumping in and out, I can occasionally click on them but sometimes can't accept them, even stock ones. The explore minmus one time to expire also counted down really fast. I have a lot of mods, but ScanSat and ReasearchBodies are the only two in the CC settings. I'm also on Linux so this could be a "punctuation matters" kind of an error in a pack. Quote Link to comment Share on other sites More sharing options...
Thygrrr Posted November 6, 2017 Share Posted November 6, 2017 (edited) Same issue with appearing and disappearing contracts here as well. So strange. Affected are Field Research and Bases and Stations. Edited November 6, 2017 by Thygrrr Quote Link to comment Share on other sites More sharing options...
New Horizons Posted November 6, 2017 Share Posted November 6, 2017 (edited) This latest Contract Configurator seems to collide with the way upgrade levels and Strategia mix up. On level 1 Administration permits 2 strategies at a time. Without installing this mod here and entering Administration of course you see no contracts but in the lower half of the window there are 2 strategies permitted. Installing that required mod Contract Configurator here, leads to only one permitted strategy, although the upgrade level still suggests 2 strategies. Is this known to anyone? Unfortunately I can not say, how this works with KSP 1.3.0. Earlier with KSP 1.2.2 it worked as expected. Edited November 6, 2017 by New Horizons Quote Link to comment Share on other sites More sharing options...
Electrocutor Posted November 10, 2017 Share Posted November 10, 2017 DATA { type = List<Vessel> requiredValue = false stations = AllVessels().Where(v => v.VesselType() == Station) title = Find the stations } DATA { type = CelestialBody requiredValue = false uniquenessCheck = CONTRACT_ACTIVE targetBody1 = ReturnedFromBodies().Where(body => @/stations.Where(v => v.CelestialBody() == body).Count() == 0).SelectUnique() title = Must have returned from a Celestial Body, but not have any stations deployed. } NullReferenceException: Object reference not set to an instance of an object ContractConfigurator.ExpressionParser.CelestialBodyParser.CheckTree (KSPAchievements.CelestialBodySubtree tree, ProgressItem pi) ... Rethrow as Exception: Error parsing statement. Error occurred near '*': ReturnedFromBodies().Where(body => @/stations.Where(v => v.CelestialBody() == body).Count() == 0).SelectUnique() ....................* <-- HERE If we assume that all LINQ Where clauses will return a list of count 0, the problem has to be that ReturnedFromBodies() is returning null instead of an empty list, right? Quote Link to comment Share on other sites More sharing options...
gamerscircle Posted November 11, 2017 Share Posted November 11, 2017 On 11/1/2017 at 7:25 PM, gamerscircle said: I think this is a known issue - There are contracts "stock I believe" that when I accept them, I see them at the space center [after leaving mission control] but when I go to another scene, that contract disappears. I do have a couple of other contract mods. Is there something that I need to do, in order to retain that stock contract or? My apologies for not keeping up. I didn't see any reply or query to this... I did go back and read through the last 4 pages of the forums and did not see anything similar. Quote Link to comment Share on other sites More sharing options...
Waxing_Kibbous Posted November 12, 2017 Share Posted November 12, 2017 (edited) On 11/6/2017 at 10:19 AM, Waxing_Kibbous said: I'm having a similar problem, the contracts UI is very active, contracts are jumping in and out, I can occasionally click on them but sometimes can't accept them, even stock ones. The explore minmus one time to expire also counted down really fast. I have a lot of mods, but ScanSat and ReasearchBodies are the only two in the CC settings. I'm also on Linux so this could be a "punctuation matters" kind of an error in a pack. It looks like my issue is caused by Research Bodies and/or Kerbal Health, if I remove one things are normal. I'm curious if other people with issues are also using RB/KH. Edited November 12, 2017 by Waxing_Kibbous Quote Link to comment Share on other sites More sharing options...
Electrocutor Posted November 12, 2017 Share Posted November 12, 2017 (edited) 21 hours ago, gamerscircle said: I didn't see any reply or query to this... I did go back and read through the last 4 pages of the forums and did not see anything similar. Make sure the contract actually still exists when you click accept. There is a very annoying bug that makes contracts appear and disappear randomly (sometimes very rapidly). If your contract happened to have disappeared at the moment when you clicked accept, it will not have actually been accepted. Even when a contract disappears, it still stays showing in the right pane if you had clicked on it earlier. Edited November 12, 2017 by Electrocutor Quote Link to comment Share on other sites More sharing options...
gamerscircle Posted November 12, 2017 Share Posted November 12, 2017 3 hours ago, Electrocutor said: Make sure the contract actually still exists when you click accept. There is a very annoying bug that makes contracts appear and disappear randomly (sometimes very rapidly). If your contract happened to have disappeared at the moment when you clicked accept, it will not have actually been accepted. Even when a contract disappears, it still stays showing in the right pane if you had clicked on it earlier. 1.) Go to mission control - accept contact 2.) Exit mission control, check at the Space Center - contract is still listed 3.) Enter VAB, check for contract - no longer available Quote Link to comment Share on other sites More sharing options...
Electrocutor Posted November 12, 2017 Share Posted November 12, 2017 4 minutes ago, gamerscircle said: 1.) Go to mission control - accept contact 2.) Exit mission control, check at the Space Center - contract is still listed 3.) Enter VAB, check for contract - no longer available I've not seen or heard of a disappearing bug like that mentioned anywhere; only odd completions and failures. If it happens again, I'd say grab your KSP.log and if not a stock contract, the log for the contract pack under GameData/ContractConfigurator/log; then drop them along with a description into https://github.com/jrossignol/ContractConfigurator/issues. Quote Link to comment Share on other sites More sharing options...
Damon Posted November 14, 2017 Share Posted November 14, 2017 On 12-11-2017 at 8:16 PM, Electrocutor said: I've not seen or heard of a disappearing bug like that mentioned anywhere; only odd completions and failures. If it happens again, I'd say grab your KSP.log and if not a stock contract, the log for the contract pack under GameData/ContractConfigurator/log; then drop them along with a description into https://github.com/jrossignol/ContractConfigurator/issues. I have the same problem. I don't use this mod tho. But my contracts are disappearing too whenever I go back to the VAB or the launchpad. Sometimes it does work, so it's hard to find which mod this causes. Quote Link to comment Share on other sites More sharing options...
WuphonsReach Posted November 14, 2017 Share Posted November 14, 2017 (edited) On 11/12/2017 at 10:26 AM, Electrocutor said: Make sure the contract actually still exists when you click accept. There is a very annoying bug that makes contracts appear and disappear randomly (sometimes very rapidly). If your contract happened to have disappeared at the moment when you clicked accept, it will not have actually been accepted. Even when a contract disappears, it still stays showing in the right pane if you had clicked on it earlier. I'll have to dig back through posts at the end of 2016 / start of 2017, but a lot of that is caused by contracts that are not written properly. For instance, there's a good way and a bad way to calculate the target body for your contract. Do it the bad way and CC will be constantly recalculating until it finds a contract. I've never had the issue with ResearchBodies contracts, but whichever contract pack that I use for ScanSAT and Bases & Stations have the issue. (I remember having to work through the issue when I was putting together Stock Antenna Balance contracts.) Edit 1: If you're digging through the post history, it's somewhere prior to page 150 where this is talked about it. I haven't found it yet, but I know it's discussed in this thread. Or maybe on the wiki... Edit 2: It's this post that distills some wisdom on how to properly pick a random target. Edited November 15, 2017 by WuphonsReach Quote Link to comment Share on other sites More sharing options...
Ruedii Posted November 16, 2017 Share Posted November 16, 2017 I've been having problems in recent version where Contract Configurator is expecting an integer for the last random seed and it is receiving a float. This is triggering an NRE, at least on Linux. I can isolate it, get a bug report, and make sure it is contract configurator and not a mod conflict.. Do you know a specifically "Clean" contract set I should use to test it? Quote Link to comment Share on other sites More sharing options...
Nik Power Posted November 26, 2017 Share Posted November 26, 2017 (edited) On 05.11.2017 at 7:20 PM, Jalaris said: I've found a bug: the launch your first vessel and gather scientific data from kerbin contracts no longer work with seti-contracts installed. You can see them, and you can accept them, but when you go to the VAB or launchpad, they disappear entirely and go back to the mission giver. Hi there! I'm having the same problem: Contracts of "Kerbal World Record-Keeping Society" like "Launch your First vehicle", "Gather Scientific data from Kerbin", "Explore Kerbin" can be accepted in Mission Control, but they disappear and can not be completed, when entering VAB/SPC Edited November 26, 2017 by Nik Power Quote Link to comment Share on other sites More sharing options...
sardia Posted November 26, 2017 Share Posted November 26, 2017 How do you disable certain types of contracts like parts testing after you don't want them anymore? I could only disable them as part of the game start setup but not afterwards. Quote Link to comment Share on other sites More sharing options...
Aelfhe1m Posted November 26, 2017 Share Posted November 26, 2017 @sardia Click the difficulty options button at the top of the settings window. This will give you access to most of the same settings that were available during game start. Quote Link to comment Share on other sites More sharing options...
TaxiService Posted November 27, 2017 Share Posted November 27, 2017 Hi nightingale, A couple of players reported a Reflection issue of Contract Configuration 1.23.3 against newly-released RemoteTech 1.8.9 on KSP 1.3.1. Here's my output_log file. Based on my investigation, the reflection issue seems to be due to the attributes of a new functionality added to RT 1.8.9. Here's the offending commit of RT codebase. I guess CC was compiled particularly against RT 1.8.8 and didn't expect the new attributes but I can hardly believe the reflection could fail against new attributes. If possible, please advise me on possible changes required to be make to RT codebase to resolve the reflection issue. Quote Link to comment Share on other sites More sharing options...
chrisl Posted December 1, 2017 Share Posted December 1, 2017 I think this is actually a Historic Missions: Contract Pack issue, and I have asked over there, but I'm hoping someone here might know. I'm playing 1.2.2 with RO/RSS/RP-0 and the Historic Missions pack. So far everything has gone just fine but recently I've starting running low on useful available contracts. I've currently got 5 active contracts (all 2 star) including Mariner 10, Viking 2 and STS-41B (all from historic missions). I've completed all the Apollo contracts, the ASTP contract, the Helios NASA contract as well as the first four Space Shuttle contracts. But I've never been offered the Pioneer 10 & 11 contracts, nor the Voyager 1& 2 contracts. As far as I can tell, I meet all the prerequisites to get those contracts, but they don't show in the list. Anyone have any idea what the issue might be? Quote Link to comment Share on other sites More sharing options...
inigma Posted December 8, 2017 Share Posted December 8, 2017 How can I set multiple needs to check for AirplanePlus and TweakScale? CONTRACT_TYPE:NEEDS[AirplanePlus] { I can check for one, but how do I add a second check? Quote Link to comment Share on other sites More sharing options...
AccidentalDisassembly Posted December 9, 2017 Share Posted December 9, 2017 1 hour ago, inigma said: How can I set multiple needs to check for AirplanePlus and TweakScale? CONTRACT_TYPE:NEEDS[AirplanePlus] { I can check for one, but how do I add a second check? Think you do NEEDS:[AirplanePlus,TweakScale,OtherMod,OtherMod] (I believe commas mean "AND" in context...) Quote Link to comment Share on other sites More sharing options...
WuphonsReach Posted December 9, 2017 Share Posted December 9, 2017 (edited) Question 1: Looking to build a contract that says "you must produce X units of Y" (and tracks how many units you have produced/consumed since acceptance of the contract). Very similar to the stock "RESOURCE_REQUEST {}" contracts, but done through CC. We have "HasResource" and "ResourceConsumption", but not something that tracks resource production over time (maybe "ResourcesConsumed"?). I could sort of get there with combining "duration" and "ResourceConsumption". Question 2: Also have trouble with this bit of code: Spoiler DATA { type = string title = What to harvest harvestResource = Ore } PARAMETER { name = ResourceConsumption type = ResourceConsumption title = Harvest at least @/harvestRate units per second of @/harvestResource resource = Resource(@/harvestResource) minRate = @/harvestRate * -1 } Not sure the global function works: resource = Resource(@/harvestResource) Question 3: Is there a way to create a list of resource types and pick one at random? Edited December 10, 2017 by WuphonsReach Quote Link to comment Share on other sites More sharing options...
AccidentalDisassembly Posted December 13, 2017 Share Posted December 13, 2017 On 11/14/2017 at 6:01 AM, damonvv said: I have the same problem. I don't use this mod tho. But my contracts are disappearing too whenever I go back to the VAB or the launchpad. Sometimes it does work, so it's hard to find which mod this causes. I have both this issue (I accept a contract in Mission Control, it shows up under the "Active" list, then go to the launchpad --> launch a ship, the contract no longer appears in my list) and the issue where contracts shuffle, appear, disappear, and change while in mission control. It's a constant thing. I tried it three times in a row with contracts asking me to rendezvous vessels in orbit of the Mun or Minmus - possibly from Exploration Plus? - and the same thing occurred each time. Meanwhile, contracts constantly appear and disappear while in Mission Control - doesn't *seem* to be only certain contracts from certain packs, just a constant recalculation of what contracts are offered, or something. Log: https://www.dropbox.com/s/13bfrfv30o4q9ur/output_logContractConfig.txt?dl=0 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.