It's like they made stupid moves to lure the NK into the open to gloat. Suicidal Dothraki cavalry charge? No arrow volleys? Siege engines on the front lines?
Why? They are on the defensive, not ofensive. They should have spammed those burning rocks, but they stopped to prevent collateral to the cavalry, that should not have been there in the first place. After they are all slaughtered (no surprise there), the infrantry gets quickly overwhelmed and everyone has to retreat into a bottleneck that is the castle main gate.
Then, the Unsullied (Dany's Elite troops) has to sacrifice themselves to cover their escape. And when the entire castle is surrounded, they lit up the trench that is waaay too thin and shallow, that they just pass through using some bodies as bridges. The dragonglass shards at the walls high machinolations are useless because the wights are climbing throught the lower ones that doens't have shards, wtf?