Merge pull request #74 from Vulpovile/bugfix/tie_phys_to_fps

Tie physics to FPS
This commit is contained in:
DirtPiper
2022-10-03 20:23:24 -04:00
committed by GitHub
4 changed files with 7 additions and 3 deletions

2
.gitignore vendored
View File

@@ -36,8 +36,6 @@
*.user *.user
*.pdb *.pdb
*.idb *.idb
*.manifest
*.htm
*.res *.res
*.ilk *.ilk
*.dep *.dep

View File

@@ -47,5 +47,7 @@ IDI_ICON1 ICON "FatB3dIcon.ico"
// //
// Manifest resources // Manifest resources
// //
#ifndef _DEBUG
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
1 RT_MANIFEST ".\\Blocks3D.exe.manifest" 1 RT_MANIFEST ".\\Blocks3D.exe.manifest"
#endif

View File

@@ -353,7 +353,7 @@ void Application::onSimulation(RealTime rdt, SimTime sdt, SimTime idt) {
} }
for(int i = 0; i < 6; i++) for(int i = 0; i < 6; i++)
{ {
_dataModel->getEngine()->step(sdt*2); _dataModel->getEngine()->step(0.1F);
} }
onLogic(); onLogic();

View File

@@ -148,7 +148,9 @@ LRESULT CALLBACK G3DProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
int main(int argc, char** argv) { int main(int argc, char** argv) {
#ifndef _DEBUG
try{ try{
#endif
hresult = OleInitialize(NULL); hresult = OleInitialize(NULL);
/* IInternetSecurityManager *pSecurityMgr; /* IInternetSecurityManager *pSecurityMgr;
@@ -214,10 +216,12 @@ int main(int argc, char** argv) {
Globals::mainHwnd = hwndMain; Globals::mainHwnd = hwndMain;
Application app = Application(hwndMain); Application app = Application(hwndMain);
app.run(); app.run();
#ifndef _DEBUG
} }
catch(...) catch(...)
{ {
OnError(-1); OnError(-1);
} }
#endif
return 0; return 0;
} }