playMaker

Author Topic: Playmaker - Programmer workflow  (Read 5873 times)

TBN

  • Playmaker Newbie
  • *
  • Posts: 2
Playmaker - Programmer workflow
« on: August 28, 2015, 02:16:09 AM »
Hi,

I am new to Playmaker, been testing it for about a week. I am a decent programmer and well versed in C#, what I found is Playmaker is slowing me down.. it is so much easier if I just code it instead of using Playmaker.

So what value does Playmaker adds to a programmer? All resources I found on the internet is about visual programming, which I find absurd... I could code those things at the fraction of the time... not to mention that I have to scour the internet for the Actions needed to accomplish tasks that I could have done in code myself.

I am interested to hear from programmer's perspective here...



jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Playmaker - Programmer workflow
« Reply #1 on: August 28, 2015, 05:00:20 AM »
Hi,

 That's a great question. Let me try to explain why I still use PlayMaker on *all* my projects, even tho, like you, I could do it all without PlayMaker because I can code. I would go further and mention that actually, I will write the proper bridges, proxies and custom actions for a given asset so that I can work with it within PlayMaker, so I am ready to actually do that bridges and spend time doing it instead of just do it by code, because I know the value I am getting out of this initial boiler plate work for PlayMaker.

First of all, PlayMaker is a tool, and like all tools, you decide wether it should be in your toolbox or not, and sometimes it's adequate for the job, sometimes it's not, so it's totally ok that you feel it doesn't help you being more productive or that it brings something on the table that benefits you.

Having said that, here few points that I think should be very carefully considered if you are questioning the usefulness of PlayMaker.

PlayMaker "visual programming" terms should be used carefully, it's not trying to replicate the way you write a c# line of code, it brings SO MUCH MORE on the table, that more and more I don't even mention that it's visual, because it's resonate the wrong way in most minds.

 -- The Finite State Machine Paradigm is something that of course more than just a visual tool, it's a logical way to develop. This in itself, is not built in c# and I strongly suggest you learn about developing this way, it's so refreshing and efficient.
 
 I found a great article on this, that explains to c# developers why a finite state approach to development is desirable.

 -- The Visual view of your code logic is helping a lot when designing and debugging your logic, this is something you don't have in c#. "Visual Programming" in that context is not absurd, It's actually tremendously helpful, even if you are experienced. Typically, coroutines nightmare is a thing of past as far as I am concerned, PlayMaker completely wipe the issue and propose something so flexible that beginners have no idea they are building complex asynchronous process without giving it a second thought. Doing the same thing in pure c# requires experience, and even so, is still difficult to debug because you don't see the processes at stake. A simple www call is enough to see why PlayMaker is beneficial, do a www call in pure c#, you have no idea of the current state or it, unless you write a custom inspector, write a lot of boiler plate code to watch your processes, etc etc, in PlayMaker, one action, one event, and done!!! it's incredible, saving SOOO much time and affect both newbies AND experience developers.

 -- PlayMaker in my opinion is the right blend of visual development and code, because EVERYTHING that is finally executed is done within "action", which is pure c# classes, so PlayMaker does NOTHING to your game that you don't have access to with normal code. The "visual" elements are simply for the finite state machine handling. From that perspective, feel free to create custom actions that work the way you expect, I like to think of actions as lego building block, highly reusable, doing very precise tasks, and the combination of them makes greater/complex behaviours, while some developers write more complex actions that do a lot, they are simply wrappers for complex features, and the FSM is here to handle the hight level workflow of the game logic.

 -- There are still features I develop with conventional code, like if I want to build a new IK framework... I would do this in pure c#, if I want to build a web socket system.... c#. That's where I draw the line, but if I want to deal with regular logic to implement the specifics of my game/Application, PlayMaker is my main tool, the tool that binds everything together, in a way, it's the "Manager" of my game, and then as I go deeper and deeper in smaller parts of my Application, I still use PlayMaker when it make sense to use a State Machine Paradigm, and I find that it's 99% of the case :)  cause it's a natural way to thinkg about logic workflow. Thist is typically bringing "FlowChart" designs into life.

-- We could transport this discussion on why Unity has this component based approach, which throws so many of us during the initial learning phase, especially coming from Java or xcode with development strategies are so different. It's matter of choice and vision, you adhere and swing with it or you choose a different technology, but you can't avoid it if you want to use Unity. It's difficult to dismiss it, just on the bases that it doesn't match your initial assumption of what it does, a pure MVC platform do wonder in the right hands, and is a total failure/nightmare for other developers, same with OOP, same with Unity, same with PlayMaker :)

 -- As for "scouring" the internet for finding custom actions: In what way is it different than people not knowing a .net feature to work with dates or xml, or some nice features of strings, and reinvent the wheel just because they did not find it before hand? Like everything, a very important part of your job as a developer is to know how to search for informations, know how to ask the right questions, not fearing asking for something you find odd or seems like it should be there. And we do our best on this forum to help everyone ( this is also the very reason why I dived into Unity, because the community was helping me on very precise, newbie questions, otherwise I would have choose a different technology for sure) I personally have a very bad memory... so I spend my days googling for how to work with almost everything like arrays, how to work with enums, etc and I never want to remember it, it's impossible, I want to remember how to find the information. That's what matters. The same applies with PlayMaker actions and the thousands of custom actions and proxies you can find spread around the forum, the wiki, the ecosystem, and the asset store. It's that ability that will make a developer stand out from the others in terms of ability to progress and be effective on a task. We all have to deal with this, at any level of knowledge and experience wether we use PlayMaker or not. And we all been through this initial phase of knowing where and how to find informations we need on our daily tasks.

