The film's elaborate plot gradually reveals that extraterrestrial beings enslaved parts of the human civilization, and used the Stargate device to trap them in their home planets across the galaxy.