x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Equal rotator problem please help

Hello,

What i am trying to do here is to get a relative rotation of an actor (the root component is getter from actor cast ) on Y axis.And i want if the rotation of the actor is 90 +-1 on Y axis to fire some event on branch true.And for that reason i put 1.000000 tolerance, so if its 90 or 91 it still be considered as true( if i'am not wrong how these tolerance values are added to rotation values)

The problem is if the actor rotation is 90 or 91 on Y axis its still considering it as false. Can anyone help?

Regards!

alt text

Product Version: UE 4.17
Tags:
rot.png (139.4 kB)
more ▼

asked Oct 10 '17 at 10:23 AM in Blueprint Scripting

avatar image

MosPetrov
28 1 4 13

(comments are locked)
10|2000 characters needed characters left

2 answers: sort voted first

I've manage to find a way to make it work. First i store the rotation with rotator variable in the desired object. Then instead of getting root component from casting actor i get this rotator variable. Then  nearly equal transform and for A pin make transform and then for rotation i plug this getter variable from the casted actor.Then i find desired rotation tolerance which is +5,-5 degree which is equal to 0.044444. And its work perfect.

​​​​​​​Have a nice day!

more ▼

answered Oct 12 '17 at 06:18 AM

avatar image

MosPetrov
28 1 4 13

(comments are locked)
10|2000 characters needed characters left

split the outcoming of your setted "get relative rot" and just get the Y Float instead of the whole rot and make a "nearly equal(float)" bool into that branch with the single Y coordinate .... maybe its buggy to use a whole rot because its checks every rot for its value before it gives you a true

more ▼

answered Oct 10 '17 at 10:44 AM

avatar image

Erytriel
324 14 3 10

avatar image MosPetrov Oct 10 '17 at 11:11 AM

Hello, Erytriel

Thanks for the fast reply.

I have tried it, but its still a false with the default rotation tolerance, if i set the rot tolerance 1.000000 then always is true, no matter if Y value is 0 or 150, every random value is considered as true. Also is this the correct way to set Nearly equal A transform and B?

Regards.

alt text

rot-02.png (141.4 kB)
(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question