Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 19b613f

Browse files
authored
Merge branch 'develop' into adv_cursor
2 parents 71f92c6 + 1ab06ce commit 19b613f

34 files changed

Lines changed: 831 additions & 820 deletions

.github/workflows/watch-df-release.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ jobs:
3131
- name: Compare branch metadata
3232
uses: nick-fields/retry@v3
3333
with:
34-
timeout_minutes: 2
34+
timeout_minutes: 5
35+
retry_wait_seconds: 60
3536
command: |
3637
blob=$(wget 'https://api.steamcmd.net/v1/info/975370?pretty=1' -O- | \
3738
awk '/^ *"branches"/,0' | \
@@ -117,7 +118,8 @@ jobs:
117118
- name: Compare versions
118119
uses: nick-fields/retry@v3
119120
with:
120-
timeout_minutes: 2
121+
timeout_minutes: 5
122+
retry_wait_seconds: 60
121123
command: |
122124
version=$(wget "${{ matrix.url }}" -qO- | tr '"' '\n' | fgrep 'tar.bz2' | head -n1 | sed -r 's/${{ matrix.prefix }}_([0-9]{2})_([0-9]{2})_linux.tar.bz2/\1.\2/')
123125
echo "latest ${{ matrix.channel }} version: $version"

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ repos:
2020
args: ['--fix=lf']
2121
- id: trailing-whitespace
2222
- repo: https://github.com/python-jsonschema/check-jsonschema
23-
rev: 0.30.0
23+
rev: 0.31.1
2424
hooks:
2525
- id: check-github-workflows
2626
- repo: https://github.com/Lucas-C/pre-commit-hooks

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ cmake_policy(SET CMP0074 NEW)
77

88
# set up versioning.
99
set(DF_VERSION "51.04")
10-
set(DFHACK_RELEASE "r1")
10+
set(DFHACK_RELEASE "r1.1")
1111
set(DFHACK_PRERELEASE FALSE)
1212

1313
set(DFHACK_VERSION "${DF_VERSION}-${DFHACK_RELEASE}")

data/init/dfhack.keybindings.init

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,9 @@ keybinding add Ctrl-T@dwarfmode/ViewSheets/UNIT|dwarfmode/ViewSheets/ITEM|dungeo
4949
# quicksave
5050
keybinding add Ctrl-Alt-S@dwarfmode quicksave
5151

52+
# toggle spectate
53+
keybinding add Ctrl-Shift-S@dwarfmode/Default "spectate toggle"
54+
5255
# designate the whole vein for digging
5356
keybinding add Ctrl-V@dwarfmode digv
5457
keybinding add Ctrl-Shift-V@dwarfmode "digv x"

docs/about/Authors.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,7 @@ thurin thurin
242242
Tim Siegel softmoth
243243
Tim Walberg twalberg
244244
Timothy Collett danaris
245+
Timothy Torres timothymtorres
245246
Timur Kelman TymurGubayev
246247
Tom Jobbins TheBloke
247248
Tom Prince

docs/changelog.txt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,14 +54,21 @@ Template for new versions:
5454
## New Tools
5555

5656
## New Features
57+
- `spectate`: can now specify number of seconds (in real time) before switching to follow a new unit unit
58+
- `spectate`: new "cinematic-action" mode that dynamically speeds up perspective switches based on intensity of conflict
59+
- `spectate`: new global keybinding for toggling spectate mode: Ctrl-Shift-S
5760

5861
## Fixes
5962
- `gui/launcher`: ensure commandline is fully visible when searching through history and switching from a very long command to a short command
6063
- `createitem`: output items will now end up at look cursor if active
64+
- `spectate`: don't allow temporarily modified announcement settings to be written to disk when "auto-unpause" mode is enabled
65+
- `changevein`: fix a crash that could occur when attempting to change a vein into itself
6166

6267
## Misc Improvements
68+
- `spectate`: player-set configuration is now stored globally instead of per-fort
6369

6470
## Documentation
71+
- `stonesense-art-guide`: new guide for making sprite art for Stonesense
6572

6673
## API
6774

@@ -70,6 +77,16 @@ Template for new versions:
7077

7178
## Removed
7279

80+
# 51.04-r1.1
81+
82+
## Fixes
83+
- `gui/launcher`: ensure commandline is fully visible when searching through history and switching from a very long command to a short command
84+
- `gui/launcher`: flatten text when pasting multi-line text from the clipboard
85+
- Ctrl-a hotkeys have been changed to something else (Ctrl-n) for tools that also have an editable text field, where Ctrl-a is interpreted as select all text
86+
87+
## API
88+
- ``Core::getUnpausedMs``: new API for getting unpaused ms since load in a fort-mode game
89+
7390
# 51.04-r1
7491

7592
## Misc Improvements

docs/guides/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,4 @@ These pages are detailed guides covering DFHack tools.
1010
/docs/guides/modding-guide
1111
/docs/guides/quickfort-library-guide
1212
/docs/guides/quickfort-user-guide
13+
/docs/guides/stonesense-art-guide
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
.. _stonesense-art-guide:
2+
3+
Stonesense art creation guide
4+
=============================
5+
6+
Understanding isometric perspective
7+
-----------------------------------
8+
9+
Stonesense uses an isometric perspective, a form of pseudo-3D projection where objects are displayed at an
10+
angle, typically with a 2:1 pixel ratio for diagonal lines. This perspective allows for a detailed and visually
11+
appealing representation of a 3D world using 2D sprites. Unlike traditional top-down views, isometric projection
12+
simulates depth while maintaining a consistent scale without vanishing points.
13+
14+
Understanding sprites
15+
---------------------
16+
17+
Understanding how Stonesense deals with sprites is central to anyone who wishes to modify the content. The
18+
scheme is not very complicated, and this guide will give a short introduction to how they work. With the
19+
exception of floors, which we will discuss later, all sprites are 32x32 pixels and come in groups known
20+
as sprite sheets. All sprites are loaded and rendered in 32-bit full-color PNGs. The image files should have
21+
a transparent background but pure magenta (RGB: 255,0,255) is also treated as transparent.
22+
23+
24+
.. image:: ../images/stonesense-sprite-sample.png
25+
:align: left
26+
27+
Here's an example of a typical Stonesense sprite.
28+
29+
When working with Stonesense sprites, it is important to understand how they fit into the isometric grid.
30+
Each sprite is designed to align with the isometric perspective and must fit within a specific bounding area.
31+
To illustrate this, here is a template for the area that should be used by Stonesense sprites:
32+
33+
.. image:: ../images/stonesense-sprite-template.png
34+
:align: left
35+
36+
The solid area is the floor space taken up by a sprite, while the dotted box indicates the volume above this
37+
area corresponding to one z-level.
38+
39+
The way sprites are loaded is fairly generalized: the name of the sprite sheet, and the index of a sprite within that sheet.
40+
41+
Sprite sheets
42+
-------------
43+
There can be an arbitrary number of sprite sheets for Stonesense, though there are 3 sheets that are
44+
always present as they contain default sprites (see further down). Configuring the XML to use new sheets is
45+
outside the scope of this guide but there may be a guide for such added in the future.
46+
47+
Sprite index
48+
------------
49+
The sprite index, or sheet index, is the zero-indexed offset of a sprite on its sprite sheet.
50+
The index starts with the upper left sprite which has index zero. It then increments to the right. Stonesense
51+
is hardcoded to 20 sprite-wide sheets, this means that anything past 20 "sprite slots" is ignored, though less
52+
than 20 slots is fine. The first sprite on the second row always has index 20 (even if there are fewer sprites per row in the sheet), the next row is 40, and so on. This
53+
boundary is hardcoded and changing the size of the sheet will not affect it.
54+
55+
This image shows how sprites are indexed. Grid added for readability.
56+
57+
.. figure:: ../images/stonesense-indexed-sprites.png
58+
:align: left
59+
60+
61+
Important sprite sheets
62+
-----------------------
63+
`objects.png <https://github.com/DFHack/stonesense/blob/master/resources/objects.png>`_ is the default sheet
64+
for buildings and vegetation. Also used for all hard-coded content, like default plants, the cursor, default
65+
walls and liquid.
66+
67+
`creatures.png <https://github.com/DFHack/stonesense/blob/master/resources/creatures.png>`_ is the default
68+
sprite sheet for creatures. If no file is specified in a creature node, this is the sheet it will use.
69+
70+
`floors.png <https://github.com/DFHack/stonesense/blob/master/resources/floors.png>`_ holds all the Stonesense
71+
floors. Unlike the other sprite sheet, this sheet is hard-coded with sprite dimensions of 32x20 pixels.
10 KB
Loading
694 Bytes
Loading

0 commit comments

Comments
 (0)