[CF-Devel] Multipart creatures and maps

crossfire-devel at archives.real-time.com crossfire-devel at archives.real-time.com
Wed Mar 17 05:48:41 CST 2004


My first version DID break those maps:

maps-bigworld/quests/peterm/FireTemple/ThirdFloor
maps-bigworld/wolfsburg/whorehouse

So i made a more pedantic one.
Those are the only maps to show up with diff -rq
comparing output of version 1 and version 2 of the script.

I did not run into any problems with these modified maps
so far.
-------------- next part --------------
#!/usr/bin/perl -w

use strict 'refs';
use strict 'subs';

@files = split /\n/,`find -type f | grep -v "/CVS/"`;

foreach $file (@files)
 {
  open (MAPFILE,$file) or die ("could not open $file\n");
  undef $/;
  $bigstring = <MAPFILE>;
  close MAPFILE;

  if ($bigstring =~ s/^More\narch.*?^end\n//msg) {
    open (MAPFILE,"> $file") or die ("could not open $file for writing\n");
    print MAPFILE $bigstring;
    close MAPFILE;
    print "$file modified\n";
  }
 }

-------------- next part --------------
_______________________________________________
crossfire-devel mailing list
     
     crossfire-devel at lists.real-time.com
     
     
     https://mailman.real-time.com/mailman/listinfo/crossfire-devel
     
     
    


More information about the crossfire mailing list