In Hamlet they just put on a play and watch the king’s reactions to watching his own act, but with modern or future tech that would be replaced with playing a video (or virtual reality holodeck) game where the murder was a potential option, then reading the datalogs.