ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/lib/collect.pl.in
(Generate patch)

Comparing deliantra/server/lib/collect.pl.in (file contents):
Revision 1.5 by root, Thu Feb 8 02:21:18 2007 UTC vs.
Revision 1.7 by elmex, Sun Feb 11 09:31:28 2007 UTC

231 $pathto = ""; 231 $pathto = "";
232 } 232 }
233 open(ARC,$arch) || &die("cannot open ".$arch); 233 open(ARC,$arch) || &die("cannot open ".$arch);
234line: while(<ARC>) { 234line: while(<ARC>) {
235 chop; 235 chop;
236 ($var,@values) = split;
237 if ($var =~ /^\s*(?:#?.*|)$/) { 236 if (/^\s*(?:#.*|)$/) {
238 #developper comment, switch to next line 237 # comment, skip line
239 $commentNum++; 238 $commentNum++;
240 next line; 239 next line;
241 } elsif ($var eq "Object") { 240 }
241 ($var, @values) = split;
242 if ($var =~ /^[Oo]bject$/) {
242 $lface[0] = ""; 243 $lface[0] = "";
243 $#lface = 0; 244 $#lface = 0;
244 $lfg = ""; 245 $lfg = "";
245 $lbg = ""; 246 $lbg = "";
246 $lvis = ""; 247 $lvis = "";
257 } 258 }
258 } 259 }
259 if ($walkon && !$nopick) { 260 if ($walkon && !$nopick) {
260 &warn("File $arch has an object with walk_on set which can be picked up\n"); 261 &warn("File $arch has an object with walk_on set which can be picked up\n");
261 } 262 }
263 print ARCH "editor_folder $pathto\n" if $pathto ne "";
262 # Process the color/face info now 264 # Process the color/face info now
263 } elsif ($var eq "color_fg") { 265 } elsif ($var eq "color_fg") {
264 $lfg = $values[0]; 266 $lfg = $values[0];
265 next line; 267 next line;
266 } elsif ($var eq "color_bg") { 268 } elsif ($var eq "color_bg") {
267 $lbg = $values[0]; 269 $lbg = $values[0];
268 next line; 270 next line;
269 } elsif ($var eq "end") {
270 print ARCH "editor_folder $pathto\n" if $pathto ne "";
271 } elsif ($var eq "visibility") { 271 } elsif ($var eq "visibility") {
272 $lvis = $values[0]; 272 $lvis = $values[0];
273 next line; 273 next line;
274 } elsif ($var eq "magicmap") { 274 } elsif ($var eq "magicmap") {
275 $mm = $values[0]; 275 $mm = $values[0];
294 # through 294 # through
295 } elsif ($var eq "no_pick") { 295 } elsif ($var eq "no_pick") {
296 $nopick = $values[0]; 296 $nopick = $values[0];
297 } elsif ($var eq "walk_on") { 297 } elsif ($var eq "walk_on") {
298 $walkon = $values[0]; 298 $walkon = $values[0];
299 } elsif ($var eq "face" && ! $faces{$values[0]}) {
300 &warn($arch." is missing face ".$values[0])
299 } elsif ($var eq "face") { 301 } elsif ($var eq "face") {
300 $lface[$#lface++] = $values[0] 302 $lface[$#lface++] = $values[0]
301 } elsif ($var eq "anim") { 303 } elsif ($var eq "anim") {
302 if ($anim{$arch}) { 304 if ($anim{$arch}) {
303 &warn("$arch is a duplicate animation name"); 305 &warn("$arch is a duplicate animation name");
316 } 318 }
317 $anim{$arch} .= "$var\n"; 319 $anim{$arch} .= "$var\n";
318 } 320 }
319 print ARCH "animation $arch\n"; 321 print ARCH "animation $arch\n";
320 next line; # don't want the mina 322 next line; # don't want the mina
321 } elsif ($var eq "face" && ! $faces{$values[0]}) {
322 &warn($arch." is missing face ".$values[0])
323 } elsif ($var eq "smoothface") { 323 } elsif ($var eq "smoothface") {
324 if ($smoothing{$values[0]} && ($smoothing{$values[0]} ne $values[1])) { 324 if ($smoothing{$values[0]} && ($smoothing{$values[0]} ne $values[1])) {
325 &warn($arch." duplicate smoothface for ".$values[0].": ".$smoothing{$values[0]}." and ".$values[1]); 325 &warn($arch." duplicate smoothface for ".$values[0].": ".$smoothing{$values[0]}." and ".$values[1]);
326 } elsif ( ($values[0] eq "") || ($values[1] eq "")) { 326 } elsif ( ($values[0] eq "") || ($values[1] eq "")) {
327 &warn ($arch." incomplete smoothface entry found: ".$values[0]." ".$values[1]); 327 &warn ($arch." incomplete smoothface entry found: ".$values[0]." ".$values[1]);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines