Why do pinned objects become unpinned in functions? Let me explain by example.
I create two objects. Let's call them Donkey and Tail. Then I pin Tail to Donkey so that moving or rotating Donkey also causes Tail to move and rotate along with it. Great. So far so good.
OK, let's create a function to move any instance of any Donkey that is spawned. We create a function that is intended to handle all movement of any spawned Donkey. Let's call the function "MoveDonkey", and give it two parameters. The first parameter contains the UID of any given Donkey. The second parameter is the distance to move that Donkey along the X axis. So, to move Donkey, I simply call the function MoveDonkey and pass in the parameter Donkey.UID in Param(0) and an integer value representing how far I wish to move Donkey in Param(1). Within the MoveDonkey function I reference the Donkey instance by calling Donkey's "Pick instance with UID Function.Param(0)". Once picked, I can use Set X on Donkey to Donkey.X+Param(1). This moves Donkey forward or back along the X axis. Works great. So far so good.
Here's the problem. Inside the MoveDonkey function, Tail has become unpinned from Donkey. Outside of the function, when I move Donkey the Tail moves along with it. But inside the function, the Tail no longer moves with Donkey. It has become unpinned within the context of the function. Why is that and how do I resolve this problem? Do I need to re-pin the Tail on the Donkey within functions?
EDIT: After further testing, I can confirm this is nothing to do with functions. Forget everything I said about functions. The problem occurs with the "Pick by unique ID" event. Apparently, using this event to pick an object and then moving or rotating that object will not move or rotate objects pinned to it. Still don't know why.