Cameron Dream

"...Cameron was stricken with food poisoning. During his illness, Cameron had a nightmare about an invincible robot hitman sent from the future to kill him, giving him the idea for The Terminator, which later catapulted his film career."

https://en.wikipedia.org/wiki/James_Cameron

https://krz-an-avatar-story.wikia.com/wiki/Some_History