playMaker

Recent Posts

Pages: [1] 2 3 ... 10
1
PlayMaker Help / Re: Make PlayerPrefs save ONLY if Player finishes the level
« Last post by heavygunner on January 16, 2021, 08:43:37 PM »
This is what I would do.

For Levels. There will be an int variable called "Level" . When player reached finish, I will send and event LEVEL FINISHED and will use action Int add and will add 1 to "Level" variable. So, That will be 2. Then, will use action Playerprefs Set Int and save that "Level" variable in new key called "level"

Same for Stars. Fire an event at Level Finished and check how many stars. and Then will use Int Compare Range action and add stars. and save thm in different key via Playerprefs

Do you maaaaybe have an example or something? I've never used PlayMaker before so this is all new to me.
Did you created the game already ?
2
PlayMaker Help / Event Trigger via Unity 2019 Event System
« Last post by Giunno on January 16, 2021, 05:58:36 PM »
Hello, I'm new to Unity and Playmaker, so could you help me please on how to solve this issue: I would like to take control of point and click via Unity Event System, which send a scriptable object data to another game object (sorry I'm not a programmer). I attach a pic on what I would like to replicate in the same manner via Playmaker.

Please could you show an example? What kind of actions I need for this? If you need more informations I'm at disposition.

Thank you
3
PlayMaker Help / Re: Make PlayerPrefs save ONLY if Player finishes the level
« Last post by Brijac on January 16, 2021, 04:37:44 PM »
This is what I would do.

For Levels. There will be an int variable called "Level" . When player reached finish, I will send and event LEVEL FINISHED and will use action Int add and will add 1 to "Level" variable. So, That will be 2. Then, will use action Playerprefs Set Int and save that "Level" variable in new key called "level"

Same for Stars. Fire an event at Level Finished and check how many stars. and Then will use Int Compare Range action and add stars. and save thm in different key via Playerprefs

Do you maaaaybe have an example or something? I've never used PlayMaker before so this is all new to me.
4
PlayMaker Help / Re: Zenject integration
« Last post by djaydino on January 16, 2021, 03:52:38 PM »
Hi.
To be honest, i don't think that there are plans to integrate this, as it looks like then it would be dependent on this.

Also even for none playmaker users there is not much demand for this yet.

But you could make other people happy by sharing your actions :) or set a open source git of what you have achieved :)
5
General Discussion / Re: v1.9.1.f7 First impressions
« Last post by Alex Chouls on January 16, 2021, 03:07:05 PM »
This is really great feedback - thanks!

I hope to get a patch build out asap with some fixes!

Have you tried the new PlayMakerControls component? It should be useful when you have multiple FSM components on a GameObject, allowing you to collapse the individual components. There is an editor cost as long as an inspector is open, but I'm looking into ways to minimize it.

More documentation for the new features is coming soon...
6
Share New Actions / Log10 and Logarithm actions
« Last post by nuFF3 on January 16, 2021, 02:33:30 PM »
I couldn't find any logarithm actions anywhere, so I decided to make them myself.
I really can't believe no one has made something like this before, since it's pretty vital for setting AudioMixer volumes more correctly, but it also has it's other uses too.
For setting volume one can use the "Convert Float To Decibels" but that's a very specific action for one thing. These actions at least have the possibility of being used for other stuff too.

I've made two actions and edited another from the Ecosystem.
The two that I made are the Float Log10 and Float Logarithm actions.
I edited the Float Operator Advanced to include logarithm operations along with what it already had.

Float Log10 takes one float variable, operates Mathf.Log10, and stores the result in a separate variable.
Float Logarithm does pretty much the same, but it takes both a variable for the Mathf.Log and a variable for base for the logarithm. It too stores the result in a separate variable.

Float Operator Advanced 2 is pretty much unaltered apart from the code that was needed for the logarithm to work.

Hope it helps.
7
PlayMaker Help / Re: Zenject integration
« Last post by jojoblaze on January 16, 2021, 02:27:34 PM »
For the sake of the argument I'm going to explain the situation I'm facing, maybe it could be useful for someone.
My Unity project use Zenject for dependency injection (if you don't know what is it, take a look here: https://blogs.unity3d.com/2014/05/07/dependency-injection-and-abstractions/ for a quick introduction).
I have a UIManager class that handle in-game user interface like menus, dialogues windows, notifications and so on (I'm a developer, so it's easier manage these things directly with code).
The UIManager object is instantiated by Zenject and is available for all other objects which may need it (this is the great convenience of DI).
Then I created some custom actions to handle ui at high level with PlayMaker. In this way I can show dialogues and prompt user for input, if he need to make a choice or give an answer and manage the conduct of the conversation jumping from one state to another based on responses.
In the action inspector I only need set options and text for dialogues, then the action will invoke UIManager methods passing parameters.
It's sooo flexible and now I love PlayMaker!  8)

So, what is the problem? It's about code design.
DI help to write clean and testable code (is very important!).

I managed to get it work, but I had to resort to singleton.
Despite being widely used especially in game development, has several drawbacks (look here https://stackoverflow.com/questions/137975/what-is-so-bad-about-singletons for more info).

Zenject has different ways to inject dependencies, but basically it need to manage or oversee objects instantiation in some way. It seems that FsmStateAction are instantiated through the Activator and I found no way to hook FsmStateAction instantiation.

If I'll found a way to make it work properly with injection, I'll report here, but I'd really like to know if there is some support to injection or if it's planned in some future release.
8
PlayMaker Help / Ground Check without collision event
« Last post by misterjuly on January 16, 2021, 02:13:25 PM »
Hello,

I'm wondering if there is a way to check if I am grounded without using a collision event. The reason I want to do this is because I have a collectible and when I collect it in the air, the FSM doesn't fire, but when there is no collision event, it works fine. Basically, as you might assume, I need this to prevent infinite double jumping. Thanks!
9
PlayMaker Help / Re: Make PlayerPrefs save ONLY if Player finishes the level
« Last post by heavygunner on January 16, 2021, 01:58:17 PM »
This is what I would do.

For Levels. There will be an int variable called "Level" . When player reached finish, I will send and event LEVEL FINISHED and will use action Int add and will add 1 to "Level" variable. So, That will be 2. Then, will use action Playerprefs Set Int and save that "Level" variable in new key called "level"

Same for Stars. Fire an event at Level Finished and check how many stars. and Then will use Int Compare Range action and add stars. and save thm in different key via Playerprefs
10
PlayMaker Help / Make PlayerPrefs save ONLY if Player finishes the level
« Last post by Brijac on January 16, 2021, 01:11:48 PM »
Hello, I'm having trouble make a level manager in my game and I was wondering if maybe I can do it with PlayMaker. I purchased it a while ago but unfortunately never used it.

This is an example of the game:


This is an example of the levels:


First level is unlocked in the beginning and you need to finish every level to unlock the next level. By finishing the level I mean getting to the finish collider at the end. Collecting points is optional and you can earn stars by collecting points.

The problem that I have is that I want that collected points only save if the player reaches that finish collider. It doesn't make sense that the player for example collects 70 points (which, lets say, gets him two stars), dies and still receives two stars. I want that the player earns those stars ONLY if he gets to the end, if he dies or just quits the game the points should delete and no stars should be awarded.

Is something like this possible with PlayMaker?
Pages: [1] 2 3 ... 10