Recent

Author Topic: sea wolf (inc)  (Read 634 times)

speter

  • Sr. Member
  • ****
  • Posts: 420
sea wolf (inc)
« on: October 04, 2025, 10:07:13 am »
Another game based on a game in Tim Hartnell's book "THe Big Fat Book of Computer Games".

Sea Wolf is a Convoy v Submarine game, set post WW2. You play the Convoy (and Escort) while the 'computer' plays the submarine.

I had a lot of trouble GUI-ifying this game, until I hit on the "obvious" solution of simply making it event-driven. In the original (basic) text game the player decides whether to move their Convoy, then whether they use the Convoy's sonar, then whether the Convoy will attempt to shoot at the Submarine - then all that is repeated for the Escort.

In my version, the player places their Convoy and Escort, then can do any of the options, using either ship, which made it much less irritating. :)

As before, I am including the (scanned) original BASIC code.

enjoy.
S.
I climbed mighty mountains, and saw that they were actually tiny foothills. :)

Ñuño_Martínez

  • Hero Member
  • *****
  • Posts: 1216
    • Burdjia
Re: sea wolf (inc)
« Reply #1 on: October 10, 2025, 06:42:10 pm »
Hartnell's games are great.  I translated Mistress of Xenophobia to C++ and Allegro ages ago.  I also tried to translate Knightsbridge several times (the last one to Pascal) but for some reason I never succeeded. %)  Both games from Giant Book of Computer Games.

I've tested it on Linux and works flawlessly.  A suggestion:  scroll the console (Memo1) so it shows the latest entry instead of having to do it manually.  You can access to the scrollbar and change its position.
Are you interested in game programming? Join the Pascal Game Development community!
Also visit the Game Development Portal

speter

  • Sr. Member
  • ****
  • Posts: 420
Re: sea wolf (inc)
« Reply #2 on: October 11, 2025, 12:05:00 am »
Hartnell's games are great.  I translated Mistress of Xenophobia to C++ and Allegro ages ago.  I also tried to translate Knightsbridge several times (the last one to Pascal) but for some reason I never succeeded. %)  Both games from Giant Book of Computer Games.
Excellent! The book I have doesn't have either of those. :(

If you get either working in FPC/Laz, please post them! :)

I've tested it on Linux and works flawlessly.  A suggestion:  scroll the console (Memo1) so it shows the latest entry instead of having to do it manually.  You can access to the scrollbar and change its position.
It sounds like the memo isn't automatically scrolling to the bottom, when lines are added. It works fine in windows 11. I'll check it out; thanks for the feedback.

cheers
S.
I climbed mighty mountains, and saw that they were actually tiny foothills. :)

BlueIcaro

  • Hero Member
  • *****
  • Posts: 827
    • Blog personal
Re: sea wolf (inc)
« Reply #3 on: October 11, 2025, 01:31:07 pm »
Hello, you can use this:
Code: [Select]
Memo1.selstart := MaxInt; 
to move to the last line

/BlueIcaro

 

TinyPortal © 2005-2018