Add colored branch stairs
Different color for stairs that go to another dungeon branch.
Adds four new glyphs, S_br{up,dn}{stair,ladder}, which use the
same character as normal stairs/ladders, but yellow color.
In tiles, the up/down arrow is yellow-green instead of while-blue.
This feature has been around a lot and is in several different
variants, but this is implemented from scratch so tiles work too.
This commit is contained in:
@@ -1806,6 +1806,7 @@ back_to_glyph(xchar x, xchar y)
|
||||
{
|
||||
int idx;
|
||||
struct rm *ptr = &(levl[x][y]);
|
||||
struct stairway *sway;
|
||||
|
||||
switch (ptr->typ) {
|
||||
case SCORR:
|
||||
@@ -1854,10 +1855,18 @@ back_to_glyph(xchar x, xchar y)
|
||||
idx = S_pool;
|
||||
break;
|
||||
case STAIRS:
|
||||
idx = (ptr->ladder & LA_DOWN) ? S_dnstair : S_upstair;
|
||||
sway = stairway_at(x, y);
|
||||
if (sway && (sway->tolev.dnum != u.uz.dnum))
|
||||
idx = (ptr->ladder & LA_DOWN) ? S_brdnstair : S_brupstair;
|
||||
else
|
||||
idx = (ptr->ladder & LA_DOWN) ? S_dnstair : S_upstair;
|
||||
break;
|
||||
case LADDER:
|
||||
idx = (ptr->ladder & LA_DOWN) ? S_dnladder : S_upladder;
|
||||
sway = stairway_at(x, y);
|
||||
if (sway && (sway->tolev.dnum != u.uz.dnum))
|
||||
idx = (ptr->ladder & LA_DOWN) ? S_brdnladder : S_brupladder;
|
||||
else
|
||||
idx = (ptr->ladder & LA_DOWN) ? S_dnladder : S_upladder;
|
||||
break;
|
||||
case FOUNTAIN:
|
||||
idx = S_fountain;
|
||||
|
||||
Reference in New Issue
Block a user