Skip to content

Commit 508b4ee

Browse files
Clean up based on feedback
1 parent 68faca8 commit 508b4ee

File tree

1 file changed

+15
-14
lines changed

1 file changed

+15
-14
lines changed

docs/guides/stonesense-art-guide.rst

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,6 @@ Stonesense art creation guide
55

66
Understanding sprites
77
---------------------
8-
Understanding how Stonesense deals with sprites is central to anyone who wishes to modify the content.
9-
The scheme is not very complicated, and this guide will give a short introduction to how they work.
10-
The way sprites are loaded is fairly generalized. With the exception of floors, which we will discuss later,
11-
all sprites are 32x32 pixels big and come in groups known as Sprite Sheets. All sprites are loaded and
12-
rendered in 32-bit full-color PNGs.
13-
148

159
.. image:: ../images/stonesense-sprite-sample.png
1610
:align: left
@@ -19,28 +13,35 @@ Here's an example of a typical Stonesense sprite.
1913

2014
Note that, in order not to conflict with neighboring sprites, a sprite must actually be within a smaller
2115
area than its 32x32 block.
22-
A template for the area used by most sprites is:
16+
A template for the area used by sprites is:
2317

2418
.. image:: ../images/stonesense-sprite-template.png
2519
:align: left
2620

2721
The solid area is the floor space taken up by a sprite, while the dotted box indicates the volume above this
2822
area corresponding to one z-level.
2923

24+
Understanding how Stonesense deals with sprites is central to anyone who wishes to modify the content.
25+
The scheme is not very complicated, and this guide will give a short introduction to how they work.
26+
The way sprites are loaded is fairly generalized. With the exception of floors, which we will discuss later,
27+
all sprites are 32x32 pixels big and come in groups known as Sprite Sheets. All sprites are loaded and
28+
rendered in 32-bit full-color PNGs. The image files should have a transparent background but pure magenta
29+
(RGB: 255,0,255) is also treated as transparent.
30+
3031
Sprite sheets
3132
-------------
32-
There can be an arbitrary number of sprite sheets configured for Stonesense, yet some are always present as
33-
they contain default sprites (see further down). Most of the content XML files allow users to specify sprite
34-
sheets, and this is done by adding a file attribute to the content nodes. By convention sprite sheets should
35-
be placed in their appropriate folder, with creature sprite sheets in the creatures folder etc.
33+
There can be an arbitrary number of sprite sheets configured for Stonesense, though there are 3 sheets that are
34+
always present as they contain default sprites (see further down). Most of the content XML files allow users to
35+
specify sprite sheets, and this is done by adding a file attribute to the content nodes. By convention sprite
36+
sheets should be placed in their appropriate folder, with creature sprite sheets in the creatures folder etc.
3637

3738
Sprite index
3839
------------
3940
Sprite Index (sometimes referred to as Sheet Index) is a concept for referring to a specific sprite on a sheet.
4041
The index starts with the upper left sprite which has index zero. It then increments to the right. Stonesense
41-
is hardcoded to 20 sprites wide sheets, this means that the last sprite to the right in the first row has Sprite
42-
Index 19. The first sprite on the second row has index 20. This boundary is hardcoded and changing the size of
43-
the sheet will not affect it.
42+
is hardcoded to 20 sprites wide sheets, this means that anything past 20 "sprite slots" is ignored, though less
43+
than 20 slots is fine. The first sprite on the second row has index 20, the next row is 40, and so on. This
44+
boundary is hardcoded and changing the size of the sheet will not affect it.
4445

4546
This image shows how sprites are indexed. Note: Grid added for readability.
4647

0 commit comments

Comments
 (0)