Gamestudio Links
Zorro Links
Newest Posts
Newbie Questions
by fairtrader. 12/05/23 10:32
Zorro Trader GPT
by TipmyPip. 12/04/23 11:34
Square root rule
by Smallz. 12/02/23 09:15
RTest not found error
by TipmyPip. 12/01/23 21:43
neural function for Python to [Train]
by TipmyPip. 12/01/23 14:47
Xor Memory Problem.
by TipmyPip. 11/28/23 14:23
Training with command line parameters
by TipmyPip. 11/26/23 08:42
Combine USD & BTC Pairs In Asset Loop
by TipmyPip. 11/26/23 08:30
AUM Magazine
Latest Screens
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Who's Online Now
6 registered members (AndrewAMD, alibaba, fairtrader, ozgur, TipmyPip, Quad), 604 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
fairtrader, hus, Vurtis, Harry5, KelvinC
19019 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 3 1 2 3
Transform Object independent of Orientation #254167
03/01/09 14:59
03/01/09 14:59
Joined: Jul 2008
Posts: 894
T
TechMuc Offline OP
User
TechMuc  Offline OP
User
T

Joined: Jul 2008
Posts: 894
Hey,

I've - probably - a pretty simple problem, i'm just not getting solved (it's a shame :x).

I want to scale an object independantly of its world orientation. E.g. i want to enlarge an object on the z axis (lets say 10 quants). How can I make this transformation Object-Orientation independent?

thanks for any hints,
TechMuc

Re: Transform Object independent of Orientation [Re: TechMuc] #254289
03/02/09 11:45
03/02/09 11:45
Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
Cowabanga Offline
Expert
Cowabanga  Offline
Expert

Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
Use "scale (_x) (_y) (_z)".

www.conitec.net/beta/aentity-scale_x.htm

Re: Transform Object independent of Orientation [Re: Cowabanga] #254298
03/02/09 13:50
03/02/09 13:50
Joined: Jul 2008
Posts: 894
T
TechMuc Offline OP
User
TechMuc  Offline OP
User
T

Joined: Jul 2008
Posts: 894
thanks for the very informative answer (attention: hidden ironie...)

man.. please read the question before answering

Re: Transform Object independent of Orientation [Re: TechMuc] #254302
03/02/09 14:19
03/02/09 14:19
Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
Cowabanga Offline
Expert
Cowabanga  Offline
Expert

Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
This is the answer of your question!

Quote:
E.g. i want to enlarge an object on the z axis (lets say 10 quants).


So my answer is correct. You can use "scale_z" to enlarge the object on the Z Axis!

And don't be so mean. I'm trying to help here...

Re: Transform Object independent of Orientation [Re: TechMuc] #254303
03/02/09 14:20
03/02/09 14:20
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
Pappenheimer Offline
Senior Expert
Pappenheimer  Offline
Senior Expert

Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
I only can think of a transformation of the vertices of the model on the world's x-axis/y-axis/z-axis.

For scaling on the world's x-axis for instance:
- Take the origin of the model, or compute the middle of the vertices, (depends on what you find more appropriate)
- then take the x-values of all vertices
- and move them depending their distance to the origin or middle of the model.
For instance for scaling the model on the x-axis to the double of its size, multiply each x-distance of the vertices to their 'origin', and move them to the new position.

Don't know whether I'm clear enough.

Re: Transform Object independent of Orientation [Re: Cowabanga] #254306
03/02/09 14:22
03/02/09 14:22
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
Pappenheimer Offline
Senior Expert
Pappenheimer  Offline
Senior Expert

Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
Cowabanga, that's an easy way to scale depending the _model's_ axis - TechMuc asked for scaling depending the _world's_ axis!

Re: Transform Object independent of Orientation [Re: Pappenheimer] #254308
03/02/09 14:26
03/02/09 14:26
Joined: Jul 2008
Posts: 894
T
TechMuc Offline OP
User
TechMuc  Offline OP
User
T

Joined: Jul 2008
Posts: 894
@Pappenheimer: Thanks for the answer. The Problem is that i can not use this method in an editor as i do not want to edit mdl files, just for edit the scaling of an object.

I've tried several methods (rotation matrix or e.g. vec_rotate(vec(0,0,1),ent->pan) ==> use vec as factor for z axis scale) but never succeeded.

There MUST be a way. I mean.. other editors get this to, without editing the whole models.

Re: Transform Object independent of Orientation [Re: Pappenheimer] #254309
03/02/09 14:26
03/02/09 14:26
Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
Cowabanga Offline
Expert
Cowabanga  Offline
Expert

Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
Originally Posted By: Pappenheimer
Cowabanga, that's an easy way to scale depending the _model's_ axis - TechMuc asked for scaling depending the _world's_ axis!


Hmmm, OK. The world. By using the scaling tool in WED. (Sorry if my answer is wrong...)

And if you mean scaling some object in the world by a script, Wait until Conitec discovers something for putting an action to blocks. :P

Re: Transform Object independent of Orientation [Re: Cowabanga] #254312
03/02/09 14:35
03/02/09 14:35
Joined: Jul 2008
Posts: 894
T
TechMuc Offline OP
User
TechMuc  Offline OP
User
T

Joined: Jul 2008
Posts: 894
@Cowabanga: Please do not post something if you do not know the answer. It's annoying, does not help to find an answer and stops other people who might give an informative answer (like pappenheimer) reading this thread...

EDIT: And NO - i do not want any comment to this post...

Last edited by TechMuc; 03/02/09 14:38.
Re: Transform Object independent of Orientation [Re: TechMuc] #254314
03/02/09 15:07
03/02/09 15:07
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
Pappenheimer Offline
Senior Expert
Pappenheimer  Offline
Senior Expert

Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
Originally Posted By: TechMuc
@Pappenheimer: Thanks for the answer. The Problem is that i can not use this method in an editor as i do not want to edit mdl files, just for edit the scaling of an object.


This sounds a bit like trying the impossible, because every result of a manipulation within the editor must work without problems in the engine without sacrificing the framerate.
This means, IMO, that the engine must provide such a function to assure that it is actually of use in realtime.
It makes no sense, if it works in the editor, but not in the engine.
Or, did I miss something?

Page 1 of 3 1 2 3

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

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