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 - plinm

Pages: [1]
1
Hi there,

It seems to be a bug, having a Call Method action in a state will cause renaming the state nearly impossible. No matter what you type in the state name, it will lose focus immediately, and the problem disappears after removing the Call Method action.

2
Hi there,

I am trying to use ArrayContains to check null reference in an array of objects (AudioClip), I leave some fields in the array unsigned and leave the Value filed in the action inspector empty, but I found it will always return not contained event.

Adding debug line in the ArrayContains action gives me this:

Code: [Select]
// output "null" in console
Debug.Log(value.GetValue());
// output "Null" in console
Debug.Log(array.Values[0]);

Note that case difference in two Null/null?

Then I try compare them to null:

Code: [Select]
// output "False" in console
Debug.Log(value.GetValue() == null);
// output "True" in console
Debug.Log(array.Values[0] == null);

Dig in further:

Code: [Select]
// output "UnityEngine.Object" in console
Debug.Log(value.GetValue().GetType());
// throws NullReferenceException
Debug.Log(array.Values[0].GetType());

SO I guess FsmVar internal did something with empty/null data and basically it is not possible to use ArrayContains to check null element.


3
Hi there,

I am using GetAngleToTarget action to calculate some angle between two objects, and then use the angle to do some other calculation, but the GetAngleToTarget action is NOT performing the calculation in OnEnter which means by the time I use it, the value will be the 0 (default).

I don't think that's the intend behaviour of the action and it does not mention anything in the tooltip or documentation.


4
Hi

I might reach a bug or something, here is what I did.

Create a gameobject from prefab and send multiple events to it with event target set to Game Object FSM (need input the name of the FSM), the target FSM will only receive the one event, and the event is not received at the same time as it sends.

If I change the event target to Game Object, then the problem is gone.

I have attached a test scene as well, need PlayMaker pre-installed.

Cheers

5
Hi there,

I have a set of actions in FSM, which creates a gameobject from prefab and then send event to the instance for intialization. It works fine in 1.8.4, but in 1.8.5, the created gameobject shows empty content for a short period of time after creation, it seems the initializing event is not triggered in the same frame.

Any idea?

Thanks.

6
PlayMaker Help / Unexpected changes when using PlayMaker with VCS
« on: August 03, 2017, 05:08:41 AM »
Hi, there

I constantly found PlayMaker would make changes to committed prefabs with PlayMakerFSM attached. For example, a git-diff here

Code: [Select]
- preprocessed: 1
+ preprocessed: 0

I have seen this in few prefabs I committed previously, while I did not touch them at all. I wonder what this "preprocessed" means, it looks like a boolean flag that used internally by PlayMaker which I cannot control. SO my question is how can avoid this, it is bit annoying to have unexpected changes now and then when you are working with version control.

Also, are there any suggestion or good practice to follow when using PlayMaker with VCS?

Many thanks.

7
Hi, there

I found the Awake in custom actions are called right after game stops in Unity Editor, which means it is called twice in a single run. I wonder if it is a BUG or intended design?

Since the Awake is called after the game stops, which causes any changes I made to scene in Awake function will be kept forever. So I have to add following code to make it work:

Code: [Select]
public override void Awake()
{
    #if UNITY_EDITOR

    if (!Application.isPlaying)
    {
        return;
    }

    #endif

    // the actual Awake code here
}

I am complete beginner to PlayMaker, so I am NOT sure if I was doing something wrong. Any help is appreciated.

Pages: [1]