I am trying to create an entity and bind it to the back of a MiniCopter. The following code works perfectly fine and the flamethrower is in the correct position and rotation up untill the "SetParent()" function. This function rotates the flamethrower and I can no longer change the localPosition, position, localRotation, or rotation but it follows the mini properly. It feels like I've tried everything.
trail = GameManager.server.CreateEntity(FlameEnt, mini.transform.position + new Vector3(0.0f, 0.8f, -1.0f), Quaternion.Euler(0f, 75f, 180f));
if (trail != null)
{
trail.SetParent(mini);
trail.transform.localPosition = new Vector3(0.0f, 0.8f, -1.0f); // doesn't do anything
trail.transform.localRotation = new Quaternion(0,0,0,0); // doesn't do anything
trail.Spawn();
trail.SendNetworkUpdateImmediate(true);
}