Welcome, Guest. Please login or register.

Author Topic: Blast from the past: Payback native for AmigaOS4.  (Read 957 times)


0 Members and 1 Guest are viewing this topic.

Offline kas1eTopic starter

Blast from the past: Payback native for AmigaOS4.
« on: December 23, 2022, 09:50:32 PM »

Yes, you read that right. Payback for AmigaOS 4 is available right now! Grab from os4depot while it hot!
Thanks to James Daniels from Apex-Designs, I was allowed to port it to AmigaOS4 and release it as AOS4 update.
You still need to buy the original Amiga CD and grab the latest updates from https://apex-designs.net/.

Before you go hunting, I want to highlight what has been done and what is planned for future updates:

The original Payback was written in C and built via StormC (meaning GCC 2.95), and a large part of the code was Assembler-based: the 68K version used the 68K assembler,
whereas the PPC/WarpOS version used H&P's Power ASM assembler (this one is with Motorola syntax, so it's PPC assembler with Phxass kind syntax and is incompatible with
GCC's "as"). So I was in needs to port all the C code from old GCC to newer GCC, and then take the Power ASM assembler code used for the WarpOS version and adapt it, so
it can be compiled with self build VASMMOT_PPC (which means VASM with Motorola syntax). Then I used GCC to combine everything into a single OS4 binary. The assembler
code adaptation was minor, but I had to implement a few functions that were not available in VASM's assembler (prolog/epilog, pushgprs/popgprs, etc).
The next major issue was Payback's Warp3D rendering. The codes were once again “old GFX cards”-based and contained some bugs, so some rewriting and fixing was required.
Yeah, it is not uncommon for game developers from the past to assume that only old kinds of graphics cards will be used (as it was in Exodus: The Last War, for example).
Now, you can use hardware rendering on your RadeonHD or RadeonRX cards with no problems, be it NovaBridge or Warp3D_SI. Thanks to Hans for his help in terms of Warp3D code!

Migration from GCC 2.95 to GCC 11.3 also takes some time because of plenty of deprecated code, old-fashioned use of DOS's anchors, message ports, memory allocations, the
way of calling assembler functions, non-static structs, etc. And, as we were told, the things that were forgiven in GCC 2.95 are no longer applicable in today's GCC, so
changes must be made. On top of that, instead of newlib, I do use Afxgroup's improved CLIB2 fork (more specifically, CLIB2_beta07).

Once things start working, new video modes are added (so you can play HD modes like 1920x1080 too). At the same time, Javier starts writing a new “preference” program that
is now Reaction-based, logical, and visually appealing. Now you can control everything from the PaybackSetupOS4 binary right from the start, as well as later in the game
as before, of course. Also, Javier does help with some bits all over the place as always, so hats off for that!

The following changes are not included in this update, but are planned for future ones:

-- Support for window mode.
-- Finalizing of the FLC video player with auto-scaling. We do have a working version, but it's not good enough, so we postponed it to a later update.
-- Complete the migration from audio.device to the ahi.device. Also, it kind of works already, but not well enough.
-- Fixing hardware rendering to works on the older Warp3D classic drivers again (migration to the newer GCC required extensive rewriting, resulting in clumsy hardware mode
   on real Warp3D).
-- to fix bugs that will be found in this update.

Now, how to install:

To install the Payback OS4 Update, you need to do some preparation work:
 - You need Payback CD Image + .CUE (for CD-Audio)
 - You need PaybackUpdate7.lha (https://www.apex-designs.net/PaybackUpdate7.lha)
 - You need working DiskImage device (to mount .CUE image):
 - To have CD-Audio you need cdplayer.library with CDDAPatch installed:
 - You need Serial Key.
 - You need this new PaybackUpdateOS4.lha
 - You need "Warp3D NovaBridge" installed and working on your RadeonHD or
   RadeonRX (on RadeonHD, if you do not have Nova Bridge, you may also use
   the Warp3D_SI driver instead).

Now you need to install the original version first, and apply original update:
 - Mount Payback's .CUE via DiskImageGUI or via command line (I use ICD0:).
 - Install the Game from the CD (when ask for screenmode skip it).
 - Apply the PaybackUpdate7 on top of it.
 - Apply this PaybackUpdateOS4 on top of it.

After that, you launch PaybackSetupOS4, which allows you to:
 - Select a screenmode for software (CPU) and/or hardware (Warp3D) rendering.
 - Select the rendering method.
 - Select "diskimage.device" for CDDA and the unit on which you mount PayBack's
   CUE file (to find the unit, click RMB on PaybackCD's icon on the workbench
   and choose "information")
 - Save and exit.

Then you just start a game by running PayBackOS4, type your key, and enjoy!
Here is the video showing how to prepare, install, and what the gameplay of the OS4 version of Payback looks like:

How-to Payback on AmigaOS4, 1920x1080 full HD

In the end, I want to give a big Thank You:

 - to James Daniels for making such a nice game: https://www.apex-designs.net/
 - to Javier for creating the preference program and whole help: https://github.com/javierdlr
 - to Afxgroup for creating an up-to-date fork of CLIB2 and improving it: https://github.com/afxgroup/clib2
 - to Hans for 2D/3D drivers and Payback's hardware rendering solutions: https://keasigmadelta.com/
 - to Salas00 for cdplayer.library, CDDA patch, diskimage.device and everything else he does for OS4: http://www.a500.org/
 - to Frank Wille, who is helping me with VASM bits: http://sun.hasenbraten.de/~frank/projects/
 - to OS4 community being alive and kicking!

Merry hunting XMAS!

Offline lionstorm

Re: Blast from the past: Payback native for AmigaOS4.
« Reply #1 on: December 24, 2022, 05:37:19 PM »
Well done and havec a nice Christmas time !

Offline utri007

Re: Blast from the past: Payback native for AmigaOS4.
« Reply #2 on: December 24, 2022, 05:44:22 PM »
Can I really buy it now??
ACube Sam 440ep Flex 800mhz, 1gb ram and 240gb hd and OS4.1FE
A1200 Micronic tower, OS3.9, Apollo 060 66mhz, xPert Merlin, Delfina Lite and Micronic Scandy, 500Gb hd, 66mb ram, DVD-burner and WLAN.
A1200 desktop, OS3.9, Blizzard 060 66mhz, 66mb ram, Ide Fix Express with 160Gb HD and WLAN
A500 OS2.1, GVP+HD8 with 4mb ram, 1mb chip ram and 4gb HD
Commodore CDTV KS3.1, 1mb chip, 4mb fast ram and IDE HD