Given the sentence:
Er stieß seinen Kameraden gegen den Baum, dass dieser zitterte.
Can one determine exactly who/what it was, that was shivering?
No, sentences such as this can't be unambiguously formed. The relation of dieser remains to be determined by context. If we only had this sentence, both the tree or the buddy could shake.
If we need to make that clear we would have to introduce missing context, e.g. by adding:
Er stieß seinen Kameraden gegen den Baum, dass dieser bis in die Krone zitterte.
In this very example the shaking part becomes humble if we refer it to something with the buddy. Hence we can assume that zittern may likely refer to the tree rather than to the buddy. But it is not 100% certain.
Alternatively we can reorder the sentence to avoid an ambiguous relative clause:
Der Baum zitterte, als er seinen Kameraden gegen ihn stieß.