|
1 | 1 | # OpenGFX2 |
2 | 2 | #  |
3 | 3 |
|
4 | | -Work-in-progress / development repo for an "OpenGFX v2". Or maybe that should be "OpenGFX director's edition", "refactored OpenGFX", or perhaps "OpenGFX extra zoom" or "OpenGFX 32bpp". Or some combination of all of them. |
| 4 | +"OpenGFX2" graphics base set for [OpenTTD](https://github.com/OpenTTD/OpenTTD). This is a spiritual successor to [OpenGFX](https://github.com/OpenTTD/OpenGFX). Think of it as "OpenGFX version 2", or maybe that should be "OpenGFX director's edition", "refactored OpenGFX", or perhaps "OpenGFX extra zoom" or "OpenGFX 32bpp". Or some combination of all of them. |
5 | 5 |
|
6 | 6 | Partly derived directly from OpenGFX, partly redrawn or revised from my original 32bpp sources. Almost all sprites have been updated or revised. |
7 | 7 |
|
8 | 8 | Features far better organisation of sprites. Extensive use of automated composite sprite generation using Python of bubious quality. Drawn and coded with extra zoom levels and 32bpp in mind. |
9 | 9 |
|
10 | 10 | ## Quick start |
11 | 11 |
|
| 12 | +### In-game content downloader / BaNaNaS |
| 13 | +It is easiest to use the in-game content downloader (`Check Online Content` in the OpenTTD main menu). |
| 14 | + |
| 15 | +To install, search for `OpenGFX2`, tick the checkbox next to OpenGFX2 Base graphics, and hit `Download`. |
| 16 | + |
| 17 | +To set as the base graphics set, go to `Game Options > (Graphics) > Base Graphics` from the OpenTTD main menu. Select `OpenGFX2 Classic`, then close the `Game Options` window. |
| 18 | + |
| 19 | +### Manual download |
12 | 20 | Download a release from [the prebuilt grf releases](https://github.com/zephyris/opengfx2/tags) and install using the instructions below. |
13 | 21 |
|
14 | | -Thease are early release previews not available in the in-game content downloader. |
| 22 | +These are early release previews not available in the in-game content downloader. This includes base set versions (the "High Def" 32bpp 4x zoom version) and NewGRFs not yet available through the in-game downloader. |
15 | 23 |
|
16 | | -## Building |
17 | | -Requires `git lfs` for large file handling. |
| 24 | +### Installation |
| 25 | +Install the baseset by copying `opengfx2_8.tar` and/or `opengfx2_32ez.tar` into the `baseset` directory for your OpenTTD installation. |
18 | 26 |
|
19 | | -Requires a system which can run `bash` shell scripts, `python3` with `PIL`, `blend-modes`, `numpy`, `skimage`, `nmlc`, `concurrent`, `multiprocessing`, `tqdm`. |
| 27 | +Install the newgrfs by copying each `.grf` file into the `newgrf` directory for your OpenTTD installation. |
20 | 28 |
|
21 | | -Clone the repository and run `make_all.sh`, it will take a long time... |
| 29 | +To set as the base graphics set, go to `Game Options>(Graphics)>Base Graphics` Set and select `OpenGFX2 Classic` (8bpp 1x zoom version) or `OpenGFX2 High Def` (32bpp 4x zoom version). |
22 | 30 |
|
23 | | -The built baseset will be in `baseset/`, called `opengfx2.tar`. |
| 31 | +To set OpenGFX2 settings, go to `NewGRF Settings`, find `OpenGFX2 Settings` and add to `Active NewGRF files`. Then, select `OpenGFX2 Settings` in the `Active NewGRF files list` and select `Set parameters` then adjust the settings. This is a bit of a hack, and will hopefully change in the future. |
24 | 32 |
|
25 | | -The build newgrf(s) will be in `newgrf/`. |
| 33 | +Install other NewGRFs as normal using `NewGRF settings`. |
26 | 34 |
|
27 | | -## Installation |
28 | | -Install the baseset by copying `opengfx2.tar` into the `baseset` directory for your OpenTTD installation. |
| 35 | +## Building |
| 36 | +These notes are for if you want to build OpenGFX2 from the source files. If you just want to download OpenGFX2 then you don't need to worry about these. |
29 | 37 |
|
30 | | -Install the newgrfs by copying each `.grf` file into the `newgrf` directory for your OpenTTD installation. |
| 38 | +Requires `git lfs` for large file handling. Once `git lfs` is installed then clone using `git` as normal. |
31 | 39 |
|
32 | | -To set as the base graphics set, go to `Game Options>(Graphics)>Base Graphics` Set and select `OpenGFX2`. |
| 40 | +Requires a system which can run `bash` shell scripts, `python3` with `PIL`, `blend-modes`, `numpy`, `skimage`, `nmlc`, `concurrent`, `multiprocessing`, `tqdm`. This has been developed using Windows Subsystem for Linux (WSL) and might have peculiarities (eg. incorrect file permissions) on a real Linux install. |
33 | 41 |
|
34 | | -To set OpenGFX2 settings, go to `NewGRF Settings`, find `OpenGFX2 Settings` and add to `Active NewGRF files`. Then, select `OpenGFX2 Settings` in the `Active NewGRF files list` and select `Set parameters` then adjust the settings. This is a bit of a hack, and will hopefully change in the future. |
| 42 | +### To build |
| 43 | +Clone the repository, navigate to the repository root directory and run `make_all.sh`. It will take a long time... |
35 | 44 |
|
36 | | -Install other NewGRFs as normal using `NewGRF settings`. |
| 45 | +The built baseset will be in `baseset/`, making different versions called `opengfx2_<version>.tar`. |
| 46 | + |
| 47 | +The build newgrf(s) will be in `newgrf/`, making various `.grf` files. |
| 48 | + |
| 49 | +### Build process notes |
| 50 | +Image processing makes a bunch of intermediate files, particularly `*_8bpp.png` and things in `pygen` directories. Others are `_bt32bpp`, `_rm32bpp.png`. These files are assumed to be temporary intermediates, and any user-modified versions will be blindly overwritten. Make sure you look at `.gitignore` see which files this applies to. |
| 51 | + |
| 52 | +Files processed by `python` and encoded by `nml` are `.png` files, but those may be derived from other sources. Raw sprites were variously drawn\generated in Paint.NET, Aseprite, Blender and more. Conversion from those raw sources to `.png` files is not part of the build process - it must be done manually. |
| 53 | + |
| 54 | +## Development |
| 55 | +These notes are to help development. If you are just downloading or building OpenGFX2 then you don't need to worry about these. |
37 | 56 |
|
38 | | -## Further notes |
39 | | -Image processing makes a bunch of intermediate files, particularly `*_8bpp.png` and things in `pygen` directories. |
| 57 | +### Release preparation |
| 58 | +Remember to bump the versions: |
| 59 | +* Base set version in `baseset/baseset_generate_obg.py` |
| 60 | +* NewGRF versions in `newgrf/nml/<newgrf_name>/<newgrf_name>-header.pmnl` |
| 61 | +* `extra.grf`/`opengfx2_settings.grf` co-compatibility check in `baseset/nml/extra-header.pnml` |
40 | 62 |
|
41 | | -Files used by `python` are `.png` files, but those may be derived from other sources. Raw raw sprites wre variously drawn\generated in Paint.NET, Aseprite, Blender and more. |
| 63 | +For better or worse, base set currently uses fractional (0.1, 0.2, ...) versioning and NewGRFs use integer (1, 2, ...) versioning. |
0 commit comments