Jump to content

fatcargo

Members
  • Posts

    388
  • Joined

  • Last visited

Everything posted by fatcargo

  1. If managed by mod, any bugs can be compensated for. So, completely separate tech trees can be a thing in KSP. Like geology, general phyiscs, structural engineering, fluid dynamics, biology, psychology, nanotech etc ... I'm hinting at the idea replacing current science system to prevent investing science in one branch to be used in another, keeping unrelated fields of study separate. One more thing : how are science points being kept separate by type, from generating by the science part to the last step when utilized in tech tree ?
  2. So, this mod can separate science points into types that can be later expended on specific nodes in tech tree... Could tech tree nodes be separated completely from main tech tree, in their own root nodes ? Yes, it would make them unresearchable from default research root, but with some additional code those could be unlocked and allow further research as expected.
  3. In my case for Science Relay, i had similar problem, but was able to kind of solve it. When i deployed a small science station around Mun i tried to send science data from a nearby satellite and it didn't work. So i turned on debug output and found that my station had 0 capacity to receive science (it has MPL lab module) and all science was sent back to original sources (the science parts that generated it). So i built a second module, launched it on SPH tarmac and tried to send science there and it worked. For unknown reason, my first station simply bugged out. I send an engineer to weld the science box part and it works now. Strange indeed. I did poke around in source, recompiled it with referencing KSP 1.11 assemblies and added some debug prints. Turns out finishTransfer() function in ScienceRelay.cs receives the vessel loaded argument as false, then it loops through all available science containers and ultimately fails, causing the "No valid science container for science" to show in debug log window. I can try to reproduce the bug, but this may be some edge case.
  4. Hoping to reignite the discussion (even by going slightly OT again) , i've looked at Modular Flight Integrator which is written as VesselModule that manages part aerodynamics and heating model. Link: I assume it is designed only for crafts moving in air medium (ie low Reynolds number), but i'm not entirely sure if it can do other things, like modeling part behaviour in liquid medium (ie high Reynolds number). If MFI can't be used to model part motion in liquids, is it possible to write a separate VesselModule plugin that can override stock fluid mechanics in KSP and perform its own calculations ? In the above linked old post discussing the "Analysis of the buoyancy of parts and how to improve things" it has in OP mention of If this still holds true (and i assume this wasn't addressed by Squad since their first release), a separate plugin to tackle this would be welcome.
  5. Thanks for the link, but beyond adding own modules to add ballast management and defining buoyancy for its own parts, it really does not address the issue en masse. There is still no clearly defined method to derive required parameters from part itself. The forum post i linked to does discuss about this, alas without definitive solution. Hence my post here. I'm hoping not to have hijacked (too much) of this thread to discuss this.
  6. How is buoyancy affected by this ? Is it even considered as a sideffect of calculations ? I'm not mentioning it in objective headspace since i have waited long for someone to solve this problem. There was an effort to fix it, but it required adding extra module/field in part cfg and manually tweak the value of each part. You can see this method got nowhere. I did try for several times to build a combination of quadcopter and a bathysphere that was winched up and down on a KAS cable. It worked to some depth (below cable limit) until the kraken, after which cable physics stopped working. The bathysphere had a small module {} added to a cockpit part to artifically add/remove mass. It looked as if when buoyancy forces were excessively different among parts on bathysphere, hell broke loose (only a modified cockpit had its mass changed, rest of part were untouched).
  7. To add my two cents, the visual damage can be done with code adapted from conformal decals mod . This way all impact can accumulate on surface and fit more or less nicely with surface. Oh and also this can add challenge to solar powered rovers on celestial bodies with dusty atmosphere (Opportunity rover survival challenge). As for impacts in interplanetary space, it can be expected to take craft cross-section area into probability calculation, but not all impact vectors point in direction of travel. There can always be impact from any direction and i don't know of any analysis / scientific paper describing distribution of matter in our solar system that can be used as starting point to make those calculations. I can only tell that the angle difference between impact vector and direction of travel does decrease as craft travels through space if its speed is approaching the average speed of particles defined for that particular volume of space. For example, in case of planetary rings, you can be fairly sure that particles travel in single plane and in same direction as it parent body rotation (i did say "fairly sure" since i'm not an astronomer). If you travel through them above their average speed, they will strike the craft "on the front".
  8. Uh-oh ! I completely forgot about "beam propulsion" - it is direction-dependant ! You could imagine it as trying to raise orbit using only ion engine. You need to fire the engine at the single point in orbit to get what is needed. This one will be tricky. Imagine using sail-like propulsion to drive TOWARD source of beam, that is contradiction.
  9. To add to above : also, if there is something wrong with code, all data will be in one place. It will be hard to match saved game state against custom data in separate file. Be aware of this. I had run into similar problem of saving state of my part and i analyzed the save and found the bug.
  10. I agree with @linuxgurugamer, this plugin can be a PartModule that saves the list of all connected transmitters or receivers (with respect to its receive/transmit type). One transmitter can have list of multiple receivers and a one receiver can only have one transmitter (unless some kind of list for fallback transmitters is added to compensate for loss of power due to lost line of sight, power failure or other disabling conditions). All save/load happens on OnLoad and OnSave which write into Persistent.sfs file that holds all save game config data.
  11. Irradiated ablative receiver propulsor (you are free to use the name ) is like a normal receiver that also expends ablator resource. The thrust for it can be somewhere between chemical rockets and ion engines (very wide range, i can't pinpoint it) but in game it should provide uniquely difficult use case - a orbital probe could carry only this part with mass of ablator resource and remotely receive energy (no need for heavy power generator) required to vaporize it, but since energy received can drop off drastically with distance, it may need a dedicated beam transmitter with a lot of power output.
  12. @Aniruddh one more idea about warp drive detection : you could list all parts in transmitter/receiver vessel for any warp drive part modules, check their fields and then let beam power mod decide. Now, this can easily blow up into a large list and make this mod unusable, but there may be a way to do it, at least gradually. You could add a list in config file describing quadruplet of module name, ksp field, value and action to be taken. Small fake example config : MODULE { name = WirelessSource //same for WirelessReceiverDirectional CONDITION { name = WarpDrive field = DriveState value=Engaged action = Disable } CONDITION { ...} } Each "CONDITION" node tells the plugin when and how to work. You can see how to access KSPField in other mods like Action Groups Extended, Kerbal Operating System and Mod Actions (this last one may be most relevant). Note that this node list can be used for anyhing else as well, not just warp drive mods.
  13. The speed detection could be a problem : crafts using warp drive mods to simulate speed above c may not actually move crafts at speed c For example alcubierre drive mod just make it easier to transfer craft in space, does not need c to do it. What can be done is to detect speed that is above limit and then take action. This limit can be written into mod config so it can be tweaked to something realistic/working. This also raises another interesting question : if there is a speed limit between transmitter and receiver, there may be situations where transfer breaks just because crafts with this mod parts orbit planets with large speed difference So do account for this too. Especially since there are mods that add alternative solar systems that can have planets with quite large speed differences. And please don't consider anything beyond this, at least at this stage, or mod development will get really complicated.
  14. For warp drive mods : they all have speed in common. There is no way around it. So you could simply test for speed and break power transfer if speed exceeds the limit, optionally could add redshift losses prior to breaking this connection. For jump gates : this is a bit more complicated, but i believe that they will generally cause vessel unload and a scene switch, maybe sudden relocation of active vessel so that can be accounted for as well.
  15. @Aniruddh if this is not too much to ask : there should be a feature to disable beamed power functionality in certain situations. Examples: 1. Disable power transfer for crafts that are moving at great velocity using warp drive modded parts 2. If there are dedicated transmitter/receiver pairs, and one of them is being instantly transferred via some kind of "jump gates" (like ESLD beacon mod) To elaborate it would be cheaty and could be explained in game to player as relativistic effects. I know these mods are sci-fi and are not much in same scope of realism as this mod, but please take this into consideration.
  16. @Nertea How much work it would be to use the feed/reflector code in this mod ? Would there be any quality-of-life improvements to justify implementing it into this mod ? Also, slightly off-topic, could the feed/reflector code be generalized to allow different uses, like for example solar furnaces or concetrated solar ?
  17. (Ab)using Commnet to get occlusion data is a good choice KSPIE features a complex dependancy on power efficiency so take care how realistic you want your mod to be. Directionality is interesting feature, but if you can make it optional for short range transmission networks it would work great for small planetary bases. How close to KSPIE wavelength dependancy do you plan to make your mod ? If i may suggest, make beam wavelength dependant on emitter and receiver diameter only for simplicity. Please comment. It is better to resolve this as soon as possible. Ahh also since you published plugin source, please consider moving it to https://github.com/ site so you can recveive bug reports, and patches.
  18. For me, adding "VolumeConfigs.user" made it work, i guess in plugin code didn't account for starting from scratch. I like the UI, hints explain everything and yellow highlight helps keep track of what is edited. As for some of requests for alternate setups that match resource requirements for other mods - that may be partially solved by defining a tank setups by mod makers themselves. If some XYZ LS mod needs food/water/oxygen, than an appropriate preset should be made either by mod author OR a player that needs this. BUT there is a difference to normal presets - these "source presets" (or "base presets" ?) should not be deletable or editable, should be defined as MM patches that are active only if such mod is present in GameData. These presets are only used to generate initial tank setups that can be later edited and saved by player under a different name.
  19. Hoooolly Kraken !!! MY TEST MODEL WORKED. It has a prefab built as "variant" from custom FBX imported model and a vanilla Diffuse shader with custom png texture. Next test is animation driving a custom shader (which is already proven to work since prefab holds a complete compiled shader, does not matter if it is built into KSP ). A noteworthy reminder : in my part config i set model with "mesh" value instead of MODEL{} node so model loading failed every time before i changed it to the above config style. One more thing : i've "discovered" BlendShapes. That thing is really something else. Pretty mych every inflatable part uses this method to show part inflating animation. I'll HAVE to try that next. Oh also i didn't have time to test the code, that's why this reply is soooo late. THANKS @xEvilReeperx , you pretty much wrote the entire plugin for me. This is something i don't see every day !
  20. Ok i think i've analyzed enough of the code to continue discussion. First off, i've got Textures Unlimited 1.5.8.23 from ShadowMage's github repo. Secondly, if there is a more appropriate thread to discuss this (so as to not unnecessarily divide/divert attention) do please point me to it. i've noticed that central part is in TexturesUnlimited-1.5.8.23\Plugin\SSTUTools\KSPShaderTools\Util\SMFBundleDefinitionReader.cs which contains attribute [DatabaseLoaderAttrib((new string[] { "smf" }))] Is "smf" an extension that will trigger this plugin to load it ? I'm not familiar with this attribute. Next, further in source there is local var List<Material> adjustedMaterials = new List<Material>(); which appears not to be used for anything. Materials get added to it and nothing else. And being local it is not usable by anything outside of setupModelTextures(). Maybe some kind of cache used in future ? Why is this asset loading method limited to single model only ? I ask because loading of multiple models from single assets file may have savings in reusing textures and shaders as well. I admit i don't have much expirience with assets beyond some (failed) experiments. Will look into this more. One more thing : in above mentioned forum discussion about assets and models you have used asset's XML file (ending in " _bundle.xml") which i think should be handled in TU plugin as it provides all resources listed by name and type (i personally like this and will use it when i try again to make my loader plugin). What does worry me is if i try to pack multiple files with same name (for example multiple models that use different textures in different directories but otherwise have same filename). And last : is there an example asset file that features a model, shader and texture ? I'd like to have a look at it.
  21. Ohh i've thought that putting the asset file inside GameData is enough so that KSP's loader would take care of the rest. I guess custom loader is still needed. Ok i'll review the post(s) and build this. Its late i'll try again tomorrow.
  22. Sorry to bother you again but i've failed after several variants. This is what i did as a starting point : 1. create empty GameObject, rename to "test" 2. create simple cube named "Cube" 3. drag cube in game object as child 2. create material (resides in "Materials" folder) 3. assign "KSP/Diffuse" shader to material 4. assign material to mesh renderer component of cube object, add PNG texture 5. create "Prefabs" folder in asset explorer 6. drag and drop "cube" object from inspector to "Prefabs" folder to create a prefab 7. select prefab in asset explorer and select AssetBundle as "new" and type "cube" 8. select from menu KSPAssets > Asset Compiler 9. click on "Build" in "cube" row (make sure "auto" is selected) 10. wait for build to complete and then copy "cube.ksp" into folder "ATestCube" inside "GameData" (size is about 0.5 MB, mostly because of texture) 11. in same "ATestCube" folder create "cube.cfg" text file with PART { //... mesh = Cube //... } 12. run KSP and it shows error, says "PartCompiler: Cannot clone model from 'ATestCube' directory as model does not exist", though log file says that "cube.ksp" asset is loaded I also tried with MODEL{} to try and target my model by path PART { // ... MODEL { model = Prefabs/test position = 0.0, 0.0, 0.0 } // ... } But it too failed with message "PartCompiler: Cannot clone model 'Prefabs/test' as model does not exist" So, how do i now reference my model in part config ?
  23. That ... that is GREAT ! It is almost like making a game myself, down to bare metal where i can do it right ! Again thanks !
  24. Thanks for the info. I will use this for models with complex animations. Though one thing still bugs me : what to do with cfg file ? It too needs to go into asset ? If i leave it in GameData, won't PartLoader try to load .mu model (which now resides in asset that i'll have to load later when my shader can be added to KSP), and then fail ? And if i have to load .cfg from asset, then MM won't be able to access it ? Does KerbalKonstructs do something like this ? I looked inside sources for KK and made a small shader loader plugin that was supposed to load shaders prior to PartLoader start and it failed to do anything. To paraphrase linked forum post - the earliest time to load a shader is at MonoBehaviour.Awake() when LoadedScene is MainMenu. What also bugs me how come PartLoader doesn't fail on models containing KSP shaders ? If original KSP shaders are loaded later on, original models should also fail ?
  25. Ok thread restart. I was trying to analyze where i made a mistake but had no luck. @xEvilReeperx question about building assets : is the following link ... ... still a valid method ? I did found one interesting thing : "GameData\Squad\squadcorefx.ksp" is most likely place where shaders are stored, and models have no problem using those assets at loading time. Why is same not true for custom made .ksp assets ?
×
×
  • Create New...