playMaker

Recent Posts

Pages: 1 ... 6 7 [8] 9 10
71
Playmaker Help / Re: Hashtable get texture just won't work
« Last post by djaydino on December 10, 2018, 03:18:24 AM »
Hi,
I did a quick test and it seems to work on my end (unity 2018.2.18f1, PlayMaker 1.9, latest array maker (downloaded today))

on the 'Hash Table Get' can you try to set the key manually?

Also be sure the the reference (both inspector and actions) has no space, same for key.

Sprite is also supported, maybe the images need to be set to sprite or maybe you have an older array maker version?

If you could not get it to work, what unity/playmaker version are you using?
72
Playmaker Help / Re: Shadow Ai
« Last post by djaydino on December 10, 2018, 03:06:22 AM »
Hi.
Maybe you can use a simple bool (isUsingLight) to check if player has a torch or lantern active, before damaging the player.

You could also use a trigger area on the light source so that :
When the player is inside the light source, set 'isUsingLight' to true (or call it isInsideLightsource' for example)
73
Playmaker Help / Re: Jump controls with Character Controller
« Last post by djaydino on December 10, 2018, 03:00:31 AM »
Hi.
The character controller is build for quick testing and is not suitable for jumping,

It is best to build your own controller by using get axis and 'set velocity' or 'add force'

Then use another fsm to handle jumping.

If you want gravity handle falling you will need a Rigidbody
74
Playmaker Help / Shadow Ai
« Last post by amirkhan on December 10, 2018, 01:42:45 AM »
Hello guys i am making 2d top down game and i want to make this tyoe of function.

when player goes into the shadow area it will hurt him and drain drain the hp
if he goes into the light area it will not hurt him

i know how to implement this but the problem is that if the shadows are dynamic like 2ddl asset
then the shadow will change like if the player has lantern or torch or something or light source and he goes to shadow area i want him to not be demaged untill he hass the light source if goes out the shadow will engulf him and it will drain his hp

like darkest fear game of java me
so how do i obtain this in unity :-\
75
Playmaker Help / Jump controls with Character Controller
« Last post by Pringlestache on December 09, 2018, 12:24:59 PM »
Hey guys!

Is it possible to get midair controls while jumping/falling with the Character Controller with Playmaker?

I've been trying for a couple of days now, and can't quite get it to work.

The setup I have for the movement right now is Get Axis Vector, Controller Simple Move and Smooth Look At Direction, while jumping is basically just handled by moving the character up with iTween and letting gravity handle the falling.

I don't want to use a Rigidbody for my character, but still want to have some control when jumping, so any tips are appreciated.
Thanks in advance! :)
76
Playmaker Help / Hashtable get texture just won't work [SOLVED]
« Last post by homeworld on December 09, 2018, 12:09:42 PM »


Hi! As the picture shows, i just cannot get 'hash table get' to pick anything up from my table of textures.

At first i tried sprite, but it seems like 'hashtable get' does not support sprite at all.

Then i switched to textures like in the pic above, but no matter what i did, it'd result in nothing. I tried a 'hash table get type', and it always returns a gameobject for some reason.

I tried all permutations of 'Default', 'Sprite' and 'Editor GUI and legacy GUI' on the texture files, nothing works.

PLEASE HELP!

77
Playmaker Help / Synchronizing Mechanim with NavMesh Agent
« Last post by Maximilian0 on December 09, 2018, 07:59:02 AM »
Hi,

I know there are already some threads about that topic but none of them seem to have an answer that makes sense to me.

