|
man,i wanna this work without Physics engine
#222896
08/21/08 14:46
08/21/08 14:46
|
Joined: Aug 2008
Posts: 63 =Strogg=3rd_com_cent.
Omicron_NEGA
OP
Warez kiddie?
|
OP
Warez kiddie?
Joined: Aug 2008
Posts: 63
=Strogg=3rd_com_cent.
|
hi,guys! im new here,and here is my question: when im Climbing a slope,it will be like this:  and i cant use phy engine,or i'll write another script. thx
P4 3.6GHz x2 8GB RAM DDR2 GeForce8800GTS
|
|
|
Re: man,i wanna this work without Physics engine
[Re: Omicron_NEGA]
#222897
08/21/08 14:47
08/21/08 14:47
|
Fear411
Unregistered
|
Fear411
Unregistered
|
look up "normal" under the manual
|
|
|
Re: man,i wanna this work without Physics engine
[Re: ]
#222898
08/21/08 14:49
08/21/08 14:49
|
Joined: Aug 2008
Posts: 63 =Strogg=3rd_com_cent.
Omicron_NEGA
OP
Warez kiddie?
|
OP
Warez kiddie?
Joined: Aug 2008
Posts: 63
=Strogg=3rd_com_cent.
|
copy that... thx
Last edited by Omicron_NEGA; 08/21/08 14:52.
P4 3.6GHz x2 8GB RAM DDR2 GeForce8800GTS
|
|
|
Re: man,i wanna this work without Physics engine
[Re: Omicron_NEGA]
#222908
08/21/08 15:55
08/21/08 15:55
|
Joined: Jul 2005
Posts: 1,930 Austria
Dark_samurai
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,930
Austria
|
I guess you are tracing to the ground, so that the entity is placed on the ground (gravity)? Than you can also change the tilt of the model so that it has the same tilt like the normal of the ground it is standing on.
Dark_Samurai
ANet - A stable and secure network plugin with multi-zone, unlimited players, voip, server-list features,... (for A7/A8)! get free version
|
|
|
Re: man,i wanna this work without Physics engine
[Re: Dark_samurai]
#222912
08/21/08 16:24
08/21/08 16:24
|
Joined: Aug 2008
Posts: 63 =Strogg=3rd_com_cent.
Omicron_NEGA
OP
Warez kiddie?
|
OP
Warez kiddie?
Joined: Aug 2008
Posts: 63
=Strogg=3rd_com_cent.
|
i know i am a hopeless fool.. more help plz~ btw,im using c_trace to judge if it is contacting the floor, that used for jumping function. I use c_move 4 gravity. **and give me a sample code if it possible,thx!!!*
Last edited by Omicron_NEGA; 08/21/08 16:26.
P4 3.6GHz x2 8GB RAM DDR2 GeForce8800GTS
|
|
|
Re: man,i wanna this work without Physics engine
[Re: Omicron_NEGA]
#222941
08/21/08 17:36
08/21/08 17:36
|
Joined: May 2006
Posts: 90 England
TigerTao
Junior Member
|
Junior Member
Joined: May 2006
Posts: 90
England
|
Some old code I picked up somewhere, works a treat though. Place this after when tracing to the ground so you get the returned normal of the surface. No need to use temp you can use another defined vector.
c_trace(tracing to ground...);
temp.tilt = 0;
temp.roll = 0;
temp.pan = -my.pan;
vec_rotate(normal, temp);
temp.tilt = -asin(normal.x);
my.tilt += 0.1 * ang(temp.tilt - my.tilt);
// play with 0.1 for speed of tilting
my.roll = 0;
Hope this helped.
|
|
|
|