Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
0 registered members (), 1,119 guests, and 0 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
back, and confused #355253
01/25/11 18:07
01/25/11 18:07
Joined: Apr 2009
Posts: 141
dakilla Offline OP
Member
dakilla  Offline OP
Member

Joined: Apr 2009
Posts: 141
hey,
been away from gamestudio for a while now and have just came back again, see whats changed etc. I have however been having a problem with a script I quickly made, I dont know if i am forgetting something basic or maybe doin something wrong with the new physics. when I run it the entity just stays where it is with no movement. I have loaded a level, and just dunno why it wont do anything. cheers in advance laugh

function playerst()
{
VECTOR force;

player = ent_create("ball.mdl",vector(0,0,100),NULL);
set(player,SHADOW);
pX_setgravity(vector(0,0,-350));
pXent_settype(player,PH_RIGID,PH_SPHERE);
pXent_setmass( player, 1);
pXent_setelasticity(player,25);
pXent_setdamping(player,20,5);

while(1)
{
vec_set(force, vector(100,0,0));
pXent_addforcecentral(player, force);
wait(1);
}
}


One day there will be an unfixable bug,
That day is not today.
Re: back, and confused [Re: dakilla] #355254
01/25/11 18:21
01/25/11 18:21
Joined: May 2009
Posts: 439
T
TerraSame Offline
Senior Member
TerraSame  Offline
Senior Member
T

Joined: May 2009
Posts: 439
I assume that you know that terrains need to be at a scale of one (in WED) for using the new PhysX system...
If yours is not, scale in in med and then re-set the scale in WED to one... Hope that helps...

Re: back, and confused [Re: TerraSame] #355257
01/25/11 18:50
01/25/11 18:50
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
You need to call physX_open(); before you load your level.
Btw the unit scale has changed, -9.81 to -15 is a good value.


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends

Gamestudio download | chip programmers | 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