playMaker

Author Topic: How to check float is 0? [SOLVED]  (Read 2448 times)

jess84

  • Hero Member
  • *****
  • Posts: 515
How to check float is 0? [SOLVED]
« on: December 15, 2013, 01:49:53 PM »
I've been driving myself bad trying to figure this out, I assume it's probably very simple though.

I have a consumable item, and when you've used all 10, I want it so that you cannot click the GUI texture item to equip the item again.

Float Sign Test doesn't work as the IsPositive is catching 0 as a positive

Float Switch doesn't work as whilst I can check for Below 1 as trigger an action, I can't get through that state is the float is 1 or greater

What's the way of checking if a float = 0?

« Last Edit: December 15, 2013, 05:00:35 PM by jess84 »

escpodgames

  • Hero Member
  • *****
  • Posts: 687
    • Assets
Re: How to check float is 0?
« Reply #1 on: December 15, 2013, 03:16:38 PM »
Float compare

jess84

  • Hero Member
  • *****
  • Posts: 515
Re: How to check float is 0?
« Reply #2 on: December 15, 2013, 03:18:38 PM »
But that's to compare 2 floats, right?

Or are you saying I should create another float as my 'target' float, 0 ?

escpodgames

  • Hero Member
  • *****
  • Posts: 687
    • Assets
Re: How to check float is 0?
« Reply #3 on: December 15, 2013, 04:51:32 PM »
You can compare your consumable item float to '0'

see image :)

jess84

  • Hero Member
  • *****
  • Posts: 515
Re: How to check float is 0?
« Reply #4 on: December 15, 2013, 04:59:40 PM »
Ah, awesome thanks.

(I originally looked at that, but thought it required 2 actual float variables - I didn't expect it to accept a manual value)