Le Fétiche Maya 64bit

Le Fétiche Maya 64bit is a native 64-bit port of Le Fétiche Maya for Windows and macOS, built by statically recompiling the Amiga version to C.

README

Le Fétiche Maya 64bit icon

Le Fétiche Maya 64bit

A native 64-bit port of Le Fétiche Maya (Silmarils, 1989), made by statically recompiling the Amiga version's program to C. It is not an emulator with the game inside: the game's 68000 code is translated ahead of time and runs as native code on a small model of the Amiga hardware it needs.

  • Windows x64: v1.0.0.
  • macOS (universal: Apple silicon and Intel): v1.0.0, signed and notarized by Apple.

The game is not included. You need your own copy of the original Amiga game's files.

The title picture in the Windows host, with CRT scanlines and 4:3 aspect

Silmarils logoStart promptThe first scene

Playing (Windows)

  1. Download maya64-1.0.0-win64.zip from the releases and unpack it anywhere.
  2. Have the Amiga game's data folder ready: the one that holds MAIN.CO and the other .CO files. In the WHDLoad package of the game it is Maya\data.
  3. Start maya64.exe. The first time, it asks for that folder and remembers it. You can also copy the game's files next to maya64.exe, or start it with --data <folder>.

Windows 10 or 11, 64-bit. No installer and no other files are needed.

Controls

The game is played with the Amiga joystick and a few keys.

ActionKeyboardGame controller (XInput)
Move the hero and the menu handArrow keys, or the numeric keypad (7/9/1/3 are the diagonals)D-pad or left stick
Fire / selectLeft Ctrl, Right Ctrl, Numpad 0 or keypad EnterA or B
Leave the logoAny key
Start a game?
Load the saved gameL at the start prompt
The game's iconsF1 to F10 (F10 saves)
Full screenAlt+Enter

Letters and ? follow your keyboard layout: press the key that types the character.

Display and settings

The window's system menu (click the icon in the title bar, or press Alt+Space) holds the port's options:

  • Full screen (Alt+Enter)
  • Integer scaling or Fit to window
  • 4:3 monitor aspect: shows the 320×200 picture as it looked on a 4:3 monitor, instead of square pixels
  • CRT scanlines
  • About…

The window follows the Windows light or dark app theme. Settings are kept in maya64.cfg and saved games in saves\, both next to maya64.exe (or in %APPDATA%\Le Fetiche Maya 64bit when that folder is read-only). The game's own folder is never written to.

Command line: --data <folder>, --crt 0|1, --aspect 4:3|square.

Playing through a launcher

Two launchers can install and start the port. Neither of them contains or downloads the game: you still need your own copy of the Amiga game's files.

  • RecompLauncher: install Le Fétiche Maya 64bit there (it takes the release from this repository), pick the Amiga version's data folder once (the one that holds MAIN.CO) and press Play. It starts maya64.exe --data <folder>. The picture shape (4:3 or square pixels) and the CRT scanlines are settings on the game's page, and the page opens the saved games (saves\ beside the program). On a Mac it installs the .zip, not the disk image.

  • sp00nznet's recomp-launcher (Windows only): from the next tagged version on, the release also carries Maya64-Installer-windows-x64.exe. It finds or asks for the game's data folder, downloads this project's newest Windows release (nothing is compiled) and shows a Play button. Until then, this command does the same by hand from a copy of this repository, and leaves Le Fetiche Maya (recomp).cmd there to start the game:

    powershell -NoProfile -ExecutionPolicy Bypass -File launcher\setup.ps1 -Game "<the game's data folder>"
    

Playing (macOS)

  1. Download maya64-1.0.0-macos.dmg from the releases, open it and drag Le Fetiche Maya 64bit to Applications. (maya64-1.0.0-macos.zip holds the same application.)
  2. Have the Amiga game's data folder ready, as for Windows (Maya/data in the WHDLoad package).
  3. Open the application. The first time, it asks for that folder and remembers it. A folder next to the application also works, as does open "/Applications/Le Fetiche Maya 64bit.app" --args --data <folder>. If the folder is in Documents, Desktop, Downloads or on an external drive, macOS asks once whether the game may read it.

