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.


Messages - HAIRGROW

Pages: [1] 2
1
PlayMaker Help / Get/Set String Property Only returns Length
« on: January 07, 2021, 02:58:05 PM »
So I have a custom script with 3 Get/Set properties. 2 Ints and 1 String. I can use the normal Get Property on all 3 but I noticed that the string value is only showing the Length of the string in PlayMaker. If I re-write the string value as a typical Public string, then the Get Property action will provide the actual string.

Does PlayMaker not allow for Get/Set Properties on string values? Or is there another way I need to implement it?

2
PlayMaker Bug Reporting / Re: Ecosystem 0.6.8 Bad Credentials error
« on: October 28, 2020, 01:57:32 PM »
I'm having the same exact issue as well. Just did a forum search for a resolution and come across this post.

3
It's been a little over a year now, and I hadn't realized that I actually received a response to this. I need to start turning on notifications. :P

Anyways, I've been working on core game code for the past year and have now decided to shift focus back on to the Actions for the Shuriken Particle System. I'm tackling all 23 modules, sub-modules, and hidden properties. So far, I've completed 15. By using the Custom Action Editor, I've managed to compile each module from the particle system into it's own PlayMaker Action. Except for the Main Module. It's broken up into several pieces. I've looked at other actions on the Ecosystem, but I need additional control of the particle system for the VR game I'm creating.

I've been a huge fan of PlayMaker since Unity 3.5. It's part of the "secret sauce" for the combat mechanics in my game. Because this is such an extensive set, I plan to release this on the Asset Store as means to fund my game production. Version 1 will consist of the Shuriken Particle System. Later versions will include actions for Hidden Properties, External Forces, and other FXs such as the Trail Renderer.

As a side note, I've also created am extensive set of VR related actions as well. It's apart of an entire system that handles the Controller Inputs and UI interaction with both the Vive Wands and Index Controllers. This will also be another set released on the Asset Store as well.

If anyone is interested I tend to post updates via https://twitter.com/ahairgrow and https://www.instagram.com/hairgrowatl/?hl=en

4
VR Help / Re: Frame Rate Drop in Headset when testing in Editor
« on: May 18, 2019, 12:50:54 AM »
I didn't know that. I'll try that. Thanks.

5
VR Help / Frame Rate Drop in Headset when testing in Editor
« on: April 29, 2019, 07:22:07 PM »
So I've been developing a VR game for the past year using the HTC Vive and was wondering if anyone else experiences drops in frame rate when using PlayMaker and testing within the editor?

It seems that whenever I have the PlayMaker editor opened, I get a huge drop in FPS. It's even worse if I have an active FSM selected. The only way I can get around this is by closing/hiding the PlayMaker window, deselect any game objects, and make sure the Game window has focus. I'm mentioning it now because it's starting to become a hindrance. In order for me to test FSMs and makes sure things are working correctly, I want to test in the Editor instead of making a build for each little change.

Has anyone experienced this and if so, what steps did you take to overcome this?

6
General Discussion / Is it possible to Find Game Object by Type?
« on: December 20, 2018, 03:07:28 PM »
So instead using Find Game Object by Tag or Name, I'm wondering if it's possible to find a Game Object by Component. I'm trying to write my own custom action for this and have looked at the Get Component action as a reference but unfortunately I can't use FindObjectOfType within the HutongGame.PlayMaker.Actions namespace. Any help would be appreciated.

7
So I'm working on a VR game and I wanted a better way to control the particle systems with PlayMaker. I've created a pretty extensive set to do what I want, but I was curious as to what features / actions others would be interested in. I've created a few other VR related actions as well such as a VR FSM Inspector, which allows you to see that state changes for FSMs in VR. Before I put something like this out, I wanted to see if there was any interest in such a thing. Thanks.

8
PlayMaker Help / Re: Get Active State Color [SOLVED]
« on: October 10, 2018, 03:12:38 PM »
Never mind. After much tinkering, I figured out that the colors in the Preferences menu are stored in PlayMakerPrefs. So in my custom action, I created an array of those colors from the Preferences and then set my public color value to the index from that array. It works perfectly.

