The Pawn Demo

Discuss ZX Spectrum Next Games, Tools and more.
Stefan123
Posts: 97
Joined: Mon Jun 05, 2017 9:38 pm

The Pawn Demo

Postby Stefan123 » Tue Jan 23, 2018 8:14 pm

I have written a limited demo of the text adventure game The Pawn for Spectrum Next. The Pawn was first released by Magnetic Scrolls in 1985 for Sinclair QL. The Atari ST and Commodore Amiga versions released in 1986 were groundbreaking in providing premium graphics in combination with an advanced parser. A text-only version of the game was released for Spectrum 128 and later Spectrum +3. In this demo, you can walk around in the world of Kerovnia and enjoy its beautiful graphics on your Spectrum Next.

The demo and all source code is on GitHub where more information is available. Only the source files pawn.c and world_pawn.c contain game-specific information, the rest of the source code is general.

https://github.com/stefanbylund/zxnext_pawn_demo

The purpose of the demo is to explore and demonstrate how a text adventure game can be presented on the Spectrum Next using a combination of the layer 2 screen for displaying colorful graphics and the Timex hi-res mode for displaying high-resolution text with a proportional font. It also demonstrates how a text adventure game can support a large amount of graphics and text by loading such resources on-demand from an SD card using ESXDOS.

The purpose of the demo is not to provide a fully-featured playable game. The parser is very limited, you can only walk around in the world, you cannot interact with its in-game characters and objects. I don't intend to continue developing the demo into a complete game since the original game is still under copyright and even if it wasn't, reimplementing the full parser and analyzing the original source code for determining all possible character/object interactions would be a huge work.

The demo contains all rooms with descriptions and graphics from the original Amiga version of the game. The Amiga version used the same graphics as the Atari ST version, which had 16-color images from a palette of 512 colors. These images have been converted to Spectrum Next's layer 2 graphics mode. Some of the images have been slightly reduced in height to fit the Spectrum Next screen resolution.

The demo can be run in the CSpect 1.7 emulator. Since I don't have a development board, I haven't been able to verify if it runs on the real hardware. It would be fun if someone with a board would try it :) Unfortunately, the demo does not currently run correctly in the ZEsarUX 6.0 emulator. If you enable the Timex hi-res mode in ZEsarUX, it cannot be combined with the layer 2 screen, only the Timex hi-res part of the screen is visible. If Timex hi-res mode is disabled in ZEsarUX, the text part of the screen will be displayed together with the layer 2 part but the actual text will of course be garbled.

How to Run

1. Download zxnext_pawn_demo.zip from GitHub and unzip it.

2. Install the latest version of the CSpect emulator (version 1.7 or later).

3. Run the batch file run_cspect.bat included in the demo. Make sure CSpect.exe is in your PATH or modify the batch file to point out where CSpect.exe is located.

Screenshots

Here are some screenshots from the demo:

Image

Image

Image

Image

Video

Here is a short video of the demo (click on the image to play):

Image
Last edited by Stefan123 on Thu Feb 15, 2018 6:43 pm, edited 5 times in total.

Stefan123
Posts: 97
Joined: Mon Jun 05, 2017 9:38 pm

Re: The Pawn Demo

Postby Stefan123 » Tue Jan 23, 2018 8:18 pm

The demo is written in C (with some parts in assembler) using z88dk. A big thank you to z88dk developer Alvin for helping out with the details of customizing the I/O terminal handling in z88dk. The graphics has been converted to layer 2 format with the Next BMP tools and is displayed in the demo using the zxnext_layer2 graphics library. The intro music is played with the vt_sound C API for the Vortex Tracker II player.

https://github.com/z88dk/z88dk
https://github.com/stefanbylund/zxnext_bmp_tools
https://github.com/stefanbylund/zxnext_layer2
https://github.com/stefanbylund/vt_sound

User avatar
mitja_i
Posts: 200
Joined: Tue May 30, 2017 6:27 am
Location: Ljubljana, Slovenia
Contact:

Re: The Pawn Demo

Postby mitja_i » Tue Jan 23, 2018 9:14 pm

That's amazing! Great work!
Backer 423 @ 37% funded 29 days left
---
ZX Spectrum Next glossary

Bleugh
Posts: 71
Joined: Mon May 29, 2017 9:30 pm

Re: The Pawn Demo

Postby Bleugh » Wed Jan 24, 2018 9:46 am

Wow!
Backer 331 - The full monty and a PCB

stephenvalente
Posts: 50
Joined: Tue May 30, 2017 8:24 am

Re: The Pawn Demo

Postby stephenvalente » Wed Jan 24, 2018 12:05 pm

Would this run in one of the Mac based emulators too? Great work either way.

Stefan123
Posts: 97
Joined: Mon Jun 05, 2017 9:38 pm

Re: The Pawn Demo

Postby Stefan123 » Wed Jan 24, 2018 1:14 pm

Thanks for the feedback :-)

Stephen: I'm only aware of two Next emulators: CSpect and ZEsarUX. CSpect is Windows-only and can be run on macOS using Windows emulation software. I've read on this forum that it should run fine in Wine. ZEsarUX is available for macOS but unfortunately has problems with showing the Timex hi-res mode simultaneously with the layer 2 mode. So right now, the only way to run the demo on macOS is to run it in CSpect under Wine (or similar).

If there are any other Next emulators, please let me know :-)

catventure
Posts: 4
Joined: Sun Jul 23, 2017 9:42 am
Contact:

Re: The Pawn Demo

Postby catventure » Wed Jan 24, 2018 1:39 pm

Nice work!
Author of "T.A.B.": a retro text adventure maker for Windows similar to 80's 8-bit adventure utilities like GAC, PAW or QUILL - Go To TAB Page

User avatar
cignale
Posts: 35
Joined: Mon May 29, 2017 8:24 pm
Location: Florence

Re: The Pawn Demo

Postby cignale » Fri Jan 26, 2018 3:15 pm

Mhhh, I have extracted the tap file and loaded with PlayZx android app (2 minutes loading time) in Next mode... Crashed. Surely I'm missing something...

Stefan123
Posts: 97
Joined: Mon Jun 05, 2017 9:38 pm

Re: The Pawn Demo

Postby Stefan123 » Fri Jan 26, 2018 7:10 pm

I've added a short video of the demo in the main post in this thread.

You can also click on the image below to play this video:

Image
Last edited by Stefan123 on Thu Feb 15, 2018 6:43 pm, edited 1 time in total.

Stefan123
Posts: 97
Joined: Mon Jun 05, 2017 9:38 pm

Re: The Pawn Demo

Postby Stefan123 » Fri Jan 26, 2018 7:35 pm

Cignale, thanks for trying the demo on a real Next board :D

Unfortunately, it is not enough to just load the TAP file via the headphone jack. The program needs to load resource files dynamically from the SD card. If you have the time, please try the following:

1. On your PC, unpack the downloaded ZIP file zxnext_pawn_demo.zip in the root directory of an SD card containing the Spectrum Next firmware. The README.md and run_cspect.bat files are not needed.

2. Insert the SD card in your Spectrum Next computer and start it.

3. Go to the directory zxnext_pawn_demo and run the program pawndemo.sna.

All files used by the program are loaded with relative paths from the current working directory. If the above does not work, move the contents of the zxnext_pawn_demo directory to the root directory of the SD card and try to run pawndemo.sna again.

By the way, what a cool avatar image you have :)


Who is online

Users browsing this forum: No registered users and 2 guests