fixed walls not appearing when rooms are next to each other and doubled door thickness
This commit is contained in:
+4
-4
@@ -255,7 +255,7 @@ fn render_pixmap(layout: &DungeonLayout, settings: &UiSettings) -> Result<Pixmap
|
|||||||
fill_bg(&mut pixmap, BG);
|
fill_bg(&mut pixmap, BG);
|
||||||
|
|
||||||
let wall_w = snap_even_width((g.cell / 2.5).max(1.0));
|
let wall_w = snap_even_width((g.cell / 2.5).max(1.0));
|
||||||
let door_w = (g.cell / 10.0).max(1.0).round();
|
let door_w = (g.cell / 5.0).max(1.0).round();
|
||||||
|
|
||||||
if settings.export_show_grid {
|
if settings.export_show_grid {
|
||||||
draw_grid(&mut pixmap, &g);
|
draw_grid(&mut pixmap, &g);
|
||||||
@@ -383,7 +383,7 @@ fn export_composite_masks(
|
|||||||
let g = ExportGeometry::new(settings.cols, settings.rows);
|
let g = ExportGeometry::new(settings.cols, settings.rows);
|
||||||
let scene = collect_scene_data(layout, settings);
|
let scene = collect_scene_data(layout, settings);
|
||||||
let wall_w = (g.cell / 2.5).max(1.0);
|
let wall_w = (g.cell / 2.5).max(1.0);
|
||||||
let door_w = (g.cell / 10.0).max(1.0);
|
let door_w = (g.cell / 5.0).max(1.0);
|
||||||
|
|
||||||
// List of tasks to perform in parallel
|
// List of tasks to perform in parallel
|
||||||
enum MaskTask {
|
enum MaskTask {
|
||||||
@@ -451,7 +451,7 @@ fn export_composite_masks(
|
|||||||
&mut pixmap,
|
&mut pixmap,
|
||||||
&g,
|
&g,
|
||||||
&scene.room_cells,
|
&scene.room_cells,
|
||||||
None,
|
Some(&scene.room_edges),
|
||||||
&scene.door_edges,
|
&scene.door_edges,
|
||||||
wall_w,
|
wall_w,
|
||||||
WHITE,
|
WHITE,
|
||||||
@@ -664,7 +664,7 @@ fn raster_target_size(settings: &UiSettings) -> (u32, u32) {
|
|||||||
pub fn build_svg(layout: &DungeonLayout, settings: &UiSettings) -> String {
|
pub fn build_svg(layout: &DungeonLayout, settings: &UiSettings) -> String {
|
||||||
let g = ExportGeometry::new(settings.cols, settings.rows);
|
let g = ExportGeometry::new(settings.cols, settings.rows);
|
||||||
let wall_w = (g.cell / 2.5).max(1.0);
|
let wall_w = (g.cell / 2.5).max(1.0);
|
||||||
let door_w = (g.cell / 10.0).max(1.0);
|
let door_w = (g.cell / 5.0).max(1.0);
|
||||||
|
|
||||||
let mut s = String::new();
|
let mut s = String::new();
|
||||||
let _ = writeln!(
|
let _ = writeln!(
|
||||||
|
|||||||
+1
-1
@@ -2433,7 +2433,7 @@ fn draw_layout(
|
|||||||
hover_stair_idx: Option<usize>,
|
hover_stair_idx: Option<usize>,
|
||||||
) {
|
) {
|
||||||
let wall_width_px = (geometry.cell_size / 2.5).max(1.0);
|
let wall_width_px = (geometry.cell_size / 2.5).max(1.0);
|
||||||
let door_width_px = (geometry.cell_size / 10.0).max(1.0);
|
let door_width_px = (geometry.cell_size / 5.0).max(1.0);
|
||||||
|
|
||||||
let room_fill = Color32::from_rgb(70, 120, 160);
|
let room_fill = Color32::from_rgb(70, 120, 160);
|
||||||
let corridor_fill = Color32::from_rgb(210, 190, 120);
|
let corridor_fill = Color32::from_rgb(210, 190, 120);
|
||||||
|
|||||||
Reference in New Issue
Block a user