inline std::string join(const std::string& dir, const std::string& path) { char last = dir.size() ? DIR_BACK(dir) : '\0'; std::string sep; if (last != '/' && last != '\\') sep = "/"; return dir + sep + path; }
void bridgefall(struct sctstr *sp) { int i; struct sctstr sect; int nx; int ny; for (i = 1; i <= 6; i++) { nx = sp->sct_x + diroff[i][0]; ny = sp->sct_y + diroff[i][1]; getsect(nx, ny, §); if (sect.sct_type == SCT_BSPAN && !bridge_support_at(§, DIR_BACK(i))) { knockdown(§); putsect(§); } } }