Page 1 of 2

PRP to OBJ?

PostPosted: Sat Nov 19, 2016 10:30 pm
by TheJasper
Hi,
Is there any way to get the prp file the plasma engine uses to place objects in their world to object files usable for other graphic engines? This would probably result in:

1. Unencrypting the PRP File
2. Extracting Texture and UV Points
3. Converting to OBJ...


Is this possible?

Thanks,
Jdog.

Re: PRP to OBJ?

PostPosted: Sun Nov 20, 2016 1:55 am
by dendwaler
Import prp in blender.
Select the objects in blender.
Export the selected objects as [objectname].fbx file.
Import the fbx file into unreal or unity.
Thats it.
Take care to keep the uv layouts intact.
Re-assign textures to the meshes.

Or did i misunderstood you?
Do you want to "swap" objects inside a prp file
You can do that using blender as well.
Then export the changed prp again.
It has to update the sum files etc.

Re: PRP to OBJ?

PostPosted: Sun Nov 20, 2016 3:37 pm
by TheJasper
Thank You! I assume I need the Korman plugin to import?

Re: PRP to OBJ?

PostPosted: Mon Nov 21, 2016 12:11 am
by dendwaler
I am not sure Korman will import a complete age , i do still use 2.49 b for it.
Another thing is the logic.
You will loose it all and i assume you will keep it intact.
Adding objects will be less difficult because you can simply make an additional prp.file with the new objects inside.
then you don' t have to change existing prp' s except the sum and fni files.
Making changes directly into the prp is more difficult i am not familiar with.
Maybe Deledrius or Sirius can shine light on that.

Re: PRP to OBJ?

PostPosted: Mon Nov 21, 2016 12:37 am
by Sirius
Korman won't import PRPs - I'm not sure if this feature is planned to be added, but for now we should stick to PyPRP on Blender 2.49.
PyPRP won't import the logic, and will fail importing some materials (along with creating a few UV errors). But importing the visuals 1:1 into Blender is simply impossible - both engines are simply too different to work together. And that's without taking exporting into account.

As for editing PRP files, it's doable. But the best solution always depends on what you're looking to do.

If you want to heavily change visuals, import the PRP in Blender, make your edits, and try re-exporting. You'll have a hard time getting everything to work like it used to, though.

If you only want to add new objects, create an entirely new PRP. You can load a Python script in it to disable older objects (like colliders or doors preventing access to your new area), and replace them with your own version (say, disable a wall in the standard PRP and replace it with the same wall but with a hole in it for a door). That's often a preferable solution, and the one used by the Offline-KI.

If you only want to edit the logic but don't want to add visuals, then hacking the PRPs directly may be the better solution ("may", because redistributing a modified PRP is harder).


Although it seems to me TheJasper's question was more oriented towards putting these meshes into another engine - which is YET another matter, with its own set of complications, restrictions, etc.
Actually, it would help to know exactly what you're trying to do, TheJasper.

Re: PRP to OBJ?

PostPosted: Sat Dec 31, 2016 11:30 am
by TheJasper
I don't need logic, just the non-textured mesh itself. However, PYRP doesn't give the option to import PRP on 2.49. Do I need to import some other way?

Re: PRP to OBJ?

PostPosted: Sat Dec 31, 2016 6:39 pm
by Deledrius
TheJasper wrote:I don't need logic, just the non-textured mesh itself. However, PYRP doesn't give the option to import PRP on 2.49. Do I need to import some other way?

You'll need a special separate add-on that Chloe made: https://github.com/GPNMilano/PyPRPImporter

It works great for importing the basic mesh. :)

Re: PRP to OBJ?

PostPosted: Sat Dec 31, 2016 7:12 pm
by TheJasper
Thanks! I just moved the PyPRP Importer scripts into my Blender 2.49 scripts folder, but I don't see an option to import a PRP or AGE file. Does PyPRP need to be installed alongside the import?

Re: PRP to OBJ?

PostPosted: Sun Jan 01, 2017 11:30 am
by TheJasper
TheJasper wrote:Thanks! I just moved the PyPRP Importer scripts into my Blender 2.49 scripts folder, but I don't see an option to import a PRP or AGE file. Does PyPRP need to be installed alongside the import?


Haha, wrong blender version. I now can click on the PyPRP Importer in python, and I can get to the window where I choose the PRP, but when I click PRP, it gives a python error and asks me to check the console. The console displays this message:

raise RuntimeError, "sanity check on Urustring failed!, invalid file, or is corrupted!?"

I will redownload myst files and see if it works

Re: PRP to OBJ?

PostPosted: Sun Jan 01, 2017 2:25 pm
by TheJasper
TheJasper wrote:
TheJasper wrote:Thanks! I just moved the PyPRP Importer scripts into my Blender 2.49 scripts folder, but I don't see an option to import a PRP or AGE file. Does PyPRP need to be installed alongside the import?


Haha, wrong blender version. I now can click on the PyPRP Importer in python, and I can get to the window where I choose the PRP, but when I click PRP, it gives a python error and asks me to check the console. The console displays this message:

raise RuntimeError, "sanity check on Urustring failed!, invalid file, or is corrupted!?"

I will redownload myst files and see if it works



Yup! It works!