/usr/pkg/bin/pod2html: perllib/TrnRead.pm: unterminated list at =head in paragraph 37. ignoring. /usr/pkg/bin/pod2html: perllib/TrnRead.pm: unexpected =item directive in paragraph 42. ignoring. /usr/pkg/bin/pod2html: perllib/TrnRead.pm: unexpected =back directive in paragraph 51. ignoring. TrnRead - Perl Module to Read Trn datastructures

NAME

TrnRead - Perl Module to Read Trn datastructures


ABSTRACT

This module allows easy reading and parsing of the nwn2 trn/trx files. It returns a hash structure having everything from the trn/trx.


DESCRIPTION

The basic working is that you give hash of options to the TrnRead::read, and get Trn object back from there. The data is either read from the string given to the read function, or from the file given to the read function.


TrnRead::read

TrnRead::read is used to read and parse trn structure. Take hash table of options in, and returns a reference to the Trn(3) object back.

USAGE

\%trn = read(%options);

OPTIONS

Following options can be given to the TrnRead::read.


=over 4
filename => filename
Filename to read data from. If this exits, then data is ignored.

data => data
Data buffer to use instead of filename. This only used if filename is no present.

seek_pos => offset
Position to seek in file or data.

return_errors => boolean
If false then die on errors, otherwise return undef on error.


SEE ALSO

trnunpack(1), Trn(3), and TrnWrite(3).


AUTHOR

Tero Kivinen <kivinen@iki.fi>.


HISTORY

Created to do walkmesh height setter.