Got instance transform function working