Gamestudio Links
Zorro Links
Newest Posts
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
0 registered members (), 1,382 guests, and 6 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19055 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
gs physics: scale adjustment #280424
07/22/09 15:34
07/22/09 15:34
Joined: Apr 2006
Posts: 329
M
molotov Offline OP
Senior Member
molotov  Offline OP
Senior Member
M

Joined: Apr 2006
Posts: 329
Hey, recently I started messing arround with the physics car script that comes with gamestudio. I'm trying to create a funny race game with power-ups. One of the power-ups is a temporaly increase in scale. I've already created the code that makes the wheels and car change in scale. But the problem is that the wheels stay at the same postion from the car as it was in the original scale. My question is, how do I change the physics joins between car and wheels in real-time based on the scale of the car. Hope someone can help me, much appreciated.

Re: gs physics: scale adjustment [Re: molotov] #280429
07/22/09 15:49
07/22/09 15:49
Joined: Nov 2008
Posts: 354
saeculum II
MPQ Offline
Senior Member
MPQ  Offline
Senior Member

Joined: Nov 2008
Posts: 354
saeculum II
you have to unregister the physics for your wheels when changing scale and after that register new! I think this is the only way.


new project in early stage...

Intel Xeon X3450 2,66GHz | Mushkin 8 Gib | Zotac GTS250 + 7300LE | A8.3 com
Re: gs physics: scale adjustment [Re: MPQ] #280453
07/22/09 17:33
07/22/09 17:33
Joined: Apr 2006
Posts: 329
M
molotov Offline OP
Senior Member
molotov  Offline OP
Senior Member
M

Joined: Apr 2006
Posts: 329
So if I understand correctly the easy way is to remove the old wheels and just ent_create new ones, every time I change the scale.

Re: gs physics: scale adjustment [Re: molotov] #280458
07/22/09 18:15
07/22/09 18:15
Joined: Nov 2008
Posts: 354
saeculum II
MPQ Offline
Senior Member
MPQ  Offline
Senior Member

Joined: Nov 2008
Posts: 354
saeculum II
yes I would do it this way

- add constraint
- scale wheel
- if wheel scaled remove old constraint and add new constraint afterwards

(not tested;))


new project in early stage...

Intel Xeon X3450 2,66GHz | Mushkin 8 Gib | Zotac GTS250 + 7300LE | A8.3 com

Moderated by  HeelX, Spirit 

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