9
PlayMaker Help / Get Active State Color [SOLVED]
« on: October 10, 2018, 01:51:19 PM »
So I'm working on creating a custom action for debugging purposes. And I'm trying to figure out how to get the color of the Active Fsm State. I'm able to get the name of the Fsm and Active State name, but I'm not seeing a direct way to get the color of the active state. I'm working on a VR game and for debugging purposes, I created an action that set's a Unity Text Mesh to the active state name. The part I'm having problems with is getting the color of the active state in PlayMaker. Essentially I would color code all my states in PlayMaker and set the color of the Unity Text Mesh to the active state color. Thanks in advance.

10
PlayMaker Help / Re: Custom Action Editor [SOLVED]
« on: June 06, 2018, 11:12:59 PM »
After much trial and error and I finally solved my problem. I had to create a reference to other classes in my main FSMStateAction script. And then in OnEnter I call those functions with the gameobject as one of the arguments. This is great because I seriously didn't want to write one gi-normous script file for one action. Now I can off load portions of it to as many c# scripts as I want.

11
PlayMaker Help / Re: Custom Action Editor
« on: June 02, 2018, 04:58:26 PM »
Do you have a direct email I could send it to?

12
PlayMaker Help / Re: Custom Action Editor
« on: May 31, 2018, 01:57:36 PM »
So I'm still trying to find my answer by looking at the xml actions, but because it's not storing a game object with
Code: [Select]
public FsmOwnerDefault gameObject I can't find what I need.

So if daisy chaining doesn't work, does that mean I can't reference the public game object from a base class in derived classes? Right now I'm getting the "Object reference not set to an instance of an object" error in my derived class.

I just want to know before I start creating one monolithic script.

13
PlayMaker Help / Re: Custom Action Editor
« on: May 30, 2018, 06:18:41 PM »
Thanks for the reply Jean. I actually came across XML Maker and was studying those as well. From my setup, is it possible to have a base action (that doesn't show up in the browser) establish the public game object in the parent FSMStateAction class, and then have derived classes (that don't show up in the browser as well) operate on that same game object? I assumed through the power of inheritance this would work, but for some reason I'm getting "object reference not set to an instance of an object" in the derived classes.

I'm still learning the more complex parts of C# but I think we're on the same page with your explanation. Essentially all the derived classes are siblings to the parent FSMStateAction class, but one of the siblings is the Main Action that shows up in the browser. The Main Actions public variables would send it's information to the variables and functions of it's siblings, which will do all the main work.

I thought about daisy chaining each section via inheritance such that the last child in the hierarchy would be the Main Action that has access to all of it's parents variables. But now that I'm getting the object reference error, even though I'm using derived classes, I'm not sure daisy chaining would work. And then, I don't want to string them all together in such a linear fashion, just in case I need to make a change to one of the parents, which would ultimately effect its children.

14
PlayMaker Help / Custom Action Editor [SOLVED]
« on: May 29, 2018, 02:09:19 AM »
So I'm in the process of creating a custom action and I wanted to know if its possible to create a single action from multiple script files?

First, let me say that I'm an artist who's still learning C#, but I understand all the basics. Enough to be able to successfully write a single working custom action. The action that I'm writing is comprised of several "settings" such as check boxes, public variables, and drop drown menus. I've got each section of the action working separately (as it own "Action" for testing purposes), but instead of writing one long gigantic script file for the whole action, which would ultimately work, I would like to break it down in to smaller chunks of code (classes) that then get compiled together via the Custom Action Editor.

After studying the Quaternion Actions, I saw how each action was a child to the parent class QuaternionActionBase. Then, each action, as well as QuaternionActionBase, has it's own Custom Action Editor script, which are all children of the QuaternionCustomEditorBase class. So, with the concept of Inheritance in mind and to prevent my script from becoming massively long, I want to know if it's possible to write the entire action in separate classes. So that way I can focus on each section of the code, get it working, and then use Action Editor to arrange all the fields.

