The Borg are one of the most popular antagonists from the Star Trek franchise and appear in several of the Star Trek games. Their most direct role so far has been in the crappy FMV game Star Trek: Borg, although a cancelled game, Star Trek: Borg Assimilator, would have featured the player in control of the villainous race in the form of an RTS, tasked with conquering the Alpha Quadrent. Players who bought a lifetime subscription to the MMORPG Star Trek Online were given the ability to play a character who was a former Borg drone liberated from the Collective.
In proper film and television Star Trek canon, the origin of the Borg is unknown. According to the wildly unpopular first Star Trek film, V'ger (one of the Voyager probes launched into space in our time) eventually travels through a black hole, comes to a planet inhabited by a machine-race, is refitted and improved, and better sent out to complete its mission. That simplistic mission being: to acquire what information it can from its journey, which it has, and then to relay that information back to its creator, which it has failed to understand is mankind. For years, Trek writers joked that this machine planet was the Borg homeworld, although this was never canon.
In the video game Star Trek: Legacy, the story of V'ger is used as a basis for the Borg's origin. The game explains that V'ger, unable to find out who its Creator could be, then regarded carbon-based life forms as an infestation of the Creator's universe. It then sets out to 'assimilate' all organic life, making it as much like itself and (it assumed) its Creator as possible in order to better suit the Creator's will.
The behaviour of the Borg involves methodical, almost binary routines of maintenance, assimilation and sleep. Former humanoids, their ultimate goal is to assimilate other humanoids into their massive Collective hivemind. They accomplish this by purposefully walking, taking physical hold of their victims and forcefully injecting "nanoprobes" into their bloodstream via sharp tubules that protrude from their arms. In a matter of seconds, the victim succumbs and is essentially a Borg. They do not speak or think individually, but only as a whole. When infected, consciousness becomes linked with the Borg collective. Upon meeting their victims, they preface their intrusion over communications by saying, "We are the Borg. You will be assimilated. Resistance is futile." This is not a threat, nor a warning, it is a suggestion not to waste energy or resources that could be used to serve the Borg.
Outside of the assimilating tubules in their arm, the Borg have no weapons on their person; likely because their ultimate goal is to assimilate and not destroy. However, they do have a very sophisticated form of shielding. After being struck only a few times by energy weapons fire , the Borg are able to adjust their shield modulation to match the phaser beam, rendering it useless. In order to penetrate this defence, phasers must repeatedly be set to a different modulation. The videogame Star Trek: Voyager: Elite Force introduced a weapon called the Infinity Modulator, I-Mod for short, that was constantly and randomly modulating the energy output of its beam, making it impossible for the Borg to adapt. Given the simplicity of the idea, it is astonishing that no one has ever come up with it in Star Trek canon.
The Borg travel in enormous cube-shaped vessels. Their organization is methodical and can be compared to that of a bee or ant-hive, with an ultimate Queen and many workers.