Closernow. %llu was the issue. In this context it is looking for the STEAM_ID which I was able to get from the environment variables while spacewar was running. Replacing the %llu with the steam id gave better results!
Spacewar! is a space combat video game developed in 1962 by Steve Russell in collaboration with Martin Graetz, Wayne Wiitanen, Bob Saunders, Steve Piner, and others. It was written for the newly installed DEC PDP-1 minicomputer at the Massachusetts Institute of Technology. After its initial creation, Spacewar! was expanded further by other students and employees of universities in the area, including Dan Edwards and Peter Samson. It was also spread to many of the few dozen installations of the PDP-1 computer, making Spacewar! the first known video game to be played at multiple computer installations.
The game features two spaceships, "the needle" and "the wedge", engaged in a dogfight while maneuvering in the gravity well of a star. Both ships are controlled by human players. Each ship has limited weaponry and fuel for maneuvering, and the ships remain in motion even when the player is not accelerating. Flying near the star to provide a gravity assist was a common tactic. Ships are destroyed when they collide with a torpedo, the star, or each other. At any time, the player can engage a hyperspace feature to move to a new and random location on the screen, though in some versions each use has an increasing chance of destroying the ship instead. The game was initially controlled with switches on the PDP-1, though Bob Saunders built an early gamepad to reduce the difficulty and awkwardness of controlling the game.
Spacewar! is one of the most important and influential games in the early history of video games. It was extremely popular in the small programming community in the 1960s and the public domain code was widely ported to and recreated on other computer systems at the time, especially after computer systems with monitors became more widespread towards the end of the decade. It has also been recreated in more modern programming languages for PDP-1 emulators. It directly inspired many other video games, such as the first commercial arcade video games, Galaxy Game and Computer Space (both from 1971), and later games such as Asteroids (1979). In 2007, Spacewar! was named to a list of the ten most important video games in history, which formed the start of the game canon at the Library of Congress, and in 2018 it was inducted into the World Video Game Hall of Fame by The Strong and the International Center for the History of Electronic Games.
During the 1950s, various computer games were created in the context of academic computer and programming research and for demonstrations of computing power, especially after the introduction later in the decade of smaller and faster computers on which programs could be created and run in real time as opposed to being executed on a schedule. A few programs, however, were intended both to showcase the power of the computer they ran on and as entertainment products; these were generally created by undergraduate and graduate students and university employees, such as at the Massachusetts Institute of Technology (MIT), where staff and students were allowed on occasion to develop programs for the TX-0 experimental computer.[1] These interactive graphical games were created by a community of programmers, many of them students and university employees affiliated with the Tech Model Railroad Club (TMRC), led by Alan Kotok, Peter Samson, and Bob Saunders. The games included Tic-Tac-Toe, which used a light pen to play a simple game of noughts and crosses against the computer, and Mouse in the Maze, which used a light pen to set up a maze of walls for a virtual mouse to traverse.[1][2][3]
The gameplay of Spacewar! involves two monochrome spaceships called "the needle" and "the wedge", each controlled by a player, attempting to shoot one another while maneuvering on a two-dimensional plane in the gravity well of a star, set against the backdrop of a starfield.[2][4] The ships fire torpedoes, which are not affected by the gravitational pull of the star. The ships have a limited number of torpedoes and supply of fuel, which is used when the player fires the ship's thrusters.[6] Torpedoes are fired one at a time by flipping a toggle switch on the computer or pressing a button on the control pad, and there is a cooldown period between launches. The ships remain in motion even when the player is not accelerating, and rotating the ships does not change the direction of their motion, though the ships can rotate at a constant rate without inertia.[2]
Each player controls one of the ships and must attempt to shoot down the other ship while avoiding a collision with the star or the opposing ship. Flying near the star can provide a gravity assist to the player at the risk of misjudging the trajectory and falling into the star. If a ship moves past one edge of the screen, it reappears on the other side in a wraparound effect. A hyperspace feature, or "panic button", can be used as a last-ditch means to evade enemy torpedoes by moving the player's ship to another location on the screen after it disappears for a few seconds, but the reentry from hyperspace occurs at a random location, and in some versions there is an increasing probability of the ship exploding with each use.[6]
Player controls include clockwise and counterclockwise rotation, forward thrust, firing torpedoes, and hyperspace.[6] Initially, these were controlled using the front-panel test switches on the PDP-1 minicomputer, with four switches for each player, but these proved to be awkward to use and wore out quickly under normal gameplay, as well as causing players to accidentally flip the computer's control and power switches. The location of the switches also left one player off to one side of the CRT display due to the limited space in front of the computer, which left them at a disadvantage.[2] To alleviate these problems, Saunders created a detached control device, essentially an early gamepad.[7][8] The gamepad had a switch for turning left or right, another for forward thrust or hyperspace, and a torpedo launch button. The button was silent so that the opposing player would not have a warning that the player was attempting to fire a torpedo during a cooldown period.[2]
Russell, Graetz and Wiitanen developed the basic Spacewar! concept in the summer of 1961, in anticipation of the PDP-1 being installed.[4] Russell had recently finished reading the Lensman series by E. E. "Doc" Smith and thought the stories would make a good basis for the program. "His heroes had a strong tendency to get pursued by the villain across the galaxy and have to invent their way out of their problem while they were being pursued. That sort of action was the thing that suggested Spacewar!. He had some very glowing descriptions of spaceship encounters and space fleet maneuvers."[5] Other influences cited by fellow programmer Martin Graetz include E. E. Smith's Skylark novels and Japanese pulp fiction tokusatsu movies.[9]
The initial version of the game also did not include the central star gravity well or the hyperspace feature; they were written by MIT graduate student and TMRC member Dan Edwards and Graetz respectively to add elements of a strategy to what initially was a shooter game of pure reflexes.[2][4] Russell had previously wanted to add gravity, but was unable to get the program to perform the calculations fast enough; Edwards optimized the drawing functions to free up processing time to calculate the effects of gravity.[15] The initial version of the hyperspace function was limited to three jumps, but carried no risk save possibly re-entering the game in a dangerous position; later versions removed the limit but added the increasing risk of destroying the ship instead of moving it. Additionally, in March 1962, Saunders created gamepads for the game, to counter "Space War Elbow" from sitting hunched over the mainframe toggles.[2][4] The game was a multiplayer-only game because the computer had no resources left over to handle controlling the other ship.[7][16] Similarly, other proposed additions to the game such as a more refined explosion display upon the destruction of a spaceship and having the torpedoes also be affected by gravity had to be abandoned as there were not enough computer resources to handle them while smoothly running the game.[2] One feature, having the speed and direction of torpedoes differ slightly with each shot, was added and then removed by Russell after player complaints.[15] With the added features and changes in place, Russell and the other programmers shifted focus from developing the game to preparing to show it off to others such as at the MIT Science Open House at the end of April 1962.[2][10][17][18] The group added a time limit, the hyperspace function, and a larger, second screen for viewers at the demonstration, and in May Graetz presented a paper about the game, "SPACEWAR! Real-Time Capability of the PDP-1", at the first meeting of the Digital Equipment Computer Users' Society.[2][19] The demonstration was a success, and the game proved very popular at MIT; the laboratory that hosted the PDP-1 soon banned play except during lunch and after working hours.[2][20] Visitors such as Frederik Pohl, the editor of Galaxy Science Fiction, enjoyed playing the "lovely game" and wrote that MIT was "borrowing from the science-fiction magazines", with players able to pretend to be Skylark characters.[21]
Beginning in mid-1962 and continuing over the next few years, members of the PDP-1 programming community at MIT, including Russell and the other Hingham Institute members, began to spread out to other schools and employers such as Stanford University and DEC, and as they did they spread the game to other universities and institutions with a PDP-1 computer.[2][7][19] As a result, Spacewar! was perhaps the first video game to be available outside a single research institute.[22] Over the next decade, programmers at these other institutions began coding their own variants, including features such as allowing more ships and players at once, replacing the hyperspace feature with a cloaking device, space mines, and even a first-person perspective version played on two screens that simulates each pilot's view out of the cockpit.[5][6] Some of these Spacewar! installations also replicated Saunders' gamepad.[23] DEC learned about the game soon after its creation, and gave demonstrations of it running on their PDP-1, as well as publishing a brochure about the game and the computer in 1963.[19] According to a second-hand account heard by Russell while working at DEC, Spacewar! was reportedly used as a smoke test by DEC technicians on new PDP-1 systems before shipping because it was the only available program that exercised every aspect of the hardware.[13][23] Although the game was widespread for the era, it was still very limited in its direct reach: while less expensive than most mainframe computers, the PDP-1 was priced at US$120,000 (equivalent to about $1,209,000 in 2023) and only 53 were ever sold, most without a monitor and many of the remainder to secure military locations or research labs with no free computer time, which prevented the original Spacewar! from reaching beyond a narrow, academic audience.[7][19][23] Though some later DEC models, such as the PDP-6, came with Spacewar! pre-loaded, the audience for the game remained very limited; the PDP-6, for example, sold only 23 units.[8][24]
3a8082e126