Bye,

 Jean



TBN

  • Playmaker Newbie
  • *
  • Posts: 2
Re: Playmaker - Programmer workflow
« Reply #2 on: August 28, 2015, 10:04:40 AM »
Thanks for the reply... really appreciate it... I guess it makes sense.. maybe the initial momentum would be slow.. since there is learning curve, adjustments, etc... and as long as I keep writing modular custom actions that can be reused over and over then it will start paying off...

I am still quite skeptical though... but I will revisit playmaker later for a different game (and I am not in a rush to finish it) and lets see how it goes... and thanks for the link to FSM!... that book is awesome!..

Cheers!

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Playmaker - Programmer workflow
« Reply #3 on: August 28, 2015, 11:40:26 AM »
Hi,

 Yep, the key here is to create modular actions, else you loose a major benefit from PlayMaker.

 good luck with everything, and don't hesitate to ask questions on the forum to ease your learning process :)

 Bye,

 Jean

coffeeANDsoda

  • Hero Member
  • *****
  • Posts: 618
Re: Playmaker - Programmer workflow
« Reply #4 on: August 28, 2015, 03:29:27 PM »
Correct me if I'm wrong jean, but for a person to create additional playmaker actions it requires the user to know quite a bit of C#?

Bare in mind, I have tried to program unity games with  JS or C# in the past, but didn't really seem to get far compared to looking up tutorials on specific gameplay mechanics on youtube.

That's why I bought playmaker. However, at times do feel making a certain game is easier to code in some cases compared to playmaker, but I want to continue using PM because when I try to code games my way, they don't to work well.

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2511
  • Mender of the past
    • Cleverous
Re: Playmaker - Programmer workflow
« Reply #5 on: August 28, 2015, 04:16:32 PM »
Jean pretty much covers it, but here's a bit of my thoughts.

I started on the opposite side of things, learning Playmaker first, making some cool stuff, then learning to code much later. After understanding the ins and outs of Playmaker, I found it pretty clear where I should and should not use it.

First, it's simply not a good idea to use it for *everything* when you are going beyond a certain point of complexity. There are a lot of low level things that Playmaker can't do what you could in regular C# like nice accessible lists, inheritance, etc... This is where you would do something in C#; the point where it is less productive to do it in Playmaker.

That being said, there's no reason you can't write Playmaker actions and just use them inside your FSMs anyway which is often just really a great way to do things sometimes. Look at ArrayMaker, for example. Not only does it give you a clear front end and visual controls but it helps you modularize your concepts instead of falling into poor design traps.

Having a reliable flow of modular parts of your code that you can mix and match at any time is extremely useful. Now you can take those modular chunks - either stock stuff, the 500+ actions on ecosystem, or your own custom actions - and tie them together to make a lot of different things instead of dealing with bloaty code to handle all the variants.

For prototypes, its invaluable. If the actions are designed right you'll have enough modular tools to build just about anything really fast.

I agree with Jean on debugging as well, its really easy to see where things breakdown in a visual FSM compared to a bunch of Debug.Log() + trial and error.

In the end it is a tool, but all tools have to be used properly and in their place for them to be effective. It's just a matter of deciding when and how to use it in your workflow. For me, that's for high level stuff with opportunity for low level stuff where I can write proper bridges for it and gain reusibility/value.
Products by Cleverous
|| Vault Core : Database
|| Vault Inventory : Multiplayer Inventory
|| Vault Attributes : Character Stats
|| That Hurt! : Dmg Floaties
|| Quinn : 3D

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7616
    • jinxtergames
Re: Playmaker - Programmer workflow
« Reply #6 on: August 29, 2015, 01:16:08 PM »
Hi,
Quote
Correct me if I'm wrong jean, but for a person to create additional playmaker actions it requires the user to know quite a bit of C#?

Actually you don't need to have a lot of knowledge from C# to make custom actions.
I started a few year ago with learning C# and then i met playmaker.
As a C# Rookie this speed-ed up my "programming" a lot!
Then i needed some actions that did not exist yet, so i started to look to several other actions code and i started to make my own actions,
 it even helped me to learn more about C#

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Playmaker - Programmer workflow
« Reply #7 on: August 31, 2015, 02:54:41 AM »
Correct me if I'm wrong jean, but for a person to create additional playmaker actions it requires the user to know quite a bit of C#?

Yep, and as djaydino mentionned, the required knowledge for simple actions is within reach for everyone working with Unity. So Again, be aware that the best combination is PlayMaker + c# knowledge, this will unleash your potential.

Bye,

 Jean