As I'm learning more about the Custom Action Editor, I'm wondering if I could write each section of the action as a separate script file, with each script using it's on custom editor, and then create a parent editor that bring all the children (fields) together in one action. Is this possible or am I going about this the wrong way?

What I've discovered thus far, is that the Action Editor only works on the script that it's pointed to. So for the Quaternions for example, GetQuaternionEulerAnglesCustomEditor.cs , will only work on GetQuaternionEulerAngles.cs, because of this line here:

[CustomActionEditor(typeof(GetQuaternionEulerAngles))]

If that's the case, will I have to suck it up and put everything into the main action and utilize 1 Custom Editor Script for the action?

Like I said, I'm learning more and more about C# and what's possible so it would awesome to create smaller modules that I could then bring all together.

Thanks in advance for any advice given.

Here's an example of what I'm trying to do

Code: [Select]
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

/// <summary>
/// This is the parent class. It's only job is to establish the public gameobject variable.
/// All subsequent scripts will be derived from this class, so they all will have access to the parent game object.
/// </summary>

namespace HutongGames.PlayMaker.Actions
{

    public abstract class SampleActionBase : FsmStateAction
    {
        [RequiredField]
        [Tooltip("The Game Object")]
        [CheckForComponent(typeof(GameObject))]
        public FsmOwnerDefault gameObject;
        public GameObject go;


    }
}

Code: [Select]
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

/// <summary>
/// This is a child to SampleActionBase.
/// It would contain most of the settings,while the rest comes from another script.
/// This would be the script that actually shows up in the Action Browser
/// </summary>

namespace HutongGames.PlayMaker.Actions
{

    [ActionCategory("Get Some")]
    [Tooltip("Tips! Tips! Tips!")]

    public class SampleAction : SampleActionBase
    {

        public FsmFloat time;
        public FsmBool looping;


        public override void Reset()
        {

            time = null;
            looping = true;
        }

        public override void OnEnter()
        {

            DoStuff();
            Finish();

        }

        public void DoStuff()
        {
            go = Fsm.GetOwnerDefaultTarget(gameObject);

            // Then do some stuff with this


        }

    }


}

Code: [Select]
using UnityEngine;
using UnityEditor;
using HutongGames.PlayMaker.Actions;
using HutongGames.PlayMakerEditor;

/// <summary>
/// Not sure what to put here. With this being the parent I thought I could
/// expose public FsmOwnerDefault gameObject; here so all children the UI would show up in a child classes,
/// but then I figured out I didn't have to do that.
/// </summary>

public class SampleActionUIBase : CustomActionEditor
{

    public override bool OnGUI()
    {
        return false;
    }

}

Code: [Select]
using UnityEngine;
using UnityEditor;
using HutongGames.PlayMaker.Actions;
using HutongGames.PlayMakerEditor;

/// <summary>
/// This script controls the interface for the SampleAction script.
/// I'd like to add Edit Fields from other scripts in this file.
/// so I could organize each section of the UI.
/// </summary>

[CustomActionEditor(typeof(SampleAction))]
public class SampleActionUI : SampleActionUIBase
{
    StartDelayUI startDelayInst;

    public override bool OnGUI()
    {

        EditField("gameObject");
        EditField("time");
        EditField("looping");


        GUILayout.Label("Next Section");

        //I'd like to place EditFields from other script files here.
        //Thus giving me more control over the layout of the interface
        // And making it easier to manage all the code.
;

        return GUI.changed;
    }
}


15
VR Help / Re: Issues with Get Controller Velocity - always 0,0,0 ?
« on: May 23, 2018, 02:08:30 PM »
Turn off isKinematic on the rigidbodies for the controllers, and you should able to obtain the velocity. I'm doing the same thing, but for the Vive. Hopefully it works for Occulus.

Pages: [1] 2