]> git.xonotic.org Git - xonotic/xonotic.git/blobdiff - misc/tools/xonotic-map-compiler
map compiler: -minimap: work better with mapinfo bounds and -scale
[xonotic/xonotic.git] / misc / tools / xonotic-map-compiler
index 58c8e6c7aa59b691bbd0ad40216b43ae8f1b3a59..c80e0a92640c08b72682a66ef76638ef1e546ba5 100755 (executable)
@@ -19,19 +19,19 @@ use File::Temp;
        our $Q3MAP2FLAGS = '-fs_forbiddenpath xonotic-data.pk3 -fs_forbiddenpath xonotic-data.pk3dir -fs_forbiddenpath xonotic-nexcompat.pk3 -fs_forbiddenpath xonotic-nexcompat.pk3dir';
 
        # Default flags for the -bsp stage
-       our $BSPFLAGS    = '-meta -samplesize 8 -minsamplesize 4 -mv 1000000 -mi 6000000';
+       our $BSPFLAGS    = '-meta -maxarea -samplesize 8 -mv 1000000 -mi 6000000';
 
        # Default flags for the -vis stage
        our $VISFLAGS    = '';
 
        # Default flags for the -light stage
-       our $LIGHTFLAGS  = '-deluxe -patchshadows -samples 3 -lightmapsize 512 -fast -fastbounce -dirty';
+       our $LIGHTFLAGS  = '-lightmapsearchpower 3 -deluxe -patchshadows -randomsamples -samples 4 -lightmapsize 512 -fast -fastbounce -dirty -bouncegrid -fill';
 
        # Default flags for the -minimap stage
        our $MINIMAPFLAGS = '';
 
        # Default order of commands
-       our $ORDER = 'light,vis,minimap';
+       our $ORDER = 'vis,light';
 
 # end of user changable part
 
@@ -325,7 +325,7 @@ for my $m(@{$options->{maps}})
                                or die "rename ${m}_s.bsp $m.bsp: $!";
                }
                my @o = @{$options->{order}};
-               push @o, qw/light vis minimap/;
+               push @o, qw/light vis/;
                my %o = ();
 
                for(@o)
@@ -347,14 +347,6 @@ for my $m(@{$options->{maps}})
                                                or die "-vis: $?";
                                }
                        }
-                       if($_ eq 'minimap')
-                       {
-                               if(defined $options->{minimap})
-                               {
-                                       q3map2 '-minimap',      @{$options->{minimap}}, "$m.map"
-                                               or die "-minimap: $?";
-                               }
-                       }
                }
 
                if($postscale != 1)
@@ -365,6 +357,12 @@ for my $m(@{$options->{maps}})
                                or die "rename ${m}_s.bsp $m.bsp: $!";
                }
 
+               if(defined $options->{minimap})
+               {
+                       q3map2 '-minimap',      @{$options->{minimap}}, "$m.map"
+                               or die "-minimap: $?";
+               }
+
                unlink "$m.srf";
                unlink "$m.prt";