So far I have figured out that some of the nav agents values need to be given to the blend tree (I'm using the standard Unity Third Person Animator) to synchronize the movement with the animation and there seems to be an action that does exactly that called "Nav Mesh Agent Animator Synchronizer". However, that action has no parameters and no documentation. When I put it on my script it either breaks the Nav Agent because it doesn't seem to be able to turn anymore or it does nothing at all.

I feel that the whole thing is a little bit paradox: I need the rotation of the agent to apply on the animation, but, if I use root motion, I need the animation to make the agent rotate in the first place... admittedly I am not very good at math though.

So: do I misunderstand the mentioned action and use it wrong somehow or do I need to do additional calculations for it to work?

Thanks for any help!
78
Playmaker Help / Re: Get FSM Array Item only works once
« Last post by JohnJones on December 09, 2018, 06:16:08 AM »
Perhaps you are right, but there is no way to know
In the mean time I have tried to work around this issue, by rewriting the entire thing.

But I am getting another error now:
ArgumentException: Array was not a one-dimensional array

A similar error was discussed here:
https://hutonggames.com/playmakerforum/index.php?topic=19094.0
It is unclear to me how this person solved the issue though

I see you are the same person who reacted to that topic,
perhaps you could help me out.


Currently there is an AI script written in cs.
I send 2 arrays to the script using set-property (both are one dimensional arrays).
I call a method that runs the AI script
_____The script does its thing_______
The script then fires up an event in my FSM
The FSM uses get property to get 2 public int variables from the script
Done


Somewhere in this process unity starts burping up hundreds upon hundreds of error messages saying

ArgumentException: Array was not a one-dimensional array.
System.Array.GetValue (Int32 index) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System/Array.cs:485)
HutongGames.PlayMakerEditor.FsmSearch.FindEventsSentBy (System.Object obj, Int32 currentDepth) (at C:/Projects/Playmaker_1.9.0/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/FsmVariablesEditor.cs:835)


The error messages continue for a while after having stopped the game.

FYI:
I am only using one dimensional arrays
I am using Playmaker 1.9.0 in Unity 2018.2.13f1


Thanks for your time.
79
Playmaker Help / Re: Networking global variables via collisions VS. mouseclicks
« Last post by kropcke on December 08, 2018, 03:26:50 PM »
Hi Jean.

Per your suggestion, I'm applying my player/collider script to the green rectangular trigger, and rewrote it to account for 'GetMouseButtonDown/Up'. It almost works...

When I click the trigger on the server, the red box turns green on both the client and the server. Hooray! This part is working  :) However, when I click the trigger on the client - nothing happens and both boxes stays red.

I would like the box to turn red on both the server and the client, regardless who clicks it.

Here's my code:

Code: [Select]
using UnityEngine;
using UnityEngine.Networking;
using HutongGames.PlayMaker;

public class MouseDownYes : NetworkBehaviour
{


    void Start()
    {
    }

    [ClientCallback]

    void Update()
    {
        if (Input.GetMouseButtonDown(0))
        {
            RpcMouseDownYes();
        }

        if (Input.GetMouseButtonUp(0))
        {
            RpcMouseDownNo();
        }
    }

    [ClientRpc]

    public void RpcMouseDownYes()
    {
        Debug.Log("Pressed primary button.");

        FsmInt globalVar = FsmVariables.GlobalVariables.FindFsmInt("var_tr_1a");
        globalVar.Value = 1;
    }

    [ClientRpc]

    public void RpcMouseDownNo()
    {
        Debug.Log("Pressed primary button.");

        FsmInt globalVar = FsmVariables.GlobalVariables.FindFsmInt("var_tr_1a");
        globalVar.Value = 0;
    }

}

I'm not sure if my Playmaker setup is screwy, or if the scripting to support it is. I feel like I'm really close, but I'm not sure how to tackle the problem. Any advice would be really appreciated. Thanks so much already for all your help.

Sincerely,
kropcke
80
Playmaker Help / Re: Moving a UI element to a Vector 2 position in World Space
« Last post by Splankton on December 08, 2018, 01:35:28 PM »
Ok I have it, thanks.  I just cant get it working.  It always give me the wrong positions. I'd like to move the UI sprite over time, to the vector2 position.
The best I got was using the MoveTo action to the destination position, but it moved to the bottom left of the UI rect.
Any ideas where I'm going wrong?
Pages: 1 ... 6 7 [8] 9 10