Java script into c#? please help me im stuck.... (solved)

Hi HetIsKane, please use Code Tags when posting code: Using code tags properly

When you destroy an object you also destroy everything else associated with that object, including its transform. Either call Destroy after instantiating your logs or save the transform’s position in a variable and use that instead:

Vector3 treePos = tree.transform.position;
Destroy(tree);
...
Instantiate(logs, treePos + Vector3(0, 0, 0) + position, Quaternion.identity);