Timing chain replacement went wrong

Hey guys,
Hoping you can give me some clarification.

So recently I did a chain replacement on my beater/project car. 2005 toyota yaris mk1 1.0 vvti 16v it has the 1sz fe engine.

Now I’m a fairly experienced DIY but I’m still learning. This was my first timing chain hense why I did it on my beater car.

When I started it up the engine cranked a few times and I heard a metal on metal noise.

Now the crank will only rotate 180° hense the pistons have hit the valves.

I understand I will have to take off the cylinder head and assess the damage and will have to do a valve replacement on the broken valves however before I do this I’m trying to figure out where I went wrong.

When I put the new chain on I made absolutely sure that cyl 1 was TDC compression stroke and that all the timing marks lined up. I made sure that the gold links on the new timing chain lined up with the marks on the cam and crankshaft sprockets as per the haynes manual and rotated the engine a few times and it was all smooth.

The only thing that I can think of that could have gone wrong was at one point the woodruff key fell out and allowed the crankshaft to be rotated independently of the cams.

Some people have suggested it is possible for the crankshaft to be a full revolution (360°) out of time from the camshafts. (It is a DOHC engine) My understanding was that the individual rotation of the crankshaft is irrelevant as long as its in time because the pistons and crankshaft will be in exactly the same position per rotation of the crankshaft anyway. As in they occupy the exact same space two times during a 4 stroke cycle.

I just want clarification that this is the case. Is it the case that the individual rotation of the crankshaft only matters on certain engines? Or is my thinking correct and I’ve most likely got my TDC wrong etc?

Any help would be appreciated