playMaker

Author Topic: Vector 3 to Int  (Read 1226 times)

Rhyuzaky

  • Playmaker Newbie
  • *
  • Posts: 32
    • View Profile
Vector 3 to Int
« on: September 24, 2015, 04:36:42 AM »
I would call an action or something to convert a Vector 3 for Int (For example: 3,555 4,654 8,556 3 4 to 8 in a vector 3).
Basically stabilizes it not contain numbers in addition to integers.
Is there any way to do this?

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2488
  • Yup.
    • View Profile
    • Cleverous
Re: Vector 3 to Int
« Reply #1 on: September 24, 2015, 05:14:41 AM »
You can take each part out of the Vector and round it, then inject them back into the Vector after rounding.

There isn't a Vector3.Round() method, but we could make an action that automates the the process above. What is the use case?

Rhyuzaky

  • Playmaker Newbie
  • *
  • Posts: 32
    • View Profile
Re: Vector 3 to Int
« Reply #2 on: September 24, 2015, 01:37:06 PM »
I'm trying to use it to create parts of a spacecraft game that I'm creating exploration and survival espacial.Neste calso use to create grid piece by piece.
Sera that a d efazer so compactly it?