Gamestudio Links
Zorro Links
Newest Posts
ZorroGPT
by TipmyPip. 03/05/26 02:58
zorro with ccxt?
by opm. 03/03/26 03:17
WFO Training with parallel cores Zorro64
by Martin_HH. 02/26/26 16:03
Zorro version 3.0 prerelease!
by TipmyPip. 02/25/26 16:38
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
5 registered members (Volkovstudio, TipmyPip, Quad, AndrewAMD, 1 invisible), 4,913 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
the1, alx, ApprenticeInMuc, PatrickH90, USER0328
19200 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Using physX how do I apply force in direction model is facing? #360335
02/23/11 17:48
02/23/11 17:48
Joined: Sep 2006
Posts: 36
Tempe, AZ
B
bpc31 Offline OP
Newbie
bpc31  Offline OP
Newbie
B

Joined: Sep 2006
Posts: 36
Tempe, AZ
I am trying to propel a boat model forward without using any of the tire physic templates but so far I can only rotate left and right. When I apply pXentsetforce local or global it only moves in absolutes not relative to my last rotation. Anyone have a code samples for this?

Re: Using physX how do I apply force in direction model is facing? [Re: bpc31] #360344
02/23/11 18:04
02/23/11 18:04
Joined: Feb 2009
Posts: 3,207
Germany, Magdeburg
Rei_Ayanami Offline
Expert
Rei_Ayanami  Offline
Expert

Joined: Feb 2009
Posts: 3,207
Germany, Magdeburg
Rotating the speed/accel vector with the actual rotation would be my solution.

Re: Using physX how do I apply force in direction model is facing? [Re: Rei_Ayanami] #360528
02/24/11 18:15
02/24/11 18:15
Joined: Sep 2006
Posts: 36
Tempe, AZ
B
bpc31 Offline OP
Newbie
bpc31  Offline OP
Newbie
B

Joined: Sep 2006
Posts: 36
Tempe, AZ
Any code samples? I'm not much of a programmer. laugh

Re: Using physX how do I apply force in direction model is facing? [Re: bpc31] #364503
03/18/11 17:56
03/18/11 17:56
Joined: Mar 2010
Posts: 120
Switzerland
T
TehV Offline
Member
TehV  Offline
Member
T

Joined: Mar 2010
Posts: 120
Switzerland
This should work:

Code:
a = cos(me.pan);
b = sin(me.pan);

pXentsetforce(me,vector(a,b,0));



I am not sure about how to use pXentsetforce(), so you might have to adjust that bit. Everything else should work.

Last edited by TehV; 03/18/11 17:57.

Moderated by  HeelX, Spirit 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1