C:\Irrlicht_examples\new_irr\new_irr\NewtonGame.h(3 : warning C4183: 'MainLoop': missing return type; assumed to be a member function returning 'int'
C:\Irrlicht_examples\new_irr\new_irr\NewtonGame.h(6 5) : error C2143: syntax error : missing ',' before '*'
Process terminated with status 1 (0 minutes, 3 seconds)
13 errors, 12 warnings
This is the one you did.
I'm using vc toolkit 2003 with codeblocks as the ide. I got merciors tut to compile with only 1 warning.
I'm doing a test compile to get my compiler setup correctly for this example. I haven't changed any of your code.
I dont know, I think that dFloat thing might be something. I usually get this kind of error when theres a missing declaration, I think dFloat is defined for Newton, anyway, replace it with its real meaning (float I think) and see what happens.
I took your code above and made a header. Added it to the project and added "using namespace std;
Project : newt7
Compiler : Microsoft Visual C++ Toolkit 2003 (called directly)
Directory : E:\myEngine\Irrlicht_examples\newirr\newirr\
--------------------------------------------------------------------------------
Switching to target: newt7 - Win32 Release
DamageTrigger.cpp
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonBox.h(28) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonSliderDoor.h(46) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonElevator.h(38) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\IrrlichtSwitch.h(29) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(57) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(58) : warning C4183: 'Prepare': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(59) : warning C4183: 'Finish': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(64) : warning C4183: 'Render': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(65) : warning C4183: 'MainLoop': missing return type; assumed to be a member function returning 'int'
ElevatorSwitch.cpp
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonBox.h(28) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\IrrlichtSwitch.h(29) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
FloatTrigger.cpp
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonBox.h(28) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonSliderDoor.h(46) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonElevator.h(38) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\IrrlichtSwitch.h(29) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(57) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(58) : warning C4183: 'Prepare': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(59) : warning C4183: 'Finish': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(64) : warning C4183: 'Render': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(65) : warning C4183: 'MainLoop': missing return type; assumed to be a member function returning 'int'
IrrlichtSwitch.cpp
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonBox.h(28) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\IrrlichtSwitch.h(29) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonSliderDoor.h(46) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonElevator.h(38) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(57) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(58) : warning C4183: 'Prepare': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(59) : warning C4183: 'Finish': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(64) : warning C4183: 'Render': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(65) : warning C4183: 'MainLoop': missing return type; assumed to be a member function returning 'int'
IrrlichtSwitch.cpp(92) : warning C4244: 'argument' : conversion from 'int' to 'const irr::f32', possible loss of data
MaterialData.cpp
MountedElevator.cpp
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonElevator.h(38) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonElevator.h(69) : error C2146: syntax error : missing ';' before identifier 'OnInitRayCast'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonElevator.h(69) : error C2143: syntax error : missing ',' before '*'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonElevator.h(69) : warning C4183: 'OnInitRayCast': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonBox.h(28) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonSliderDoor.h(46) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\IrrlichtSwitch.h(29) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(57) : warning C4183: 'Init': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(58) : warning C4183: 'Prepare': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(59) : warning C4183: 'Finish': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(64) : warning C4183: 'Render': missing return type; assumed to be a member function returning 'int'
e:\myEngine\Irrlicht_examples\newirr\newirr\NewtonGame.h(65) : warning C4183: 'MainLoop': missing return type; assumed to be a member function returning 'int'
Process terminated with status 1 (0 minutes, 23 seconds)
2 errors, 40 warnings
I'm beginning to not like newton and raknet. Too many compiler errors when there really should be none becouse these are precompiled examples.
If it exists in the real world, it can be created in 3d
I got it to compile in Code::Blocks with the toolkit by changing all of the dFloats to regular floats. It still had several warnings but it did compile and run perfectly.
"The creation of something new is not accomplished by the intellect but by the play instinct acting from inner necessity. The creative mind plays with the objects it loves."