|
Post by tsh73 on Dec 9, 2021 13:08:26 GMT -5
Wrap-around error then docking See Enterprise and base on opposite sides? But program made it docked
*** ENTERPRISE IS DOCKED AT STARBASE (SECTOR 3,1) *** *** SHIELDS DROPPED FOR DOCKING PURPOSES ***
DEVICE STATE OF REPAIR WARP ENGINES 100% SHORT RANGE SENSORS 100% LONG RANGE SENSORS 100% PHASER CONTROL 84% PHOTON TUBES 100% DAMAGE CONTROL SYSTEM 100% SHIELD CONTROL 100% LIBRARY-COMPUTER 100%
TECHNICIANS STANDING BY TO EFFECT REPAIRS TO YOUR SHIP; ESTIMATED TIME TO REPAIR: 0.13 STARDATES WILL YOU AUTHORIZE THE REPAIR ORDER (Y/N) y
SHORT RANGE SENSOR SCAN FOR QUADRANT ANTARES I --------------------------------- * * STARDATE 3124.2 CONDITION GREEN <*> >!< QUADRANT 1,1 * * SECTOR 3,1 * PHOTON TORPEDOES 10 TOTAL ENERGY 3000 SHIELDS 0 * * KLINGONS REMAINING 18 ---------------------------------
Proposed fix
[Check.If.Docked] Docked=0 A$=">!<" FOR I=SectROW-1 TO SectROW+1 FOR J=SectCOL-1 TO SectCOL+1 if I<0 or I>8 or J<0 or J>8 then [outOfSector] 'fix Z1=I Z2=J GOSUB [Look.For.A$.In.Quadrant$] IF Found=1 THEN Docked=1 [outOfSector] 'fix NEXT J NEXT I
|
|
|
Post by dan1101 on Dec 10, 2021 10:44:49 GMT -5
Another good catch, Anatoly. Thank you. The docking check was letting bad data through. I have added your fix to the listing at the top of the thread again. Out of curiosity, I went back and looked at the original code from 1978. Sure enough, there WAS a check for values out of range in the docking routine. I obviously deleted it at some point in the redesign process. Oops!
Thanks again!
-- Dan
|
|
|
Post by tsh73 on Dec 12, 2021 8:55:55 GMT -5
|
|
|
Post by dan1101 on Dec 15, 2021 5:33:46 GMT -5
NOTES ON GAME PLAY
In the process of analyzing and re-writing the Super Star Trek game for Liberty BASIC, I made notes to help me understand the original code. I did not write these with the intention of sharing them with anyone, but I decided that they may be of interest to anyone who might want to further modify and develop this classic game. I have edited and expanded them into a more readable form. These are mostly observations about specific aspects of game play.
As in the original version, the positions of stars, bases, and Klingons within each quadrant are randomized each time you enter the quadrant. If you leave a quadrant and immediately re-enter, all the stars, bases, and Klingons will have moved. Apparently, this is not a flaw, but a feature. This is the way it was in the original, so I left it as it was. There is no provision for storing locations of things in each Quadrant after leaving it.
Another way of thinking about it is: Essentially, the only quadrant that actually exists is the one you are in, and it is erased when you leave. The only values that are stored are the quantity of contents in each quadrant.
This also means that if you damage a Klingon, but do not destroy it, and leave the quadrant, the Klingon will be recreated AT FULL POWER when you return. If you destroy it before you leave, it is permanently removed and will not regenerate. Also, the power level of Klingons is randomly generated when you enter a quadrant. If you leave and re-enter, each Klingon's energy level changes at random each time. COMBAT Klingons can move around in a Quadrant, but they cannot leave a quadrant.
Klingons cannot harm the Enterprise while it is docked.
The Enterprise CAN fire upon Klingons while docked with either torpedoes or phasers. This seems to be an unfair advantage.
The Enterprise can destroy a star base AT WHICH it is currently DOCKED (torpedo).
The Enterprise can only fire its weapons when there is a Klingon present in the quadrant.
Klingons cannot attack a star base.
Since Klingons are armed only with phasers, they never have to aim their weapons. No matter where the Enterprise is located, they ALWAYS hit it, unless it is docked at a star base.
When Klingons move in between combat rounds, they relocate at random. In other words, while the Enterprise must travel in a STRAIGHT LINE and has to maneuver around objects, Klingons simply TELEPORT. They may relocate anywhere in the quadrant between combat rounds.
Klingons neither need nor use energy to move.
TIME Time passes in only two situations: when getting repairs at a Starbase, or when moving (using the navigation command). This means that you can use any of the Commands other than Navigation without any game time passing. Short and long-range scans, raising or lowering Shields, and Library-Computer functions all cause no time to pass. Even during combat, time passes only if and when you MOVE.
UNDEAD KLINGONS In combat, Klingon energy level is used for both offense and defense. They do not have a separate "shield" level. When the energy reaches zero the Klingon is destroyed, but this can only happen by being hit by an attack from the Enterprise. The lower the energy, the weaker the Klingon’s Phaser attacks become. Each Phaser attack the Klingons make reduces their own energy levels significantly, so they can only make a few attacks. If the Enterprise survives three or four hits from a specific Klingon, the power level for that Klingon is so reduced that it is essentially powerless to harm the Enterprise. It continues to attack, but it can do NO DAMAGE. This creates, in effect, harmless and somewhat pathetic "Undead Klingons", which I consider a flaw in the game. Klingons can never destroy themselves through energy depletion. No matter how low they get through attacking, their energy will always remain some fractional level above zero.
MORE ABOUT COMBAT Klingons always fire second, unless you move within the quadrant. If you move, they WILL fire first. This means that if you enter a quadrant with no shields raised, you always get a chance to raise them before the Klingons fire, as long as you have not moved since entering.
Klingons always fight to the death. No matter how badly damaged, they continue to attack until destroyed.
Phaser damage is reduced by the distance between ships. This applies to both Enterprise and Klingons. However, phaser damage is actually AMPLIFIED if the ships are directly adjacent to each other.
Enterprise Phaser damage is divided equally among the Klingons in the Quadrant. If there are three Klingons present, each takes only one third of the damage, but this is further modified by distance, so the closest ships take the most damage.
Photon torpedoes can only hit one Klingon per combat round.
You cannot use both Phasers and Photon Torpedoes in the same combat round.
If your shields are at zero, ANY hit on the Enterprise, no matter how small, will destroy the ship and end the game.
THE GALAXY No Quadrant can contain more than one Starbase, eight stars, or three Klingons.
Every Quadrant will contain at least one star. Empty quadrants are impossible.
The location of the Enterprise is never recorded in the Galactic grid!
The Enterprise is always placed first when a new Quadrant is entered and the rest of the contents of quadrant is then scattered at random around it. By this approach the number or Klingons, Bases, and Stars in each quadrant are part of the galactic record allowing the player to enter and leave a quadrant multiple times and always find the same quantity of contents, but the Enterprise itself travels from quadrant to quadrant like a ghost, leaving no record of exactly where it has been, or in which order the quadrants have been visited.
The quadrants that appear in the "explored" display (Library-Computer function 0) show any Quadrant visited or scanned with a Long Range Scan, so there is no way to tell whether a quadrant has actually been visited, or merely ADJACENT TO a quadrant that has been visited and scanned with a long range scan.
To win the game it is only necessary to visit the quadrants that contain Klingons. Much of the galaxy may be left unexplored. In fact, it is highly unlikely there would be enough time to visit every quadrant before the mission time expires.
Although there is no provision to save a game in progress, it would be quite simple to add this ability. The information needed to be stored in a file would include: the galactic grid, the location of the Enterprise (quadrant and sector coordinates), the star date, the starting and ending dates of the mission, and the Enterprise's damage array, energy level, and number of torpedoes. The number of Klingons remaining could be calculated from the galactic grid.
|
|