Add xphyspreset structures
This commit is contained in:
parent
3a718acb50
commit
e3f971f62c
47
libs/xassets/xphyspreset.cpp
Normal file
47
libs/xassets/xphyspreset.cpp
Normal file
@ -0,0 +1,47 @@
|
||||
#include "xphyspreset.h"
|
||||
|
||||
XPhysPreset::XPhysPreset()
|
||||
: XAsset()
|
||||
, mNamePtr(0)
|
||||
, mName("")
|
||||
, mType(0)
|
||||
, mMass(0)
|
||||
, mBounce(0)
|
||||
, mFriction(0)
|
||||
, mBulletForceScale(0)
|
||||
, mExplosiveForceScale(0)
|
||||
, mSndAliasPrefixPtr(0)
|
||||
, mSndAliasPrefix("")
|
||||
, mPiecesSpreadFraction(0)
|
||||
, mPiecesUpwardVelocity(0)
|
||||
, mTempDefaultToCylinder(false)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
XPhysPreset::~XPhysPreset()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void XPhysPreset::ParseData(QDataStream *aStream)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void XPhysPreset::Clear()
|
||||
{
|
||||
mNamePtr = 0;
|
||||
mName.clear();
|
||||
mType = 0;
|
||||
mMass = 0;
|
||||
mBounce = 0;
|
||||
mFriction = 0;
|
||||
mBulletForceScale = 0;
|
||||
mExplosiveForceScale = 0;
|
||||
mSndAliasPrefixPtr = 0;
|
||||
mSndAliasPrefix.clear();
|
||||
mPiecesSpreadFraction = 0;
|
||||
mPiecesUpwardVelocity = 0;
|
||||
mTempDefaultToCylinder = false;
|
||||
}
|
||||
38
libs/xassets/xphyspreset.h
Normal file
38
libs/xassets/xphyspreset.h
Normal file
@ -0,0 +1,38 @@
|
||||
#ifndef XPHYSPRESET_H
|
||||
#define XPHYSPRESET_H
|
||||
|
||||
#include "xasset.h"
|
||||
|
||||
#include <QString>
|
||||
|
||||
class XPhysPreset : public XAsset
|
||||
{
|
||||
public:
|
||||
XPhysPreset();
|
||||
~XPhysPreset();
|
||||
|
||||
virtual void ParseData(QDataStream* aStream) override;
|
||||
virtual void Clear() override;
|
||||
|
||||
private:
|
||||
qint32 mNamePtr;
|
||||
QString mName;
|
||||
|
||||
int mType;
|
||||
|
||||
float mMass;
|
||||
float mBounce;
|
||||
float mFriction;
|
||||
float mBulletForceScale;
|
||||
float mExplosiveForceScale;
|
||||
|
||||
qint32 mSndAliasPrefixPtr;
|
||||
QString mSndAliasPrefix;
|
||||
|
||||
float mPiecesSpreadFraction;
|
||||
float mPiecesUpwardVelocity;
|
||||
|
||||
bool mTempDefaultToCylinder;
|
||||
};
|
||||
|
||||
#endif // XPHYSPRESET_H
|
||||
Loading…
x
Reference in New Issue
Block a user