Page 5 of 8

Posted: Sat Oct 20, 2007 10:07 am
by federico
the first release features only entities for the editor, the scripting part will come in a second release. I'm working on a set of simply demos to show you how to use the entities.

Posted: Sat Oct 20, 2007 12:53 pm
by federico
another step: you can attach other entities to the Rigid Bodies (DSpotLights, spouts...). :twisted:

Posted: Sun Oct 21, 2007 2:55 am
by federico
closer and better: breakable joints implemented

Posted: Sun Oct 21, 2007 3:09 am
by fps
:shock: man. you are incredibly fast.
you must really put a lot of effort into this.
it looks like its going to come out great.
it really does.

Posted: Sun Oct 21, 2007 12:25 pm
by bernie
:D Federico you are my hero... Great stuff man.

Posted: Sun Oct 21, 2007 1:01 pm
by Juutis
bernie wrote:Federico you are my hero... Great stuff man.
Couldn't put it any better myself! Absolutely fantastic. :D

Posted: Sun Oct 21, 2007 1:20 pm
by federico
Most of those features were here but buggy: now I'm bugfixing them all. This moring I solved the staticMesh collision: Now the the physics world can be extended to the staticmeshes. The last task is to optimize the ragdoll entity. I will release with the two standard skeletons (farcry and valve) then, according to the request I could release a new version with some .ini definitions for the ragdoll parameters, but right now I didn't understand the why-and-how of the parameters I used... So right now you have to stay with my skeletons and enjoy all the other goodies.
I want to release: all this stuff is becoming really hot in my hands... :wink:

I'm putting up a site for the release...

Posted: Mon Oct 22, 2007 11:43 pm
by fps
i cant wait!!!!!!!!!!!!!!!! this is really awsome.
one thing i would like to try to do in the fuure with this is have physics enabled pickup weapons. i think its awsome (altough slightly heartbreaking) to se your oponents weapon fly through the air and clatter loudly to the ground at you feet as you just empty yours into him.
even in system shock 2, when you droped your weapon it clanked loudly. which was both creepy and realistic.
physics really rocks!!!

Posted: Thu Oct 25, 2007 10:02 pm
by kikosmalltalk
Hi federico

Thank you for their attention and forgive my delay to respond.

you wrote:

If you are talking about scale, I don't have any scale, so 1 texel is 1 newton unit.


Yes, on that it is my question !!!.
Now. In their demo, a box has a dimencion of: 5 meters, 30 meters, or ?? . And an mass of ?

Me also use 1 meter = 1 texel.
As I understand, the dimensions and measures are important for Newton correct operation.
It is not the same thing a simulation of a body that measures 100 meters and a mass of 10000 Kg that a body that has 3 meters and a mass of 1000 Kg.

It is for this reason that I reduce my maps to a size of:
500 long
100 high
500 width.

And my car to:
3 long
1.5 high
1.7 width


Code: Select all

//Tick 
float dwTicks = 0.0f; 
dwTicks = (float)(TimeTicks)/IterationTime; 

for (int p = 0; p <(1 + dwTicks); p++) 
{ 
for(int s=0; s<UpdateLoop;s++) 
{ 
NewtonUpdate (nWorld, dwTicks*AdvanceTime); 
} 
}


With the form of solving Newton update.
Don't you have stutterer problems?.

See this article:

http://www.gaffer.org/game-physics/fix-your-timestep/

Best regards, KIKO

Posted: Fri Oct 26, 2007 1:57 am
by federico
Me also use 1 meter = 1 texel.
As I understand, the dimensions and measures are important for Newton correct operation.
It is not the same thing a simulation of a body that measures 100 meters and a mass of 10000 Kg that a body that has 3 meters and a mass of 1000 Kg.
That's not the point, kiko. The physics engine is unit agnostic so that a body of 100meters with a mass of 10000Kg should behave exactly in the same way of a body of 1 meters and 10Kg. Equal ration between dimensions and mass should return the same result. In your example

100meters : 10000Kg != 3meters : 1000Kg

while instead

100meters : 10000Kg = 1meter : 10Kg = 3meters : 30Kg

Anyway, this is true with some limitations, but they doesn't apply for us: In fact all the topic about scale in the Newton forum are about "scaling up" the world to have millimeters and grams in order to avoid the freeze treeshold. We have instead a world to "scale down" instead...
With the form of solving Newton update.
Don't you have stutterer problems?.
That code come from Nout. The point is that RF have an internal timeslicer: in fact the Tick(); executes the loop that lasts exactly the time sliced by the CCommonData class. I don't know if this applies also in your project. I have some sturrering due to the media playing (sound and spout effects) during the collisions. Right now my simulation seems to be in time, but I know that a better updating procedure could be achieved.

I think I should study better these notes from walaber docs:

http://walaber.com/newton_wiki/index.ph ... cing%22%3F
http://walaber.com/newton_wiki/index.ph ... nUpdate%3F

and eventually this:
http://walaber.com/newton_wiki/index.ph ... n_extremes

Eventually I think that my sinulation could be affected by this:

In certain circonstance, the use of time-slicing can lead to a paradoxe in which the time required to update physics will become greater than the time-slice itself.

When the application enters this paradoxe, it starts to works more and more slowly. Each use of the « while » loop (as described in this example) will require more and more time to be completed, and the application will quickly seems to be frozen.

To avoid to enter this paradoxe, one solution is to filter the delta-time (the « milliseconds » variable in the example) so it will never get greater than a limit of your choice.

Posted: Fri Oct 26, 2007 4:21 pm
by federico
last feature added: the Attribute entity can be spawned now as Physics entity. Supports reSpawn and triggering.

My tasks are now complete. I'm packing the first release. Sourceforge has graciously given me an host and svn.

Prepare yourself :wink:

Posted: Sat Oct 27, 2007 1:09 am
by federico
Ready to release, I see that the breakable joint doesn't work anymore, and I don't know why... :evil:

Posted: Sat Oct 27, 2007 5:25 pm
by Juutis
Sweet! Does the version have the sin and cos functions in scripting? I really need them to align my scripted weapons properly with the camera.

Posted: Sun Oct 28, 2007 2:56 am
by federico
yes, they're in 075C so they're in my release.
i added these commands:
AddHashCommand("SetRelBoneRotation", 188); // SetRelBoneRotation
AddHashCommand("SetWeaponActorName", 189); // SetWeaponActorName
AddHashCommand("ChangeEntityName", 190); // ChangeEntityName
AddHashCommand("GetCameraHeight", 193); // GetCameraHeight
AddHashCommand("SetCameraHeight", 194); // SetCameraHeight
AddHashCommand("SetCameraOffset", 195); // SetCameraOffset
AddHashCommand("EnableStencilShadows", 196); // EnableStencilShadows
AddHashCommand("SetRelBonePosition", 197); // SetRelBonePosition
AddHashCommand("SetBoneGlobalRotation", 198); //
AddHashCommand("GetActorBoneRotation", 199); // GetActorBoneRotation
they're quite self-explanatory. I simply have to give up my first plan to write all the documentation before the release. I have to release and then write the docs. I don't want to let you wait anymore and I need to let someone else look at my work just to relax myself a bit.
I think that tomorrow could be the right day for the release.

:wink:

Posted: Sun Oct 28, 2007 1:40 pm
by federico
breakable joints working again... :lol: