Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: kenmarold on December 16, 2015, 06:26:59 PM

Title: Is there an action to find the difference between two numbers?
Post by: kenmarold on December 16, 2015, 06:26:59 PM
If I want to find the difference between -3.5 and 8.5 how would I do that in Playmaker?
Title: Re: Is there an action to find the difference between two numbers?
Post by: craigz on December 16, 2015, 07:35:22 PM
Should just need to subtract them :)

Here's one way to do it. It could probably be condensed down to a couple states, but  here's a few more to illustrate. I used integers to make the numbers cleaner, but it'll work for floats as well.

GIF
(http://i.imgur.com/6bteYFJ.gif)

Grab
(http://i.imgur.com/mD4xQ8f.png)

best!
Title: Re: Is there an action to find the difference between two numbers?
Post by: terri on December 16, 2015, 09:20:49 PM
here is an action that does craigz's logic on its own

Title: Re: Is there an action to find the difference between two numbers?
Post by: craigz on December 16, 2015, 11:19:58 PM
Ahh! Thanks Terri :D

Don't mind me... I'm just going to be taking this also.. :P
Title: Re: Is there an action to find the difference between two numbers?
Post by: dudebxl on December 16, 2015, 11:41:37 PM
+ 1. To add to ecosystem..