SLG Movement – No path generated due to creating two Chess in same Layout

This title is pretty lengthy due to the specificity of the problem.

The issue stems from SLG Movement’s failure to generate a path. This is rooted in the wrong Board placement of the Chess (which, in this case, is meant to refer to the mover), which, specifically, is having two or more instances of the Chess in the same Layout.

This happens when the Board’s Action:Create chess is executed on the same Layout where the Chess mover exists. This instantiates another copy of Chess. I think this fine, but when SLGMovement’s Action:Get moving path is called, and if the Chess is not unambiguously picked (SOL), then it will use the first Chess, which is not really assigned to the Board.

I noticed this particularly in Rex’s example capx where he puts the ‘resources’ — eg exemplar Sprites — into a separate Layout.

I think having a ‘resources’ Layout is good practice, however, this should only be used for Sprites intended for instancing, as those directly manipulated will not be visible in the current Layout if they are manually set in the ‘resources’ one.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s