Random number, either A or B. Not a range between them. How do?

I have been looking around and searching but still am looking for an answer.
How does one randomly get a number between 2 different numbers. I have tried using floats and integer nodes and not the result I am looking for.

Specifically, how would one choose randomly a number between -3 and 3 ?
Not a range between them only either or.

Thank you!

Get any random number (integer) and check if its even or odd?

You can use Random Bool and connect that to a Select Integer

1 Like

I can think of three ways that are easy in Blueprint:

  1. Make an array that contains the numbers you want to choose from, and pick random item from array
  2. Create a random integer in the range [0, 1] and calculate (A + (B-A)*Random0or1)
  3. Use a random boolean and/or integer, and a Select Value node where the random integer goes into the choice pin at the bottom.
3 Likes

I guess the solution was just that simple, I was trying all kinds of things! This worked the way I wanted it to. Thank you.