--- deliantra/server/random_maps/layout.C 2017/01/29 02:47:05 1.32 +++ deliantra/server/random_maps/layout.C 2018/11/17 23:40:02 1.34 @@ -1,6 +1,7 @@ /* * This file is part of Deliantra, the Roguelike Realtime MMORPG. * + * Copyright (©) 2017,2018 Marc Alexander Lehmann / the Deliantra team * Copyright (©) 2010,2011,2012,2013,2014,2015,2016 Marc Alexander Lehmann / Robin Redeker / the Deliantra team * Copyright (©) 1994-2004 Crossfire Development Team (restored, original file without copyright notice) * @@ -25,7 +26,7 @@ #include #include -void noinline +ecb_noinline void layout::alloc (int w, int h) { assert (sizeof (cell) == 1); @@ -76,14 +77,14 @@ sfree ((char *)data, size); } -void noinline +ecb_noinline void layout::fill (char fill) { //memset (data [0], fill, w * h); // only when contiguous :/ fill_rect (0, 0, w, h, fill); } -void noinline +ecb_noinline void layout::replace (char from, char to) { for (int x = 0; x < w; ++x) @@ -92,7 +93,7 @@ data [x][y] = to; } -void noinline +ecb_noinline void layout::rect (int x1, int y1, int x2, int y2, char fill) { --x2; @@ -104,7 +105,7 @@ data [x1][y1] = data [x1][y2 - 1] = fill; } -void noinline +ecb_noinline void layout::fill_rect (int x1, int y1, int x2, int y2, char fill) { for (; x1 < x2; ++x1) @@ -117,7 +118,7 @@ rect (0, 0, w, h, fill); } -void noinline +ecb_noinline void layout::fill_rand (int percent) { percent = lerp (percent, 0, 100, 0, 256); @@ -130,7 +131,7 @@ ///////////////////////////////////////////////////////////////////////////// // erode by cellular automata -void noinline +ecb_noinline void layout::erode_1_2 (int c1, int c2, int repeat) { layout neu (w, h); @@ -206,7 +207,7 @@ typedef fixed_stack pointlist; -static void noinline +ecb_noinline static void push_flood_fill (layout &dist, pointlist &seeds, int x, int y) { if (dist [x][y]) @@ -277,7 +278,7 @@ // isolation remover, works on a "distance" map // the map must be initialised with 0 == rooms, 255 = walls -static void noinline +ecb_noinline static void isolation_remover (layout &dist, unsigned int perturb = 2) { // dist contains @@ -535,7 +536,7 @@ * 4 match on (i+1, j+1) * and the possible combinations thereof. */ -static int noinline +ecb_noinline static int calc_pattern (char ch, layout &maze, int i, int j) { int pattern = 0;