playMaker

Author Topic: Is there a variable for position, rotation and scale?  (Read 2575 times)

wheretheidivides

  • Sr. Member
  • ****
  • Posts: 496
Is there a variable for position, rotation and scale?
« on: December 17, 2014, 11:23:29 PM »
Instead of using get position, get rotation and get scale of a game object, is there a variable to all at the same time?  If not, could there be?  Playmaker could just have 3 variables in one.  that way one could get the info from a game object and then set it.  This would avoid 3 variables per obkect.  We could call this a vector9.

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2511
  • Mender of the past
    • Cleverous
Re: Is there a variable for position, rotation and scale?
« Reply #1 on: December 18, 2014, 09:48:12 AM »
Internally it is the Transform. A Vector9 variable doesn't make sense when you consider the structure of Transform.

http://docs.unity3d.com/ScriptReference/Transform.html

There are a lot of things to consider when working with the transform of an object which is why the actions are subdivided in such a manner.

What is the use case? Just to apply a Vector3 to the Position, Rotation and Scale in a single action? If that is so, we can just make an action to do it.
Products by Cleverous
|| Vault Core : Database
|| Vault Inventory : Multiplayer Inventory
|| Vault Attributes : Character Stats
|| That Hurt! : Dmg Floaties
|| Quinn : 3D

wheretheidivides

  • Sr. Member
  • ****
  • Posts: 496
Re: Is there a variable for position, rotation and scale?
« Reply #2 on: December 18, 2014, 05:25:09 PM »
I'd like to see an action for that.  position, rotation and scale (transform9) and another with just position and rotation (transform6).  It'd speed things up.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Is there a variable for position, rotation and scale?
« Reply #3 on: December 22, 2014, 03:47:46 AM »
Hi,

yeah, the problem would be ( on top of what Lane said), that then all Playmaker actions would need to understand this transform, and what you want from it, when you work with it, and so it make sense currently to keep every properties in its own vector3 variable.

 I agree, a convenient action to get all three ( or part of it) properties of a transform would speed things up a bit.

I'll see if I can do that action withint he next few days, please bump.

 Bye,

 Jean