Quantcast
Channel: Programming (In-game)
Viewing all articles
Browse latest Browse all 645

IMyMechanicalConnectionBlock throw exception only when loading session

$
0
0
Hi o/

I face a strange behavior with IMyMechanicalConnectionBlock object.

Here's a code who works on function main() script; but not on program() only when call 1st time after loading a game, if I recompile after first exception all become fine again.


Code:
	// Identify and Rename Subgrids
	List<IMyMechanicalConnectionBlock> _MechConn = new List<IMyMechanicalConnectionBlock>();
	GridTerminalSystem.GetBlocksOfType<IMyMechanicalConnectionBlock>(_MechConn, x => SatisfyGridPolicy(x) &&...
IMyMechanicalConnectionBlock throw exception only when loading session

Viewing all articles
Browse latest Browse all 645

Trending Articles