Cataclysm-dda: Using a pickaxe on a sidewalk or a road creates an "open roof" not ground that can be dug / made into a pit

Created on 8 Aug 2018  路  6Comments  路  Source: CleverRaven/Cataclysm-DDA

Game version: Experimental build #7666

Operating system: Win10

Tiles or curses: Tiles

Mods active:
"dda",
"filthy_morale",
"no_npc_food",
"novitamins",
"Tolerate_This",
"ExArch",
"Medieval_Stuff",
"More_Survival_Tools",
"nw_pack",
"alt_map_key",
"npc_traits",
"mxocosmetics",
"mutant_npcs",
"Urban_Development",
"boats",
"deoxymod",
"blazemod",
"more_classes_scenarios",
"no_reviving_zombies",
"StatsThroughSkills"

Expected behavior

Using a pickaxe om a regular floor, pavement, etc should produce a dirt floor.

Actual behavior

Inside a house, it seems to cause the ceiling to cave in, and produces a flat roof tile. That might actually be whats intended.

Outside, however, on pavement or a sidewalk, it creates a tile "flat roof", as well as producing some rock and rebar.

Steps to reproduce the behavior

(S2 - Confirmed) Fields / Furniture / Terrain / Traps Items / Item Actions / Item Qualities

All 6 comments

i think you may have forgotten something

Whoops. yes, fixed.

I'm curious if one of the mods is to blame for this... I was unable to reproduce this bug in vanilla.

I used the pickaxe and destroyed pavement and got dirt, then destroyed sidewalk and got dirt, then went into a building and destroyed the floor which collapsed the roof too and I got dirt, tried another building with linoleum tile and still got dirt. (Using vanilla, 0.C-7699)

Did you have experimental z-levels on? That's a requirement to reproduce
the probably related explosion issue.

Yep, z-levels is the culprit. Should have figure that one out myself

The culprit is to be found in map.cpp line 3128

tripoint below( p.x, p.y, p.z - 1 );
const auto roof = get_roof( below, params.bash_floor && ter( below ).obj().movecost != 0 );
ter_set( p, roof );

Something wrong with that get_roof calculation.
Weirdly enough, mining pavement on a roof results in a dirt floor.

Was this page helpful?
0 / 5 - 0 ratings