playMaker

Author Topic: Int, Float, GameObject If/Else if/Else Action  (Read 4921 times)

darkhitori

  • Playmaker Newbie
  • *
  • Posts: 6
Int, Float, GameObject If/Else if/Else Action
« on: September 27, 2015, 02:22:45 AM »
Artist here and beginner programmer messing around with some code and Modified the Float Compare 2 and GameObject Compare Action into If/Else if/Else Actions.....Hopefully other beginners will find this easy to use in developing their games!!!........Enjoy  ;)








jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Int, Float, GameObject If/Else if/Else Action
« Reply #1 on: September 29, 2015, 05:02:42 AM »
Hi,

 Thanks for contributing, but I would suggest one thing to avoid the typical issue with this types of actions, what if you want yet another if statement....

so I suggest you make an array of if statments, and so for a given action the developer can have as many elses than needed.

 For code examples on how to provide arrays within actions, check out "SelectRandomColor" for example.

 Bye,

 Jean

darkhitori

  • Playmaker Newbie
  • *
  • Posts: 6
Re: Int, Float, GameObject If/Else if/Else Action
« Reply #2 on: September 30, 2015, 11:32:10 PM »
I hear what you are saying Jean....So I took your advice and remade it like you said with an array in case people want more if statements...Just make sure the Ifs and the Operations & Send Events have the same number to evaluate. Thanks and here you go!!! ;D



IndieIconic

  • Playmaker Newbie
  • *
  • Posts: 2
Re: Int, Float, GameObject If/Else if/Else Action
« Reply #3 on: April 18, 2017, 04:24:38 PM »
There was a time that I got an addon similar to this. Though I've searched through the ecosystem and forums and this is one of the only things I can find.

Does anyone know what the addon is that has an if/else structure like this? -> Or is it on the ecosystem under a package?

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Int, Float, GameObject If/Else if/Else Action
« Reply #4 on: April 19, 2017, 02:46:31 AM »
Hi,

 uhm, I can't recall anything like that, maybe with bool tests?

 Bye,

 Jean

terri

  • Sr. Member
  • ****
  • Posts: 386
    • terrivellmann.tumblr.com
Re: Int, Float, GameObject If/Else if/Else Action
« Reply #5 on: April 19, 2017, 05:31:34 PM »
maybe its conditional expression?