aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2016-01-26 06:03:25 -0500
committerB. Watson <yalhcru@gmail.com>2016-01-26 06:03:25 -0500
commit0735321bfc1aadf7e2230df1edc9dd7363978dd6 (patch)
tree4e42d04a9e33ebdcebf2a605f90dc00109201f3e
parent9203bbfed671b809d8c4c8e2d2dabe058b8bc249 (diff)
downloadtaipan-0735321bfc1aadf7e2230df1edc9dd7363978dd6.tar.gz
fix prices not being reset, make cursor less visible
-rw-r--r--README.txt29
-rw-r--r--push.sh3
-rw-r--r--taipan.c8
3 files changed, 19 insertions, 21 deletions
diff --git a/README.txt b/README.txt
index 52bf581..a9795a6 100644
--- a/README.txt
+++ b/README.txt
@@ -120,27 +120,19 @@ arcade game).
BUGS! At least these:
-- When entering bank deposit/withdrawal amounts, numbers greater than
- 2**32-1 (2,147,483,647) result in the wrong amount being transferred,
- due to get_num() returning a signed long (which it does in order to
- support pressing Enter for 'all', which returns -1). Fixing this will
- require changes to both get_num() and all the code that calls it.
-
- After a battle, the prices don't get reset (or, not always?) when
- entering the new port (confirm? This was reported but I haven't
- seen it).
+ entering the new port.
- The "negative interest" bug is currently missing, due to using
unsigned values for debt. Plus, it's cheating. I'm undecided
whether or not to use a bignum for debt; if I do, it will be
possible to have negative debt.
-- Not really a bug, but, the interest calculation for debt
- is slightly different, due to using integer math. Very small debt
- amounts will grow much faster than they should, then stabilize and
- converge towards the correct values over time. This only happens when
- you have less than 10 in debt, which (at least for me) is a pretty
- rare situation.
+- Not really a bug, but, the interest calculation for debt is slightly
+ different, due to using integer math. Very small debt amounts will grow
+ much faster than they should, then stabilize and converge towards the
+ correct values over time. This only happens when you have less than
+ 10 in debt, which (at least for me) is a pretty rare situation.
- A few things in the screen layout are slightly off comapred to
the Apple version. Would really like to get it exact.
@@ -163,9 +155,10 @@ BUGS! At least these:
from combat, it said 4 billion ships were attacking (number of ships
must have gone negative).
-- After a fight, "Arriving at Manila" or such will sometimes appear on the
- fight screen without clearing it first (ships still visible).
- sea_battle() is returning something unexpected, but how?
+- Fixed, I think: After a fight, "Arriving at Manila" or such will
+ sometimes appear on the fight screen without clearing it first (ships
+ still visible). This happened when Li Yuen's pirates drove off the
+ first enemy fleet, then attacked the player.
Deliberate differences between the Apple II and Atari ports:
@@ -185,7 +178,7 @@ Deliberate differences between the Apple II and Atari ports:
some prompts need Enter, some don't. In the Atari port, the only prompts
that require Enter are:
- naming your firm
- - entering a cash amount (but not if you hit a for "all")
+ - entering an amount, cash or items (but not if you hit a for "all")
5. "We have 5 guns" is in an inverse video box. I think it looks nicer, and
it matches the "You can afford 5" inverse video box on the trading
diff --git a/push.sh b/push.sh
index f03791e..69c9cae 100644
--- a/push.sh
+++ b/push.sh
@@ -5,7 +5,8 @@
# "naptime" is a shell script that you don't have :)
git push && make distclean all || exit 1
-URL="$( naptime taipan.xex | sed 's,urchlay.naptime.net,204.9.204.226,' )"
+#URL="$( naptime taipan.xex | sed 's,urchlay.naptime.net,204.9.204.226,' )"
+URL="$( naptime taipan.xex )"
REV="$( git rev-parse --short HEAD )"
echo "build ID $REV at $URL"
diff --git a/taipan.c b/taipan.c
index 246c60e..bb49035 100644
--- a/taipan.c
+++ b/taipan.c
@@ -1281,7 +1281,10 @@ unsigned long get_num(void) {
num_buf[count] = '\0';
count--;
} else if(input == 'a') {
- if(!count) return UINT32_MAX;
+ if(!count) {
+ cursor(0);
+ return UINT32_MAX;
+ }
} else if(input == 'k' || input == 'm') {
char i;
for(i = 0; i < (input == 'k' ? 3 : 6); i++) {
@@ -2048,7 +2051,8 @@ void quit(void)
timed_getch(TMOUT_3S);
- return;
+ // return; // original code, results in prices not changing.
+ result = 0;
} else {
static int num_ships;
num_ships = randi()%((capacity / 5) + guns) + 5;