Jump to content

[1.1.2] Kerbal Inventory System (KIS) 1.2.12


KospY

Recommended Posts

Full exception is:


[FONT=monospace][COLOR=#000000][EXC 17:46:41.119] NullReferenceException: Object reference not set to an instance of an object[/COLOR]
KIS.ModuleKISInventory.[COLOR=#ffffff]UpdateKey[/COLOR][COLOR=#000000] ()[/COLOR]
KIS.ModuleKISInventory.Update ()

The mod is de-referencing a null pointer, pointers should *always* be checked before first access, which is not being done in this code. ;-)

Not the full exception, the full log. That gives a lot more context for the problem, especially in KSP/unity where errors elsewhere can have odd effects in completely unrelated areas.

Link to comment
Share on other sites

pointers should *always* be checked before first access, which is not being done in this code. ;-)

Not really. You often want to arrange your program so that you can expect most refs to be non-null, and if one happens to be null, then the error is often someplace else. However, as you say, sometimes you discover that a ref might be null by design, which is when you add a null-check.

Edited by LostOblivion
Link to comment
Share on other sites

The mod is de-referencing a null pointer, pointers should *always* be checked before first access, which is not being done in this code. ;-)

It's not a pointer... but anyway, what would you do when you find a null reference? You throw an exception. But there's no point manually checking and then manually throwing an exception, the CLR does all that on its own anyway. So unless you want to specifically handle cases of null references differently, there's no point in a duplicate check.

Don't try to apply design rules of your favorite language to another runtime environment without learning more about it first.

Link to comment
Share on other sites

I really love KIS. I could save lots of kerbals with it which would have died in space :D

The new large IMC-250 Container is also awesome for space station building in orbit. The design fits quite well I think. So I got the idea that the container would also be cool to have as a cargo bay which opens like the new stock cargo bays. It already looks like it could open the two sides :)

Link to comment
Share on other sites

I don't understand. When I use Bob (as his an engineer), and drag out a parachute and attach it to the ship I want it attached to, it says its part of Bob Kerman, and the parachute slowly float off the ship and off into space (at the same velocity and rotation as Bob had when he attached it. How do I fix this?

EDIT: Found it, need to help down X

Link to comment
Share on other sites

I would like to edit a save since I forgot to bring a wrench so my docking party. Where in the persistent file can I add the parts that are supposed to be in the inventory of a capsule?

Link to comment
Share on other sites

@Andy81le

Note that capsules can only carry items when a Kerbal occupies them. Technically it's the inventory of the Kerbal, however the items are still stored within the part, in the ModuleKISInventory module.

I suspect it'll be easier to hack this module in for a container than an occupied capsule though. And unless you're at Jool it'll probably take less time to bring up the screwdriver in an SC-62 container than to figure out the module structure though...

Good luck!

Link to comment
Share on other sites

I can't radially attach radial SAS from Ven's stock revamp. It says wrong node, with all 3 nodes it has.

Just started using this, so I'm learning. Been using KAS since 0.22 tho.

Link to comment
Share on other sites

Any mods have more than 20000L volume containers?

I just need 40000L for BDarmory CIWS.

OPTION A:

a) Go to: C:\Program Files\Steam\SteamApps\common\Kerbal Space Program\GameData\KIS\Parts\container2

B) Edit part.cfg with any text editor:

c) Change: maxVolume = 20000

to: maxVolume = 40000

d) Close file and restart KSP

OPTION B:

a) Copy part.cfg to a new file and rename it to parta.cfg

B) Use any text editor to change parta.cfg:

1. change "name =" to another name

2. change "title =" to a new title (makes it easier to spot in parts list)

3. change other entries as you see fit, including maxVolume.

4. Close editor and restart KSP

5. You'll now have the original part and your new mod.

Edited by Apollo13
Link to comment
Share on other sites

a) Go to: C:\Program Files\Steam\SteamApps\common\Kerbal Space Program\GameData\KIS\Parts\container2

B) Edit part.cfg with any text editor:

c) Change: maxVolume = 20000

to: maxVolume = 40000

d) Close file and restart KSP

Thx man.

Link to comment
Share on other sites

Hello,

first let me thank you for this helpful mod.

I seem to have a bug. whenever I equip a kerbal with items in the inventory and I pass through or EVA out off a KerbCan (PPD-2), all items are gone missing.

Found out the hard way, after arriving on the moon to repair a rover, bringing an engineer with everything needed for the repair.

This can be tested on the launch pad.

Link to comment
Share on other sites

It might be a repeat report but I have an item duplication bug regarding carried containers: Assuming wrench in Kerbal slot #1, carried container in Kerbal slot #2. Inside the container there is also an item (let's say the basic battery) in the container's slot #2. The Kerbal is on EVA near a container mount, "2" is pressed and "X" is held while the container outline is hovering in blue over the node attach point. LMB is pressed to complete the attachment of the container to the mount.

The result is that it is the battery from inside the container is attached to the mount instead of the container itself by virtue of the similarity in slot #. Additionally the placed item does not subtract from the container's inventory so one battery is now two batteries.

---

On a different front dragging and dropping parts with EVA RCS enabled can double as controlling the EVA reorient. If you made certain KIS actions restricted while the RCS joysticks are in hand it could steer users away from the mixed control situation while also being quite plausible (Kerbals need their hands free for tools and whatnot).

Link to comment
Share on other sites

On a different front dragging and dropping parts with EVA RCS enabled can double as controlling the EVA reorient. If you made certain KIS actions restricted while the RCS joysticks are in hand it could steer users away from the mixed control situation while also being quite plausible (Kerbals need their hands free for tools and whatnot).

I had noticed this too, but quickly learned to turn off the RCS upon arrival at the work site.

Link to comment
Share on other sites

I had noticed this too, but quickly learned to turn off the RCS upon arrival at the work site.

I was on one version ago. No longer an issue. [Enhancement] Disable jetpack mouse input while dragging

Link to comment
Share on other sites

waht happened to the connectors? i alwayus get situations that call for fixed mounting points, particularly with the insane power drain of the electromagnets.

Do you mean from KAS? They are still in KAS.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...