Renamed Assets to XAssets.
This commit is contained in:
parent
be8aa3691e
commit
729a6bac7c
@ -1,208 +0,0 @@
|
||||
#include "comprimarylight.h"
|
||||
|
||||
ComPrimaryLight::ComPrimaryLight(QObject *aParent)
|
||||
: XAsset(aParent)
|
||||
, mType(-1)
|
||||
, mCanUseShadowMap(-1)
|
||||
, mExponent(-1)
|
||||
, mUnused(-1)
|
||||
, mColor(0, 0, 0)
|
||||
, mDir(0, 0, 0)
|
||||
, mOrigin(0, 0, 0)
|
||||
, mRadius(0.0)
|
||||
, mCosHalfFovOuter(0.0)
|
||||
, mCosHalfFovInner(0.0)
|
||||
, mCosHalfFovExpanded(0.0)
|
||||
, mRotationLimit(0.0)
|
||||
, mTranslationLimit(0.0)
|
||||
, mDefName(new XString(this))
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void ComPrimaryLight::Clear()
|
||||
{
|
||||
delete mDefName;
|
||||
}
|
||||
|
||||
ComPrimaryLightArray *ComPrimaryLight::ParseArray(QDataStream *aStream, int aCount)
|
||||
{
|
||||
ComPrimaryLightArray* result = new ComPrimaryLightArray();
|
||||
|
||||
for (int i = 0; i < aCount; i++)
|
||||
{
|
||||
ComPrimaryLight* comPrimaryLight = new ComPrimaryLight();
|
||||
comPrimaryLight->ParseData(aStream);
|
||||
|
||||
result->append(comPrimaryLight);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::ParseData(QDataStream *aStream)
|
||||
{
|
||||
*aStream
|
||||
>> mType
|
||||
>> mCanUseShadowMap
|
||||
>> mExponent
|
||||
>> mUnused
|
||||
>> mColor
|
||||
>> mDir
|
||||
>> mOrigin
|
||||
>> mRadius
|
||||
>> mCosHalfFovOuter
|
||||
>> mCosHalfFovInner
|
||||
>> mCosHalfFovExpanded
|
||||
>> mRotationLimit
|
||||
>> mTranslationLimit;
|
||||
|
||||
mDefName->ParseData(aStream);
|
||||
}
|
||||
|
||||
quint8 ComPrimaryLight::GetType() const
|
||||
{
|
||||
return mType;
|
||||
}
|
||||
|
||||
quint8 ComPrimaryLight::GetCanUseShadowMap() const
|
||||
{
|
||||
return mCanUseShadowMap;
|
||||
}
|
||||
|
||||
quint8 ComPrimaryLight::GetExponent() const
|
||||
{
|
||||
return mExponent;
|
||||
}
|
||||
|
||||
quint8 ComPrimaryLight::GetUnused() const
|
||||
{
|
||||
return mUnused;
|
||||
}
|
||||
|
||||
QColor ComPrimaryLight::GetColor() const
|
||||
{
|
||||
return mColor;
|
||||
}
|
||||
|
||||
QVector3D ComPrimaryLight::GetDir() const
|
||||
{
|
||||
return mDir;
|
||||
}
|
||||
|
||||
QVector3D ComPrimaryLight::GetOrigin() const
|
||||
{
|
||||
return mOrigin;
|
||||
}
|
||||
|
||||
float ComPrimaryLight::GetRadius() const
|
||||
{
|
||||
return mRadius;
|
||||
}
|
||||
|
||||
float ComPrimaryLight::GetCosHalfFovOuter() const
|
||||
{
|
||||
return mCosHalfFovOuter;
|
||||
}
|
||||
|
||||
float ComPrimaryLight::GetCosHalfFovInner() const
|
||||
{
|
||||
return mCosHalfFovInner;
|
||||
}
|
||||
|
||||
float ComPrimaryLight::GetCosHalfFovExpanded() const
|
||||
{
|
||||
return mCosHalfFovExpanded;
|
||||
}
|
||||
|
||||
float ComPrimaryLight::GetRotationLimit() const
|
||||
{
|
||||
return mRotationLimit;
|
||||
}
|
||||
|
||||
float ComPrimaryLight::GetTranslationLimit() const
|
||||
{
|
||||
return mTranslationLimit;
|
||||
}
|
||||
|
||||
XString* ComPrimaryLight::GetDefName() const
|
||||
{
|
||||
return mDefName;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetType(quint8 aType)
|
||||
{
|
||||
mType = aType;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetCanUseShadowMap(quint8 aCanUseShadowMap)
|
||||
{
|
||||
mCanUseShadowMap = aCanUseShadowMap;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetExponent(quint8 aExponent)
|
||||
{
|
||||
mExponent = aExponent;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetUnused(quint8 aUnused)
|
||||
{
|
||||
mUnused = aUnused;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetColor(const QColor aColor)
|
||||
{
|
||||
mColor = aColor;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetDir(const QVector3D aDir)
|
||||
{
|
||||
mDir = aDir;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetOrigin(const QVector3D aOrigin)
|
||||
{
|
||||
mOrigin = aOrigin;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetRadius(float aRadius)
|
||||
{
|
||||
mRadius = aRadius;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetCosHalfFovOuter(float aCosHalfFovOuter)
|
||||
{
|
||||
mCosHalfFovOuter = aCosHalfFovOuter;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetCosHalfFovInner(float aCosHalfFovInner)
|
||||
{
|
||||
mCosHalfFovInner = aCosHalfFovInner;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetCosHalfFovExpanded(float aCosHalfFovExpanded)
|
||||
{
|
||||
mCosHalfFovExpanded = aCosHalfFovExpanded;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetRotationLimit(float aRotationLimit)
|
||||
{
|
||||
mRotationLimit = aRotationLimit;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetTranslationLimit(float aTranslationLimit)
|
||||
{
|
||||
mTranslationLimit = aTranslationLimit;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetDefName(XString* aDefName)
|
||||
{
|
||||
mDefName = aDefName;
|
||||
}
|
||||
|
||||
void ComPrimaryLight::SetDefName(const QString aDefName)
|
||||
{
|
||||
if (mDefName != nullptr) {
|
||||
mDefName->SetString(aDefName);
|
||||
}
|
||||
}
|
||||
@ -1 +0,0 @@
|
||||
#include "mapent.h"
|
||||
@ -1,11 +0,0 @@
|
||||
#ifndef MAPENT_H
|
||||
#define MAPENT_H
|
||||
|
||||
struct MapEnts
|
||||
{
|
||||
const char *name;
|
||||
char *entityString;
|
||||
int numEntityChars;
|
||||
};
|
||||
|
||||
#endif // MAPENT_H
|
||||
@ -1 +0,0 @@
|
||||
#include "soundalias.h"
|
||||
@ -1,103 +0,0 @@
|
||||
#ifndef SOUNDALIAS_H
|
||||
#define SOUNDALIAS_H
|
||||
|
||||
#include "soundcurve.h"
|
||||
#include "loadedsound.h"
|
||||
|
||||
struct StreamFileNameRaw
|
||||
{
|
||||
const char *dir;
|
||||
const char *name;
|
||||
};
|
||||
|
||||
struct StreamFileNamePacked
|
||||
{
|
||||
unsigned int offset;
|
||||
unsigned int length;
|
||||
};
|
||||
|
||||
union StreamFileInfo
|
||||
{
|
||||
StreamFileNameRaw raw;
|
||||
StreamFileNamePacked packed;
|
||||
};
|
||||
|
||||
struct StreamFileName
|
||||
{
|
||||
unsigned int fileIndex;
|
||||
StreamFileInfo info;
|
||||
};
|
||||
|
||||
struct StreamedSound
|
||||
{
|
||||
StreamFileName filename;
|
||||
};
|
||||
|
||||
union SoundFileRef
|
||||
{
|
||||
LoadedSound *loadSnd;
|
||||
StreamedSound streamSnd;
|
||||
};
|
||||
|
||||
struct SoundFile
|
||||
{
|
||||
unsigned __int8 type;
|
||||
unsigned __int8 exists;
|
||||
SoundFileRef u;
|
||||
};
|
||||
|
||||
struct XAUDIOCHANNELMAPENTRY
|
||||
{
|
||||
unsigned __int8 InputChannel;
|
||||
unsigned __int8 OutputChannel;
|
||||
float Volume;
|
||||
};
|
||||
|
||||
struct XAUDIOCHANNELMAP
|
||||
{
|
||||
unsigned __int8 EntryCount;
|
||||
XAUDIOCHANNELMAPENTRY *paEntries;
|
||||
};
|
||||
|
||||
struct SpeakerMap
|
||||
{
|
||||
bool isDefault;
|
||||
const char *name;
|
||||
XAUDIOCHANNELMAP channelMaps[2][2];
|
||||
};
|
||||
|
||||
struct snd_alias_t
|
||||
{
|
||||
const char *aliasName;
|
||||
const char *subtitle;
|
||||
const char *secondaryAliasName;
|
||||
const char *chainAliasName;
|
||||
SoundFile *soundFile;
|
||||
int sequence;
|
||||
float volMin;
|
||||
float volMax;
|
||||
float pitchMin;
|
||||
float pitchMax;
|
||||
float distMin;
|
||||
float distMax;
|
||||
int flags;
|
||||
float slavePercentage;
|
||||
float probability;
|
||||
float lfePercentage;
|
||||
float centerPercentage;
|
||||
int startDelay;
|
||||
SoundCurve *volumeFalloffCurve;
|
||||
float envelopMin;
|
||||
float envelopMax;
|
||||
float envelopPercentage;
|
||||
SpeakerMap *speakerMap;
|
||||
};
|
||||
|
||||
struct SoundAliasList
|
||||
{
|
||||
const char *aliasName;
|
||||
snd_alias_t *head;
|
||||
int count;
|
||||
};
|
||||
|
||||
#endif // SOUNDALIAS_H
|
||||
@ -1 +0,0 @@
|
||||
#include "soundcurve.h"
|
||||
@ -1,11 +0,0 @@
|
||||
#ifndef SOUNDCURVE_H
|
||||
#define SOUNDCURVE_H
|
||||
|
||||
struct SoundCurve
|
||||
{
|
||||
const char *filename;
|
||||
int knotCount;
|
||||
float knots[8][2];
|
||||
};
|
||||
|
||||
#endif // SOUNDCURVE_H
|
||||
@ -1,21 +0,0 @@
|
||||
#include "xsoundfile.h"
|
||||
|
||||
XSoundFile::XSoundFile()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
XSoundFile::~XSoundFile()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void XSoundFile::ParseData(QDataStream *aStream)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void XSoundFile::Clear()
|
||||
{
|
||||
|
||||
}
|
||||
@ -1,23 +0,0 @@
|
||||
#ifndef XSOUNDFILE_H
|
||||
#define XSOUNDFILE_H
|
||||
|
||||
#include "xasset.h"
|
||||
|
||||
class XSoundFileRef;
|
||||
|
||||
class XSoundFile : public XAsset
|
||||
{
|
||||
public:
|
||||
XSoundFile();
|
||||
~XSoundFile();
|
||||
|
||||
virtual void ParseData(QDataStream* aStream) override;
|
||||
virtual void Clear() override;
|
||||
|
||||
private:
|
||||
quint8 mType;
|
||||
quint8 mExists;
|
||||
XSoundFileRef* mRef;
|
||||
};
|
||||
|
||||
#endif // XSOUNDFILE_H
|
||||
@ -1,7 +0,0 @@
|
||||
#include "xmapents.h"
|
||||
|
||||
XMapEnts::XMapEnts()
|
||||
: XAsset()
|
||||
{
|
||||
|
||||
}
|
||||
@ -1,15 +0,0 @@
|
||||
#ifndef XMAPENTS_H
|
||||
#define XMAPENTS_H
|
||||
|
||||
#include "xasset.h"
|
||||
|
||||
class XMapEnts : public XAsset
|
||||
{
|
||||
public:
|
||||
XMapEnts();
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
#endif // XMAPENTS_H
|
||||
@ -4,7 +4,7 @@ SUBDIRS += core \
|
||||
compression \
|
||||
encryption \
|
||||
fastfile \
|
||||
assets \
|
||||
xassets \
|
||||
zonefile \
|
||||
ddsfile \
|
||||
iwifile \
|
||||
|
||||
@ -11,7 +11,7 @@
|
||||
#include "soundcurve.h"
|
||||
#include "loadedsound.h"
|
||||
#include "clipmap.h"
|
||||
#include "comworld.h"
|
||||
#include "xcomworld.h"
|
||||
#include "gameworld.h"
|
||||
#include "mapent.h"
|
||||
#include "gfxworld.h"
|
||||
@ -2525,9 +2525,9 @@ void Assets::Load_operandInternalDataUnion(QDataStream *aStream)
|
||||
|
||||
|
||||
// ?Load_ComPrimaryLight@@YAX_N@Z at 0x822a6098
|
||||
ComPrimaryLight Assets::Load_ComPrimaryLight(QDataStream *aStream)
|
||||
XComPrimaryLight Assets::Load_ComPrimaryLight(QDataStream *aStream)
|
||||
{
|
||||
ComPrimaryLight result;
|
||||
XComPrimaryLight result;
|
||||
|
||||
*aStream
|
||||
>> result.type
|
||||
@ -3630,12 +3630,12 @@ Operand Assets::Load_Operand(QDataStream *aStream)
|
||||
|
||||
|
||||
// ?Load_ComPrimaryLightArray@@YAX_NH@Z at 0x822a79d0
|
||||
QVector<ComPrimaryLight> Assets::Load_ComPrimaryLightArray(QDataStream *aStream, int count)
|
||||
QVector<XComPrimaryLight> Assets::Load_ComPrimaryLightArray(QDataStream *aStream, int count)
|
||||
{
|
||||
QVector<ComPrimaryLight> result;
|
||||
QVector<XComPrimaryLight> result;
|
||||
|
||||
for (int i = 0; i < count; i++) {
|
||||
ComPrimaryLight comPrimaryLight;
|
||||
XComPrimaryLight comPrimaryLight;
|
||||
|
||||
*aStream
|
||||
>> comPrimaryLight.type
|
||||
@ -1119,7 +1119,7 @@ struct clipMap_t
|
||||
uint checksum;
|
||||
};
|
||||
|
||||
struct ComPrimaryLight
|
||||
struct XComPrimaryLight
|
||||
{
|
||||
quint8 type;
|
||||
quint8 canUseShadowMap;
|
||||
@ -1145,7 +1145,7 @@ struct ComWorld
|
||||
int isInUse;
|
||||
uint primaryLightCount;
|
||||
qint32 primaryLightsPtr;
|
||||
QVector<ComPrimaryLight> primaryLights;
|
||||
QVector<XComPrimaryLight> primaryLights;
|
||||
};
|
||||
|
||||
enum nodeType : qint32
|
||||
@ -3051,7 +3051,7 @@ private:
|
||||
RawFile Load_RawFile(QDataStream *aStream);
|
||||
XLocalizeEntry Load_LocalizeEntry(QDataStream *aStream);
|
||||
void Load_operandInternalDataUnion(QDataStream *aStream);
|
||||
ComPrimaryLight Load_ComPrimaryLight(QDataStream *aStream);
|
||||
XComPrimaryLight Load_ComPrimaryLight(QDataStream *aStream);
|
||||
CollisionPartition Load_CollisionPartition(QDataStream *aStream);
|
||||
CLeafBrushNodeLeaf Load_CLeafBrushNodeLeaf(QDataStream *aStream, int leafBrushCount);
|
||||
CLeafBrushNodeData Load_CLeafBrushNodeData(QDataStream *aStream, int aNodeCount);
|
||||
@ -3092,7 +3092,7 @@ private:
|
||||
void Load_LocalizeEntryPtr(QDataStream *aStream);
|
||||
MultiDef Load_MultiDef(QDataStream *aStream);
|
||||
Operand Load_Operand(QDataStream *aStream);
|
||||
QVector<ComPrimaryLight> Load_ComPrimaryLightArray(QDataStream *aStream, int count);
|
||||
QVector<XComPrimaryLight> Load_ComPrimaryLightArray(QDataStream *aStream, int count);
|
||||
CBrushSide Load_cbrushside_t(QDataStream *aStream);
|
||||
CBrush Load_CBrush(QDataStream *aStream);
|
||||
QVector<CollisionPartition> Load_CollisionPartitionArray(QDataStream *aStream, int count);
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user