make paths work in ptloader

This commit is contained in:
David Rose 2003-02-12 15:38:51 +00:00
parent 65888a4846
commit 4077810de6
2 changed files with 6 additions and 0 deletions

View File

@ -30,6 +30,7 @@ SomethingToEggConverter::
SomethingToEggConverter() {
_allow_errors = false;
_path_replace = new PathReplace;
_path_replace->_path_store = PS_absolute;
_animation_convert = AC_none;
_start_frame = 0.0;
_end_frame = 0.0;

View File

@ -89,6 +89,11 @@ load_file(const Filename &path, bool) const {
EggData egg_data;
_converter->set_egg_data(&egg_data, false);
DSearchPath file_path;
file_path.append_directory(path.get_dirname());
_converter->get_path_replace()->_path = file_path;
if (_converter->convert_file(path)) {
egg_data.set_coordinate_system(CS_default);
result = load_egg_data(egg_data);