Changed: Minor changes
This commit is contained in:
parent
6f5b64a669
commit
4795488385
19 changed files with 128 additions and 112 deletions
|
@ -1120,8 +1120,6 @@ void CPSConstraintMesh::getShapesNames(std::string *shapesNames) const
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//====================================================================================
|
//====================================================================================
|
||||||
void CPSConstraintMesh::setShape(uint index, const std::string &shapeName)
|
void CPSConstraintMesh::setShape(uint index, const std::string &shapeName)
|
||||||
{
|
{
|
||||||
|
@ -1132,7 +1130,6 @@ void CPSConstraintMesh::setShape(uint index, const std::string &shapeName)
|
||||||
_ValidBuild = 0;
|
_ValidBuild = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//====================================================================================
|
//====================================================================================
|
||||||
const std::string &CPSConstraintMesh::getShape(uint index) const
|
const std::string &CPSConstraintMesh::getShape(uint index) const
|
||||||
{
|
{
|
||||||
|
|
|
@ -287,6 +287,7 @@ void CAnimationSetDlg::refresh (BOOL update)
|
||||||
|
|
||||||
// Keyframer ?
|
// Keyframer ?
|
||||||
UTrackKeyframer *keyTrack=dynamic_cast<UTrackKeyframer *>(track);
|
UTrackKeyframer *keyTrack=dynamic_cast<UTrackKeyframer *>(track);
|
||||||
|
|
||||||
if (keyTrack)
|
if (keyTrack)
|
||||||
{
|
{
|
||||||
// Get number of keys
|
// Get number of keys
|
||||||
|
|
|
@ -185,7 +185,6 @@ BOOL CLocatedTargetDlg::OnInitDialog()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
const sint posX = 5;
|
const sint posX = 5;
|
||||||
sint posY = 180;
|
sint posY = 180;
|
||||||
|
|
||||||
|
|
|
@ -111,8 +111,10 @@ void CMeshDlg::OnBrowseShape()
|
||||||
{
|
{
|
||||||
MessageBox(utf8ToTStr(e.what()), _T("shape loading error"));
|
MessageBox(utf8ToTStr(e.what()), _T("shape loading error"));
|
||||||
}
|
}
|
||||||
|
|
||||||
updateMeshErrorString();
|
updateMeshErrorString();
|
||||||
}
|
}
|
||||||
|
|
||||||
UpdateData(FALSE);
|
UpdateData(FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -220,6 +220,7 @@ void CParticleSystemEdit::updateDieOnEventParams()
|
||||||
{
|
{
|
||||||
ew = FALSE;
|
ew = FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
GetDlgItem(IDC_APPLY_AFTER_DELAY)->EnableWindow(ew);
|
GetDlgItem(IDC_APPLY_AFTER_DELAY)->EnableWindow(ew);
|
||||||
|
|
||||||
CString out;
|
CString out;
|
||||||
|
@ -232,6 +233,7 @@ void CParticleSystemEdit::updateDieOnEventParams()
|
||||||
{
|
{
|
||||||
out = _T("???");
|
out = _T("???");
|
||||||
}
|
}
|
||||||
|
|
||||||
GetDlgItem(IDC_APPLY_AFTER_DELAY)->SetWindowText(out);
|
GetDlgItem(IDC_APPLY_AFTER_DELAY)->SetWindowText(out);
|
||||||
((CButton *) GetDlgItem(IDC_AUTO_DELAY))->SetCheck(autoDelay ? 1 : 0);
|
((CButton *) GetDlgItem(IDC_AUTO_DELAY))->SetCheck(autoDelay ? 1 : 0);
|
||||||
}
|
}
|
||||||
|
|
|
@ -386,6 +386,7 @@ CParticleWorkspace::CNode *CParticleWorkspace::addNode(const std::string &filena
|
||||||
{
|
{
|
||||||
relativePath = resultPath;
|
relativePath = resultPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (relativePath.size() >= 2)
|
if (relativePath.size() >= 2)
|
||||||
{
|
{
|
||||||
if (relativePath[0] == '\\' && relativePath[1] != '\\')
|
if (relativePath[0] == '\\' && relativePath[1] != '\\')
|
||||||
|
@ -393,6 +394,7 @@ CParticleWorkspace::CNode *CParticleWorkspace::addNode(const std::string &filena
|
||||||
relativePath = relativePath.substr(1);
|
relativePath = relativePath.substr(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
CNode *newNode = new CNode;
|
CNode *newNode = new CNode;
|
||||||
newNode->init(this);
|
newNode->init(this);
|
||||||
newNode->setRelativePath(relativePath);
|
newNode->setRelativePath(relativePath);
|
||||||
|
|
|
@ -201,10 +201,13 @@ void CSkeletonScaleDlg::setSkeletonToEdit(NL3D::CSkeletonModel *skel, const std
|
||||||
{
|
{
|
||||||
const std::string tabStr = " ";
|
const std::string tabStr = " ";
|
||||||
std::string name = _SkeletonModel->Bones[i].getBoneName();
|
std::string name = _SkeletonModel->Bones[i].getBoneName();
|
||||||
|
|
||||||
// append a tab for easy hierarchy
|
// append a tab for easy hierarchy
|
||||||
uint boneId = i;
|
uint boneId = i;
|
||||||
|
|
||||||
while((boneId=_SkeletonModel->Bones[boneId].getFatherId())!=-1)
|
while((boneId=_SkeletonModel->Bones[boneId].getFatherId())!=-1)
|
||||||
name = tabStr + name;
|
name = tabStr + name;
|
||||||
|
|
||||||
// append to the list
|
// append to the list
|
||||||
_BoneList.AddString(utf8ToTStr(name));
|
_BoneList.AddString(utf8ToTStr(name));
|
||||||
}
|
}
|
||||||
|
|
|
@ -114,6 +114,7 @@ void CSnapshotToolDlg::stringFromRegistry(HKEY hKey, const TCHAR *name, CString
|
||||||
DWORD type;
|
DWORD type;
|
||||||
DWORD size;
|
DWORD size;
|
||||||
LONG result = RegQueryValueEx(hKey, name, NULL, &type, NULL, &size);
|
LONG result = RegQueryValueEx(hKey, name, NULL, &type, NULL, &size);
|
||||||
|
|
||||||
if (type != REG_SZ || result != ERROR_SUCCESS || size == 0)
|
if (type != REG_SZ || result != ERROR_SUCCESS || size == 0)
|
||||||
{
|
{
|
||||||
dest = defaultStr;
|
dest = defaultStr;
|
||||||
|
@ -144,18 +145,22 @@ template <class T, class U> void integralTypeFromRegistry(HKEY hKey, const TCHAR
|
||||||
DWORD type;
|
DWORD type;
|
||||||
DWORD size;
|
DWORD size;
|
||||||
LONG result = RegQueryValueEx(hKey, name, NULL, &type, NULL, &size);
|
LONG result = RegQueryValueEx(hKey, name, NULL, &type, NULL, &size);
|
||||||
|
|
||||||
if (type != REG_DWORD || result != ERROR_SUCCESS || size == 0)
|
if (type != REG_DWORD || result != ERROR_SUCCESS || size == 0)
|
||||||
{
|
{
|
||||||
dest = (T) defaultValue;
|
dest = (T) defaultValue;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
DWORD value;
|
DWORD value;
|
||||||
result = RegQueryValueEx(hKey, name, NULL, &type, LPBYTE(&value), &size);
|
result = RegQueryValueEx(hKey, name, NULL, &type, LPBYTE(&value), &size);
|
||||||
|
|
||||||
if (result != ERROR_SUCCESS)
|
if (result != ERROR_SUCCESS)
|
||||||
{
|
{
|
||||||
dest = defaultValue;
|
dest = defaultValue;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
dest = (T) value;
|
dest = (T) value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -175,6 +180,7 @@ void CSnapshotToolDlg::fromRegistry()
|
||||||
NLMISC::splitString(tStrToUtf8(filters), ",", filterList);
|
NLMISC::splitString(tStrToUtf8(filters), ",", filterList);
|
||||||
|
|
||||||
m_Filters.ResetContent();
|
m_Filters.ResetContent();
|
||||||
|
|
||||||
for (uint k = 0; k < filterList.size(); ++k)
|
for (uint k = 0; k < filterList.size(); ++k)
|
||||||
{
|
{
|
||||||
m_Filters.AddString(utf8ToTStr(filterList[k]));
|
m_Filters.AddString(utf8ToTStr(filterList[k]));
|
||||||
|
@ -431,7 +437,6 @@ void CSnapshotToolDlg::OnGo()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// make sure that the screen can contains the window client area
|
// make sure that the screen can contains the window client area
|
||||||
RECT desktopSize;
|
RECT desktopSize;
|
||||||
::GetClientRect(::GetDesktopWindow(), &desktopSize);
|
::GetClientRect(::GetDesktopWindow(), &desktopSize);
|
||||||
|
|
|
@ -2372,11 +2372,13 @@ INT_PTR CALLBACK MiscDialogCallback (
|
||||||
currentParam->RemanenceShiftingTexture = SendMessage (GetDlgItem (hwndDlg, IDC_REMANENCE_SHIFTING_TEXTURE), BM_GETCHECK, 0, 0);
|
currentParam->RemanenceShiftingTexture = SendMessage (GetDlgItem (hwndDlg, IDC_REMANENCE_SHIFTING_TEXTURE), BM_GETCHECK, 0, 0);
|
||||||
|
|
||||||
GetWindowText (GetDlgItem (hwndDlg, IDC_REMANENCE_SLICE_NUMBER), tmp, 512);
|
GetWindowText (GetDlgItem (hwndDlg, IDC_REMANENCE_SLICE_NUMBER), tmp, 512);
|
||||||
|
|
||||||
uint rsn;
|
uint rsn;
|
||||||
if (NLMISC::fromString(tStrToUtf8(tmp), rsn))
|
if (NLMISC::fromString(tStrToUtf8(tmp), rsn))
|
||||||
{
|
{
|
||||||
currentParam->RemanenceSliceNumber = rsn;
|
currentParam->RemanenceSliceNumber = rsn;
|
||||||
}
|
}
|
||||||
|
|
||||||
GetWindowText (GetDlgItem (hwndDlg, IDC_REMANENCE_SAMPLING_PERIOD), tmp, 512);
|
GetWindowText (GetDlgItem (hwndDlg, IDC_REMANENCE_SAMPLING_PERIOD), tmp, 512);
|
||||||
toFloatMax(tmp, currentParam->RemanenceSamplingPeriod);
|
toFloatMax(tmp, currentParam->RemanenceSamplingPeriod);
|
||||||
GetWindowText (GetDlgItem (hwndDlg, IDC_REMANENCE_ROLLUP_RATIO), tmp, 512);
|
GetWindowText (GetDlgItem (hwndDlg, IDC_REMANENCE_ROLLUP_RATIO), tmp, 512);
|
||||||
|
|
|
@ -435,6 +435,7 @@ public:
|
||||||
CBankManager ()
|
CBankManager ()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
const NL3D::CTileBank& getBank (std::string& path=GetBankPathName ())
|
const NL3D::CTileBank& getBank (std::string& path=GetBankPathName ())
|
||||||
{
|
{
|
||||||
if (path!=_lastPath)
|
if (path!=_lastPath)
|
||||||
|
|
|
@ -1296,6 +1296,7 @@ void CTView::DrawTile(tilelist::iterator i,CDC *pDC,int clear, int n)
|
||||||
{
|
{
|
||||||
Name = NLMISC::toString("%d", i->id);
|
Name = NLMISC::toString("%d", i->id);
|
||||||
}
|
}
|
||||||
|
|
||||||
rect_txt.top = pt.y + sizetile_y + spacing_tile_text;
|
rect_txt.top = pt.y + sizetile_y + spacing_tile_text;
|
||||||
rect_txt.bottom += rect_txt.top + sizetext_y;
|
rect_txt.bottom += rect_txt.top + sizetext_y;
|
||||||
rect_txt.left -= spacing_x;
|
rect_txt.left -= spacing_x;
|
||||||
|
|
|
@ -920,7 +920,6 @@ void CGraphPlugin::unsetDlgGraph()
|
||||||
_PluginActive=false;
|
_PluginActive=false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void CGraphPlugin::doSelection(const string& primPath)
|
void CGraphPlugin::doSelection(const string& primPath)
|
||||||
{
|
{
|
||||||
IPrimitive *rootNode;
|
IPrimitive *rootNode;
|
||||||
|
|
|
@ -89,8 +89,10 @@ MissionCompilerMainWindow::MissionCompilerMainWindow(QWidget *parent) :
|
||||||
settings->endGroup();
|
settings->endGroup();
|
||||||
|
|
||||||
NLLIGO::Register();
|
NLLIGO::Register();
|
||||||
|
|
||||||
// TODO try/catch exception. Crashes if path invalid.
|
// TODO try/catch exception. Crashes if path invalid.
|
||||||
try{
|
try
|
||||||
|
{
|
||||||
m_ligoConfig.readPrimitiveClass(NLMISC::CPath::lookup("world_editor_classes.xml").c_str(), false);
|
m_ligoConfig.readPrimitiveClass(NLMISC::CPath::lookup("world_editor_classes.xml").c_str(), false);
|
||||||
}
|
}
|
||||||
catch(const NLMISC::Exception &e)
|
catch(const NLMISC::Exception &e)
|
||||||
|
|
Loading…
Reference in a new issue