playMaker

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - tcmeric

Pages: 1 [2] 3 4
16
Tutorial and custom action.

1. Imagine you want to throw your grenade (or missile or whatever) to a specific location, from a specific location. Ie, from your hand to the bad guys face. But how do you know exactly how much force to apply to get that rigidbody grenade to land at the exact spot? Watch the tutorial and download the custom actions from my github account!

It only takes 1 action to calculate and 1 action to launch. Easy.

2. Imagine you want to predict the path of that grenade BEFORE you throw it. And render the line on screen to show your players. That way they can decide if they want to throw it. I have a custom action for that too! (Please note, this second custom action set requires a paid asset called "Trajectory Predictor". https://www.assetstore.unity3d.com/en/#!/content/55752

I wrote a custom playmaker action to predict the path from playmaker (to use with this asset). The action is free, the asset is not.

All of this is covered in my tutorial here on youtube: https://www.youtube.com/watch?v=SH-c1hqdELU&t=248s

This is all rigidbody based (no animations), so that your grenade can hit a wall or bounce off the floor naturally. These calculations work with any height! No need for a flat ground.

Actions can be found here (although I strongly suggest you watch the tutorial first: https://github.com/dumbgamedev/general-playmaker/tree/master/projectiles

If you like these custom actions and tutorials, feel pledge a few $ into my patreon account. https://www.patreon.com/playmaker

17
Playmaker Help / Unity List to Array or ArrayMaker
« on: June 08, 2017, 07:08:19 AM »
I am creating action for opsives third person controller (can be found here: https://github.com/dumbgamedev/thirdpersoncontroller_playmaker)

There is a method that returns a list of inventory items. I am trying to figure out how to get that list into a playmaker FSM array or arraymaker array.


Method:
void Opsive.ThirdPersonController.Inventory.GetAvailableItems ( ref List< ItemType >    itemTypes)   

Returns a list of items which are currently available in the inventory.
itemTypes The list of items which are currently available.

Documentation: https://www.opsive.com/assets/ThirdPersonController/API/class_opsive_1_1_third_person_controller_1_1_inventory.html#a815d5b4f2f50267b7572930771279292

Any ideas or examples?

18
Playmaker Tutorials / Ragdoll - Hit Reaction Manager (plus actions)
« on: May 25, 2017, 07:56:58 PM »
https://www.youtube.com/watch?v=FZ_5jVoOrow

In this tutorial we look at getting hit reactions using the third party asset "Ragdoll - Hit Reaction Manager" along with playmaker. We use three methods to trigger hit reactions including setting a manual location, mouse click and raycast. Great for natural reactions to gunshots, collisions and other "hits".

I wrote some custom actions to work with this asset (and helper actions). You can download them for free from my github account, linked below.

Asset Purchase: https://www.assetstore.unity3d.com/en/#!/content/46513
Playmaker Actions: https://github.com/dumbgamedev/hitmanager_playmaker
Playmaker Slack Channel Chat: https://invite-playmaker-slack.herokuapp.com
Patreon: https://www.patreon.com/playmaker

19
Do we already have an action to get the direction and distance between two objects (without raycasting) ? I couldnt see one.

https://docs.unity3d.com/Manual/DirectionDistanceFromOneObjectToAnother.html

If not, I will write one because I need it. But if we have one, better not to write another. Thanks!

20
Playmaker Help / Remove Items from Playmaker Array
« on: May 21, 2017, 06:10:20 AM »
I am trying to remove all items from a playmaker array (not arraymaker's array).

The action "array clear", just changes all my gameobject to null in the array (which is not really removed).

The action "array delete at", only removes on item based on index number.

How can I clear/remove all the items from the array, so its count is once again 0?

Thanks!

21
Feature Requests / Gradient Support
« on: May 17, 2017, 05:17:58 AM »
Are we able to get gradient support for a future version? Either FsmGradient or maybe some kind of gradient color picker?

Is it possible to use a custom inspector/picker in playmaker right now?

Thanks.

22
Unitys built in NavMeshAgent.remainingDistance can return the result of infinity (instead of the correct distance) when two or more corners (path points) have been calculated. This means the playmaker action "Get Agent Remaining Distance" is not reliable in many cases (as it is using NavMeshAgent.remainingDistance).

An alternative method is calculating the corners (path points) distance instead. An example is given in the unity documentation. I used the documentation to create an action to do so.

https://github.com/dumbgamedev/general-playmaker/blob/master/path/calculateAgentDistanceByCorners.cs

Ive tested it out several times and it returns the same result as the action Get Agent Remaining Distance, except it never returns infinity (good!).

Maybe this action plus the path debug action I posted should be added to the playmaker navmesh package? (Might need name changes/ different category).

23
Share New Actions / Debug Navmesh Agent Path Action
« on: April 30, 2017, 03:52:08 AM »
This action debugs the navmesh agent path.

A navmesh path can be complete, partial (in which can it will try to recalculate if you have that option set to true on your agent component), or incomplete.

This action will check your calculated agent path and check to see if it is complete, partial or incomplete and then fire a a corresponding event.

You can download it from my github account, under MIT (free to use, no need to attribute) license. https://github.com/dumbgamedev/general-playmaker/blob/master/path/debugAgentPath.cs


24
Share New Actions / Line Renderer Set Gradient
« on: April 29, 2017, 01:17:16 AM »
So in 5.5, you cannot set a color to a line renderer anymore because it now uses a gradient. (I think its from 5.5 forward).

I needed a 2 color gradient for my lines, so I wrote this. Of course it could also work for 1 color, if you just set both colors to be the same. It also allows you to set the color location, alpha amount and alpha location (time). Basically everything you need to set a color gradient on a line renderer.

Enjoy: https://github.com/dumbgamedev/general-playmaker/tree/master/lineRenderer

25
Playmaker Help / Custom Action - Either or Component
« on: April 25, 2017, 11:07:49 AM »
I have a playmaker action that could be for 1 of 2 different component (scripts). In this case

1. textmeshpro
2. textmeshpro UGUI

My script does a simple check and then runs the nessesary function if/else the script is attached (I will improve this with an error check after, and use if, if else, else).

However, the problem is that

A. Its ugly. Is there a better way to do this? If else is ok, but I feel I am doing too much code in the if else?

For void update(), I need to do the check again? (for everyframe options).

Any ideas?

Code: [Select]
// (c) Eric Vander Wal, 2017 All rights reserved.
// Custom Action by DumbGameDev
// www.dumbgamedev.com

using UnityEngine;
using TMPro;

namespace HutongGames.PlayMaker.Actions
{
    [ActionCategory("TextMesh Pro Basic")]
    [Tooltip("Set Text Mesh Pro Text.")]

public class  setTextmeshProText : FsmStateAction
{
[RequiredField]
[Tooltip("Textmesh Pro component is required.")]
public FsmOwnerDefault gameObject;

[RequiredField]
[UIHint(UIHint.TextArea)]
[TitleAttribute("Textmesh Pro Text")]
[Tooltip("The text for Textmesh Pro.")]
public FsmString textString;

[Tooltip("Check this box to preform this action every frame.")]
public FsmBool everyFrame;

// for textmesh pro
TextMeshPro meshproScript;
// for textmesh pro UGUI
TextMeshProUGUI meshproUguiScript;

public override void Reset()
{

gameObject = null;
textString = null;
everyFrame = false;
}

public override void OnEnter()
{
var go = Fsm.GetOwnerDefaultTarget(gameObject);

TextMeshPro tmp = go.GetComponent<TextMeshPro>();

// if textmesh pro normal script attached, do this
if (tmp != null)
{
Debug.Log("TextMesh Pro Script Attached");
meshproScript = go.GetComponent<TextMeshPro>();

if (!everyFrame.Value)
{
DoMeshChange();
Finish();
}

}

// if textmesh pro Ugui is attached
else
{
Debug.Log ("TextMesh Pro UGUI Script Attached");
meshproUguiScript = go.GetComponent<TextMeshProUGUI>();

if (!everyFrame.Value)
{
DoMeshChangeUgui();
Finish();
}
}

}


// textmesh pro normal script
void DoMeshChange()
{
var go = Fsm.GetOwnerDefaultTarget(gameObject);
if (go == null)
{
return;
}

meshproScript.text = textString.Value;
}


// textmesh pro ugui script
void DoMeshChangeUgui()
{
var go = Fsm.GetOwnerDefaultTarget(gameObject);
if (go == null)
{
return;
}

meshproUguiScript.text = textString.Value;
}

}
}

26
Share New Actions / Textmesh Pro Playmaker Actions (free)
« on: April 24, 2017, 12:50:16 AM »
The Textmesh Pro playmaker action set has now been released for free under a MIT/LGPL license (free to use in your game, no need to add into credits) by myself (Dumb Game Dev).

https://github.com/dumbgamedev/TextMeshPro_Playmaker

As well, I have made a basic intro video for these actions. I highly suggest you check out Textmesh Pro, which is now free on the asset store. This is really a big step-up for text in Unity. It is all free, and if you are not already using it in your project, you should now!!!

https://www.youtube.com/watch?v=G7l-qPeZteE&feature=youtu.be

One last thing to note, is that this project was funded through my Patreon account. If you do use this asset, or would like to see more free playmaker actions, please consider contributing a few dollars a month. https://www.patreon.com/playmaker

The next releases in the pipeline for my Patreon account are actions for Post Processing Stack (free on the asset store), Beautify (another great post processing asset that I use myself often) and Liquid Volume (by the same authors as Beautify).

To Note: There are still a few issues with the actions for mobile shaders. If you run into any bugs, please report them so I can make corrections. (Shaders are tricky and this asset comes with a whole bunch).

27
I am trying to create a custom action that listens for a c# delegate event and returns an event argument (event payload). Unfortunately I am having some difficulty here. This is my first time working with unity delegates and events. If there are some playmaker actions that are already do this, maybe it will help me work it out.

This is the documentation here: https://vrtoolkit.readme.io/docs/vrtk_destinationmarker

And I am trying to get the event payload "Vector3 destinationPosition".


28
Playmaker Help / NavMesh Remaining Distance
« on: April 21, 2017, 07:38:46 AM »
I am using the pathfinding package for playmaker. I am using the action "get agent remaining distance", which works well.

However, I would like to set a destination without starting movement (so I can calculate the distance before I choose to move or not). Ie, if it is too far, my player may decide not to move.

When using the "Set Agent Destination as Game Object", it begins to move towards the destination right away. It does not wait for the "Agent Move" action.

I can use "Agent Pause" and then choose "Agent Resume" when I am ready to move. But, is there a way to calculate a navmesh path without movement the starting on my gameobject?

Lastly, how is this path stored? (I plan on writing a script that will allow the player to see the possible path and distance before committing to it). I dont think there is a way in playmaker to display the saved path (correct?)

Thanks!

29
Share New Actions / Free Playmaker Actions for Xweapon Trails
« on: April 19, 2017, 07:40:13 AM »
I have created free playmaker actions for xweapon trails. You can download them from my github account here: https://github.com/dumbgamedev/XWeaponTrail_Playmaker

The Xweapon Trails asset is about 8$ now on the asset store. It creates nice smooth weapon trails after swinging your weapons around (can be 3d, 2d or VR). You can add trails to add kinds of objects (doesnt need to be weapons). Anything you want a swoosh movement after. I choose this one because it has a 5 star rating and tons of buys.
https://www.assetstore.unity3d.com/en/#!/content/20972

I created a tutorial how to set it up in VR and use my actions (however the same principle applies for 3d or 2d). https://www.youtube.com/watch?v=1pBK8OB0r8o&t=539s

30
Share New Actions / Outline Effect - Custom Playmaker Actions (Free)
« on: April 19, 2017, 07:01:05 AM »
I have created some free playmaker actions for the store asset Outline Effect (which is also free). This asset allows you to add a outline effect to objects (game objects, text, sprites, etc). It can change color, width, etc. With my playmaker actions you can do things like change colors on the fly (during game time), enable/disable highlight, etc.

You can download the playmaker actions here: https://github.com/dumbgamedev/outlineEffect_Playmaker

You can download the asset here: https://www.assetstore.unity3d.com/en/#!/content/78608

You can watch my tutorial on how to use this asset with or without playmaker here: https://www.youtube.com/watch?v=0nLzMHOtc4E&feature=youtu.be

Pages: 1 [2] 3 4