Page 2 of 3

Posted: Sun Nov 14, 2004 11:43 am
by etcaptor
I'm glad to see that this stuff is developed :D
BTW - This works well with borland compiler too :lol:

Posted: Sun Nov 14, 2004 11:58 am
by etcaptor
In demo, I get player moving or jumping only for the first several seconds, after loading of level??

Posted: Sun Nov 14, 2004 12:01 pm
by bal
etcaptor wrote:In demo, I get player moving or jumping only for the first several seconds, after loading of level??
Same here. Seems like a collision problem with that playernode. It gets stuck at some places (almost everywhere).

Posted: Sun Nov 14, 2004 2:57 pm
by schick

Code: Select all

	void IrrNewtonWorld::UpdateWorld()
	{
		if( m_World && m_Device->isWindowActive())
		{
			// first update
			if( m_LastUpdate == 0)
			{
				m_LastUpdate = m_Device->getTimer()->getTime();
			}
			else if( (m_LastUpdate + m_UpdateRate) >  m_Device->getTimer()->getTime())
			{
				NewtonUpdate( m_World, m_UpdateRate); 
				m_LastUpdate = m_Device->getTimer()->getTime();
			}   
			else
			{
			}  
		}  
	} 
The problems seems to be here:

Code: Select all

		if( m_World && m_Device->isWindowActive())
Ill debug it. Thanks for testing.

yeh i got that too

Posted: Mon Nov 15, 2004 4:56 am
by buhatkj
yeh mine gets stuck too. Also i dunno if anybody mentioned this part: once your stuck, it instead of shooting seems to just place the box a certain distance away in whatever direction you were facing rather than "shooting" it.
I will attempt to help debug it too, but likely schick will find it first since he is of course the most familiar with this code :-)
cheers all
(looking forward to pluggin' this nifty little animator into my game engine)

Posted: Mon Nov 15, 2004 9:18 pm
by Guest
Here is working perfect I am getting 240 fps at work and over 190 at home, the camera is very responsive.
Maybe some gravity and a skin to the shot boxes will make more interesting.
Roberto

Posted: Thu Nov 25, 2004 10:50 am
by etcaptor
Hi schick,
Any news from your project?

Posted: Fri Nov 26, 2004 8:21 am
by schick
Projects news:

Updated to 2.2:

- links against newton 1.30 (be sure you have upgraded)
- bug fixes
- more bug fixes
- some minor changes to the IrrNewtonWorld and the IrrNewtonAnimator interface

ToDo:
- add joints (there is a vehicle joint available)
- add missing rigid bodies
- add all raycast functions

I please you to use the code and test it. I am currently working on another project, too. Therefore my testing time is, give it 3 runs if it works ok :-). Not that good i know.

You can download the demo (well, just a fps camera and some shooting) and the current source here:
http://www.bluffel.de.vu/

The documentation was also updated here:
http://www.bluffel.de.vu/IrrNewton/Docu/

Best regards,

Schick

Posted: Fri Nov 26, 2004 11:43 am
by etcaptor
Ok, thanks.
I still have the same problems with movements like by version 0.2

Posted: Fri Nov 26, 2004 1:24 pm
by Wolf Dreamer
Compiling...
main.cpp
d:\NewtonSDK\sdk\Newton.h(16) : error C2146: syntax error : missing ';' before identifier '_NEWTON_USE_LIB'
d:\NewtonSDK\sdk\Newton.h(16) : error C2501: 'declare' : missing storage-class or type specifiers
d:\NewtonSDK\sdk\Newton.h(16) : error C2144: syntax error : 'int' should be preceded by ';'
d:\NewtonSDK\sdk\Newton.h(16) : error C2501: '_NEWTON_USE_LIB' : missing storage-class or type specifiers
IrrNewton - 4 error(s), 0 warning(s)
I have the latest Newton, and read the readmefirst.txt that came with it, copying what it told me to into the code, but still I get those four errors.

In the newton txt file for the new version is reads
- To link with libraries you will need to declare _NEWTON_USE_LIB before you include newton.h in your project
- if you are linking visual with VS 6. You will need to declare the following in any of you C or C++ modules

#if (_MSC_VER >= 1300)
//VC7 or later, building with pre-VC7 runtime libraries
//defined by VC6 C libs
extern "C" long _ftol (double);
extern "C" long _ftol2( double dblSource )
{
return _ftol( dblSource );
}
#endif
Any suggestions? I got a lot more errors before reading that .txt file and copying over what it says to.

----
When I run the example of your program, I notice that movement speed is very slow. Is that done on purpose?

Shooting the boxes outward is odd since they stop after a certain distance, frozen in midair. I assume it is suppose to do that. I'd rather have each object with a variable called range, which would destroy it after it went a certain distance, so if ever you miss your target, it doesn't keep track of the projectiles movement is it sails off to the end of the massive world most games would have, or hit someone on another continent.

"Those scoundrels! Here we are enjoying a day at the beach, and they send a horde of bullets over at us!"
"Uh... didn't you stand on the beach a few minutes ago and say, hey, check out how cool my new weapon is, then shoot over in their direction first?"
"Curse these weapons with their unlimited range, and the devestation they will surely reek upon our world... then again, I can now slay all monsters from an insane distance."

*yawn* its too early in the morning to be funny. I know its just alpha so that'll probably change.

Artillary shells would be affected by gravity, and arch downward to the ground, while regular bullets/magic fireballs/arrows etc. would fire straight ahead a certain distance before vanishing.

Nice work so far though.

Posted: Sun Nov 28, 2004 11:26 am
by schick
If you like to link to the static library you need that compiler #define for the msvc6. The new static library, not tested myself, but could be be linked under linux, too.

If you link against the dll library, there is no problem linking with msvc6.

The demo is not supposed to be a game demo. It just shows what can be done easily. You only need a few function calls and the hole physic stuff is working.

Cheers,

Schick

Posted: Sat Dec 11, 2004 5:38 pm
by schick
New release of IrrNewton. If you are using IrrNewton, please upgrade.

The random crashing of Newton was fixed.

Grab the source of IrrNewton here: http://www.bluffel.de.vu/

Cheers,

Friedrich Schick

Posted: Sat Dec 18, 2004 3:49 am
by Kaneda

Posted: Tue Dec 21, 2004 11:48 pm
by JoeWright
Friedrich,

Just started using IrrNewton. Great work, thanks.

I've got a problem with the freeing up of resources. IrrNewtonAnimator::StopIrrNewtonAnimator keeps re-entering via the NewtonDestroyBody call so that eventually there is a stack overload.

Not too sure what the problem is, maybe you could have a look.

Thanks

Joe

Posted: Sat Dec 25, 2004 7:34 pm
by schick
I reworked the material system to work with int instead of string. Furthermore, i patched some functions to accurate the speed.

Yeah, you could "fix" the bug just by setting the Newton Body to NULL instead of calling StopIrrNewtonAnimator(). That bug remained from the last Newton SDK, which had some bugs itself and i had to do a workaround.

Code: Select all

m_NewtonBody = NULL;
Cheers,

Schick