# -------------------------------------------------------------------------- # # Example PERL code to read SAUCE # # Written by Shivan Bastard # # Copyright 1996 ACiD Productions, All Rights Reserved. # # -------------------------------------------------------------------------- # # Tested under FreeBSD, Linux, and Perl 5.0 # # -------------------------------------------------------------------------- # # # # Building a binary SAUCE structure in PERL would be much too time consum- # # ing. The simple and efficient nature of SAUCE itself allows us to treat # # it's identification like one big 128 byte string. Since PERL was designed # # for manipulating text and strings it is only natural that this would be # # the easiest way to extract the information we need from the SAUCE header. # # -------------------------------------------------------------------------- # open($temp,"$temp"); seek($temp,-128,2); read($temp,$sauce,128); close($temp); $id=$sauce; $id=substr($id,0,5); if ($id eq 'SAUCE') { $name=$sauce; $name=substr($name,7,35); $author=$sauce; $author=substr($author,42,20); $Print "$name by $author"; } SAUCE00PERL SAUCE Reader Shivan Bastard ACiD Productions 19961201P