It would be hard to do a nonlinear story if the ending is fixed, but one way to do it would to make the player be different characters in the scene depending on their choices, e.g. one ending has you as the murderer, another as the victim and another as a witness.
Of course you could simply have many ways of reaching a similar point, giving the event different context and motivation for the player, e.g. you slay the dragon because it killed your family, to rescue someone it holds captive or to get the bounty on it.