mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2026-03-07 05:23:02 +00:00
WIP: Updating code to follow laupentin's code review.
Done: - Moved custom map structures to their own objcommon header file - Updated GfxLightGridRow struct - Reverted shader_bin file path - Renamed Project Creator to BSP Creator - Removed model loading from BSP creator - Cleaned up BSP Creator and updated the names of structs WIP: - Update BSP calculation code to be more readable and use unique/shared ptrs
This commit is contained in:
@@ -158,100 +158,6 @@ namespace T6
|
||||
|
||||
AUFT_NUM_FIELD_TYPES,
|
||||
};
|
||||
|
||||
struct customMapVertex
|
||||
{
|
||||
vec3_t pos;
|
||||
float binormalSign;
|
||||
float color[4];
|
||||
float texCoord[2];
|
||||
vec3_t normal;
|
||||
vec3_t tangent;
|
||||
unsigned int packedLmapCoord;
|
||||
};
|
||||
|
||||
enum CM_MATERIAL_TYPE
|
||||
{
|
||||
CM_MATERIAL_COLOUR,
|
||||
CM_MATERIAL_TEXTURE,
|
||||
CM_MATERIAL_EMPTY
|
||||
};
|
||||
|
||||
struct customMapMaterial
|
||||
{
|
||||
CM_MATERIAL_TYPE materialType;
|
||||
const char* materialName;
|
||||
};
|
||||
|
||||
struct worldSurface
|
||||
{
|
||||
customMapMaterial material;
|
||||
|
||||
//char lightmapIndex;
|
||||
//char primaryLightIndex;
|
||||
//char reflectionProbeIndex;
|
||||
|
||||
int triCount;
|
||||
int firstVertexIndex;
|
||||
int firstIndex_Index;
|
||||
};
|
||||
|
||||
struct customMapGfx
|
||||
{
|
||||
int vertexCount;
|
||||
customMapVertex* vertices;
|
||||
|
||||
int indexCount;
|
||||
uint16_t* indices;
|
||||
|
||||
int surfaceCount;
|
||||
worldSurface* surfaces;
|
||||
};
|
||||
|
||||
struct customMapColVertex
|
||||
{
|
||||
vec3_t pos;
|
||||
};
|
||||
|
||||
struct collisionSurface
|
||||
{
|
||||
int triCount;
|
||||
int firstVertexIndex;
|
||||
int firstIndex_Index;
|
||||
};
|
||||
|
||||
struct customMapCol
|
||||
{
|
||||
int vertexCount;
|
||||
customMapColVertex* vertices;
|
||||
|
||||
int indexCount;
|
||||
uint16_t* indices;
|
||||
|
||||
int surfaceCount;
|
||||
collisionSurface* surfaces;
|
||||
};
|
||||
|
||||
struct customMapModel
|
||||
{
|
||||
std::string name;
|
||||
|
||||
vec3_t origin;
|
||||
vec3_t rotation; // euler rotation in degrees
|
||||
float scale;
|
||||
};
|
||||
|
||||
struct customMapInfo
|
||||
{
|
||||
std::string name;
|
||||
std::string bspName;
|
||||
|
||||
customMapGfx gfxInfo;
|
||||
customMapGfx colInfo;
|
||||
|
||||
size_t modelCount;
|
||||
customMapModel* models;
|
||||
};
|
||||
|
||||
using AssetPhysPreset = Asset<ASSET_TYPE_PHYSPRESET, PhysPreset>;
|
||||
using AssetPhysConstraints = Asset<ASSET_TYPE_PHYSCONSTRAINTS, PhysConstraints>;
|
||||
|
||||
@@ -1278,30 +1278,16 @@ namespace T6
|
||||
typedef tdef_align32(4) char aligned_byte_pointer;
|
||||
typedef tdef_align32(4) GfxCompressedLightGridCoeffs GfxCompressedLightGridCoeffs_align4;
|
||||
|
||||
struct GfxLightGridUnk
|
||||
{
|
||||
char unknown1;
|
||||
char unknown2;
|
||||
char unknown3;
|
||||
char unknown4;
|
||||
char unknown5;
|
||||
char unknown6;
|
||||
char unknown7;
|
||||
char unknown8;
|
||||
};
|
||||
|
||||
|
||||
struct GfxLightGridRow
|
||||
{
|
||||
unsigned __int16 colStart;
|
||||
unsigned __int16 colCount;
|
||||
unsigned __int16 zStart;
|
||||
unsigned __int16 zCount;
|
||||
uint16_t colStart;
|
||||
uint16_t colCount;
|
||||
uint16_t zStart;
|
||||
uint16_t zCount;
|
||||
unsigned int firstEntry;
|
||||
GfxLightGridUnk unk;
|
||||
char lookupTable[1]; // The lookup table has a variable length
|
||||
};
|
||||
|
||||
|
||||
struct GfxLightGrid
|
||||
{
|
||||
unsigned int sunPrimaryLightIndex;
|
||||
|
||||
Reference in New Issue
Block a user