Just an update. I ported all Archer and Atalanta heads (up to Tier 4) and bodies (up to D022/mB022) over to Unity. Currently working on the interfaces.
Have some problems with rendering double sided transparent objects on top of each other. There must be a way to do this correctly since an over 15 year old game can do it. I'm probably overlooking something simple...
------------------------------ Update -----------------------------
Found 3 not-very-elegant ways to fix the double sided transparent materials...
1) The first option is to do two shader passes, meaning there is an additional gpu drawcall per object. There still are some rare cases that it still is rendered wrong.
2) Second option is to simply not render a part of the texture with an alpha value of approximately 0. It's fine for desktops but can be hard on mobile devices (since it should work cross platform).
3) Third is to duplicate the normals.
Think I will go with the second option for now. Took me way too long to figure out how to do this...
Did some more user interface too.
------------------------------ Update -----------------------------
Refined the camera controls. Added manual, auto and locked mode.
------------------------------ Update -----------------------------
Managed to get the data part of the inventory to work with some dummy items.
I'm using two 3D arrays of size [2, 12, 6], however, the size can easily be increased or pages can be added. One of the arrays contains the actual items, the other contains the index of the item at every index taken up by the item. So for example:
Item 01 has a size of 1x1 and is stored at [1, 3].
Item 02 has a size of 2x2 and is stored at [2, 1].
Just like in PT the item is added to the first possible spot when picked up. At first I was making a dumb mistake with the loops causing it to keep saying there was not enough room in the inventory... Gave me a headache for a while.
Still some improvements can be made but i'm too lazy. Since the default inventory is only 2x12x6 these optimizations wouldn't matter that much anyway.
(I could for example keep track of how many free slots are still free on page 1 and 2. If the item needs more slots that page can be skipped.)
------------------------------ Update -----------------------------
Only took me a little over 3 hours to get this working. Created a dummy item that contain an image, a width, height and name. The item can be attached to a script which makes an object clickable.
When the object is clicked the script tries to store the item in the inventory array. Only if this succeeds the clickable object is removed.
I can't move the items around in the inventory yet.
------------------------------ Update -----------------------------
Added functionality to move items around in the inventory. Will be doing some graphical aspects of the inventory soon. Currently I use a keyboard shortcut to move the first item to a set position.
------------------------------ Update -----------------------------
I will update what i'm working on in the first post of this thread.