macOS 11 Big Sur or later; one application for Apple silicon and Intel Macs.

The controls are those of the table above, with these differences: Control (either one) is fire, F1 to F10 may need the fn key on a Mac keyboard, full screen is Control+Command+F (or the window's green button), and the Command key always stays the Mac's (Command+Q quits). The options are in the View menu: Enter Full Screen, Integer Scaling or Fit to Window, 4:3 Monitor Aspect and CRT Scanlines; About is in the application menu. Settings and saved games are kept in ~/Library/Application Support/Le Fetiche Maya 64bit/; the game's folder is never written.

Building from source

Windows

You need Visual Studio 2022 or later (C++ tools), CMake, Ninja, Python 3.8 or later, and optionally LLVM (clang-cl is used when present). You also need the Amiga game's T.X, the program that gets recompiled; it sits in the same data folder.

build.cmd D:\Games\Maya\data

This generates C from your T.X into the build folder and builds build\win\maya64.exe (the game) and build\win\maya_cli.exe (a headless runner for tests: scripted input, BMP screenshots, WAV sound). The recompiler checks T.X against the version it was written for (the WHDLoad v1.4 package's file) and warns on a mismatch.

The application icon is built from res/maya64-icon.png with python tools/make_icon.py (needs Pillow); the generated res/maya64.ico is in the repository, so a normal build does not need this step.

macOS

You need the Xcode command line tools, CMake and Python 3 (Ninja is used when present), and the game's T.X.

./build.sh ~/Games/Maya/data

This builds the universal build/mac/Le Fetiche Maya 64bit.app (signed ad hoc) and build/mac/maya_cli. tools/package_mac.sh makes the signed, notarized release zip and disk image; see docs/MACOS-PORT.md.

How it works

PathContents
tools/m68k/The recompiler: hunk loader, 68000 decoder, control-flow analysis, C generator
runtime/The Amiga the game needs: CPU state and dispatcher, custom chips (copper, bitplanes, blitter, Paula sound), CIAs, and the ~40 AmigaOS calls the game makes
present/Scaling, 4:3 aspect and the CRT scanlines filter (portable C)
host/win32/The Windows application: window, menu, theme, About box, input, sound output
host/macos/The macOS application (Cocoa): window, menus, About box, input, game controllers, AudioQueue sound
tests/maya_cli, the headless runner
docs/Design and status: RECOMP-PLAN.md, HOST-DESIGN.md, DECISIONS.md, MACOS-PORT.md, RELEASE-NOTES.md

The game's program, T.X, is an interpreter for Silmarils' ALIS script language. The recompiler translates it to C functions that keep the 68000's registers and stack exactly, with cycle counts so that interrupts, the display and the sound run on the original timing. The scripts, pictures, sounds and music are read from the game's own files at run time, unchanged.

What is and is not in this repository

  • In: the port's own code, documentation, and a few screenshots.
  • Not in: any file of the game, and no C generated from it. The released maya64.exe necessarily contains the translated interpreter, as any static recompilation's binary does; it contains none of the game's scripts, pictures, sounds or music, and does nothing without the original game's files. The same holds for the macOS application.

Credits and licence

Le Fétiche Maya is by Silmarils (Claude Cazenave, Louis-Marie Rocques, Valérie Vasseur, Yves Pierog, J-Christophe Charter, Bruno Blanchet). The game belongs to its owners.

The 64-bit version is by Onur BUYUKCAGLAR, with Anthropic Claude AI assistance. The port's own code is under the MIT licence, which also lists the acknowledgements (the WHDLoad installer by Mr.Larmer and CFou!, DOSBox Pure Unleashed's CRT filter by Bernhard Schelling, and maestun's ALIS interpreter as a format reference).

Listed on PlayPorted