
Is it possible for a game to present an interesting challenge, yet fit in 1K of RAM? As evidence that the answer is “yes,” I offer Widget, a relative of the games Hammurabi and Lemonade Stand, in which the player allocates his resources for the best effect. As the player, you are the head of the United Widget Company, trying to expand your business as rapidly as possible without going broke.
You start out with one plant and $90,000. A plant is capable of producing as many as 1000 widgets a month, which will sell for $10 each. The monthly fixed overhead is $4000, including the mortgage cost for your first plant. In addition, it costs $5 per widget to produce any widgets in excess of the first hundred. To sell any widgets, you have to advertise. Naturally, the return on advertising isn’t entirely predictable, but you have to learn how much to spend in order to sell what you produce at a profit.
The key to making money is buying more plants. A plant costs $100,000 to buy and $2000 a month to maintain, and it lets you produce another thousand widgets a month. This means more fixed cost and more need for advertising; it also means economies of scale. You’ll notice that as production increases, it takes more advertising dollars to sell each widget. On the other hand, if you keep a steady flow coming out of your plants, each month’s sales will produce a carry-over effect into the next month.
With these costs in mind, you can start playing Widget. Each turn represents one month. At the start of the turn, the screen shows your current cash balance, number of plants, and inventory. If you have at least $100,000, you are asked, “Buy a plant?” To buy a plant, answer “Y” (just the one letter); anything else means “no.”
Next (or first, if you had less than $100,000), the program asks for your ad budget. Enter the number of thousands of dollars that you want to spend on ads; for example, to spend $4000, enter “4.” You will be asked again for input if you try to spend more than you have.
Finally you are asked how many widgets you want to produce. Enter the number of hundreds of widgets you want to produce, remembering that each plant can only produce 1000 widgets. Again, the program won’t let you go until you’ve entered a legal number.
The advertising cost is then subtracted from your cash balance, sales are determined, revenue comes in, and then the other costs are subtracted. If you can’t meet your costs, the message “You are bankrupt” appears, and the game is over. Otherwise, the program goes on to the next month.
Before starting, decide how many months you’re going to play. Sixty turns (5 years) or 120 turns (10 years) make a good game. Keep score by calculating your company’s net worth, which is its cash balance plus $100,000 per plant. There isn’t any predetermined winning score, but the outcome of a fairly well-played game would be to have 5 plants and $50,000 or more at the end of 10 years.
5 RANDOMIZE
6 LET Z = 1
10 LET P = 1
20 LET M = 990
30 LET I = 0
40 LET S = 10
100 CLS
110 PRINT "MONTH" ,Z
120 LET Z = Z + 1
300 PRINT "YOU HAVE" , "$" ;M; "00"
310 PRINT ,P;" PLANTS"
320 PRINT ,I;"00 WIDGETS"
330 PRINT "LAST MONTH YOU
SOLD ";5; "00"
350 IF M < 1000 THEN GO TO 410
360 PRINT "BUY A PLANT?"
370 INPUT Y$
380 IF NOT Y$ = "Y" THEN GO TO 410
390 LET P = P + 1
400 LET M = M - 1000
410 PRINT "AD BUDGET IN 1000S ?"
420 INPUT B
430 IF B * 10 > M THEN GO TO 420
440 LET M = M - B * 10
450 PRINT "PRODUCTION IN 100S ?"
470 INPUT W
480 IF W > 10 * P THEN GO TO 470
490 LET I = I + W
500 LET S = S / (RND (3) + 3)
510 IF B < 6 THEN GO TO 550
520 LET S = S + (B - 6) * 5
530 LET B = 6
550 IF B < 2 THEN GO TO 600
560 LET S = S + (B - 2) * 7
570 LET B = 2
600 LET S = S + B * B
610 IF S > I THEN LET S = I
620 LET M = M + S * 10
630 LET I = I - S
640 LET M = M - 20 * P - 20
650 LET M = M - (W - 1) * 5
660 IF NOT M < 0 THEN GO TO 100
800 PRINT "YOU ARE BANKRUPT."
MONTH 1
YOU HAVE $90000
1 PLANTS
000 WIDGETS
LAST MONTH YOU SOLD 1000
AD BUDGET IN 1000S?
MONTH 29
YOU HAVE $101000
1 PLANTS
000 WIDGETS
LAST MONTH YOU SOLD 1300
BUY A PLANT?
MONTH 61
YOU HAVE $71000
2 PLANTS
200 WIDGETS
LAST MONTH YOU SOLD 1900
AD BUDGET IN 1000S?
MONTH 85
YOU HAVE $50000
3 PLANTS
000 WIDGETS
LAST MONTH YOU SOLD 3600
AD BUDGET IN 1000S?
MONTH 121
YOU HAVE $53000
5 PLANTS
600 WIDGETS
LAST MONTH YOU SOLD 5300
AD BUDGET IN 10000S?
Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.