/Makt

An open source implementation of a backend for the game HoMM3 in Swift.

Primary LanguageSwiftOtherNOASSERTION

βš”οΈ Makt πŸ›‘

This is an open source implementation of classic game Heroes of Might and Magic III Complete (HoMM3) "backend" (fully functional (well work in progress) game engine, without graphics) in pure Swift.

Etymology

"Makt" means "Might" in Swedish πŸ‡ΈπŸ‡ͺ

Packages

Package Common πŸ› 

Unintersting shared utility code stuff.

Package Decompressor πŸ“–

GZip decompressor package.

Package Malm πŸͺ¨

Contains all shared game models such as Hero, Creature, Spell, Artifact etc, but no logic at all.

Etymology

"Malm" means "Ore" in Swedish πŸ‡ΈπŸ‡ͺ

Package Guld πŸͺ¨

Parser of HoMM3 asset files/archives: .lod, .def, .pcx

Etymology

"Guld" means "Gold" in Swedish πŸ‡ΈπŸ‡ͺ

Package Video πŸ“½

Conversion of .bik and .smk movie files into .mov

Noteable dependency

This package uses SwiftFFmpeg which requires FFmpeg (Requires FFmpeg 4.0 or higher). on macOS, you can:

brew install ffmpeg

Package H3M πŸ—Ί

HoMM3 map file - .h3m - parser.

H3M Map File structure

Do check out H3M.md for map file structure.

Gotchas

A tile might contain multiple objects, in fact more than two! E.g. a Hero has a box of 3x2 and in the same origininating tile (lower left tile) of that 3x2 box, there might be another object, e.g. a resource. This is seen on tile (x: 25, y: 65) on vanilla RoE map "Race for Ardintinny.h3m". Or on map "Rebellion" at (x: 52, y: 57) there is a mountain, rock and crystalCavern.

Package H3C πŸ•

HoMM3 campaign file - .h3c - parser.

Package Laka

A CLI toolset for extraction of game resources.

See README.

Etymology

"Laka" means "Extract" in Swedish πŸ‡ΈπŸ‡ͺ

Package Packa πŸ“¦

Binary tree packing algorithm used by Laka, to fit as many images in an as small square as possible.

See README.

Package Makt βš”οΈ

The game engine.