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 - C.J.Geringer

Pages: 1 2 [3] 4
31
Thank you for the quick reply.

I will bump next week.

32
Thank you for your answer.

is there a way to set which state machine the script sincronizes to? the examples I have found only have one FSM per object. And the component seems to only allow me to select which object it syncrhonizes, but not which FSM in a given Object.

Seems like the "Getcomponents' method only exixsts in Monobehaviour, and since mecanim´s behavious do not extend from mono behaviour, they do not have that capability.

I need at least to be able to synchronize different animator layers with diferent FSMs in a same object.

33
I am currently trying the following code:

Code: [Select]
using UnityEngine;
using System.Collections;
using HutongGames.PlayMaker;

public class MecPMSendEvent : StateMachineBehaviour {


public string TargetFSMName;
public string EventName;
private PlayMakerFSM  TargetFSM;

// OnStateEnter is called when a transition starts and the state machine starts to evaluate this state
override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex) {

PlayMakerFSM[]temp= GetComponents<PlayMakerFSM>();
foreach(PlayMakerFSM fsm in temp){
if (fsm.FsmName==TargetFSMName){
TargetFSM=fsm;
break;
}


}
}


// OnStateUpdate is called on each Update frame between OnStateEnter and OnStateExit callbacks
//override public void OnStateUpdate(Animator animator, AnimatorStateInfo stateInfo, int layerIndex) {
//
//}

// OnStateExit is called when a transition ends and the state machine finishes evaluating this state
override public void OnStateExit(Animator animator, AnimatorStateInfo stateInfo, int layerIndex) {

TargetFSM.Fsm.Event(EventName);


}

// OnStateMove is called right after Animator.OnAnimatorMove(). Code that processes and affects root motion should be implemented here
//override public void OnStateMove(Animator animator, AnimatorStateInfo stateInfo, int layerIndex) {
//
//}

// OnStateIK is called right after Animator.OnAnimatorIK(). Code that sets up animation IK (inverse kinematics) should be implemented here.
//override public void OnStateIK(Animator animator, AnimatorStateInfo stateInfo, int layerIndex) {
//
//}
}

but I get an erro that says "the name 'GetComponents' does not exist in the current context.

Would someone be able to tell me what I am doing wrong?

34
Now that unity allows one to attach C# scripts as behaviours in mecanim clips, I am trying to have mecanim behaviours send an event by name to state machines.

Currently the Mecanim Behaviour sends the event name to a monobehaviour attached to the object and then that monobehaviour send the event to the FSM machine.

I want to eliminate this intermediate script.

What is the best way to have two public string variables in the mecanim (Event Name and FSM name), and have the mecanim behaviour send the event to the specified FSM? (the FSM is in the same gameobject controlled by the mecanim animator)

35
Playmaker Help / Re: Help, modifying SendEventbyName
« on: March 18, 2015, 05:16:16 AM »
I may be missing something, but checking in the manual and int he editor, when the action "send Event' is used it gives the option of choosing an specific FSM to receive the event. From the manual: https://hutonggames.fogbugz.com/default.asp?W34

 
Quote
GameObject Fsm

Only send this event to a specific Fsm off a given GameObject. Event must be marked global

This option seems to be absent in "send event by name": https://hutonggames.fogbugz.com/default.asp?W834

I need to send an event by name to a specific FSM in the game object because I have two identical but independent FSMs in the same object, and I will have many problem if the event is sent to both when it should have been sent to only one.

36
Playmaker Help / Help, modifying SendEventbyName
« on: March 17, 2015, 04:31:00 PM »
Hello, can someone, please tell me what is the easiest way to change the action "send event by name" to allow me to specify an fsm to send the event to, like "send event" does?

I tried looking at the script of 'send event", but couldn´t pinpoint where exactly it does this.

thank you for your time

37
Playmaker Tips & Tricks / Re: Making a First Person Controller
« on: December 09, 2014, 04:01:36 PM »
I can´t see the example in the first post for some reason, anyone else have the same problem?

38
General Discussion / Playmaker 1.8 Relese Date
« on: October 02, 2014, 01:36:47 PM »
Is there an expected release date for the next version of playmaker? or just "coming soon"?

I looked for it and did not find it anywhere.


39
User Showcase / Re: Squarebite Inventory Asset package - NEW VERSION 3.0
« on: September 14, 2014, 06:31:02 PM »
Played a bit with the demo. it says to use "wasd" to move, however  "A" and "D" seemed to do nothing. is there a way to draw weapons and attack/block?

40
Playmaker Tutorials / Re: Official Tutorial Request Thread
« on: August 01, 2014, 10:03:06 AM »
A roguelike tutorial would be greatly appreciated.

41
Playmaker Help / Itween rotation shake and rigidbodies
« on: April 28, 2014, 04:50:44 AM »
I have an Itween rotation shake on a FSM, that works ok, but stops working when I add a rigid body, or make the object a physics object.

Does someone know how I can solve this?

Thank you for your time

42
Playmaker Tutorials / Re: Official Tutorial Request Thread
« on: April 16, 2014, 08:01:24 AM »
I would love a tutorial that shows how to best setup a camera/controller scheme like
Oni´s http://www.youtube.com/watch?v=C6i5pdTbMQ0

Or Forge´s http://www.youtube.com/watch?v=21yoW7mpBxo

It´s similar to an FPS camera, so I think it wouldn´t be too troublesome.

43
Work In Progress... / Re: [Community] Example Scene Requests Thread
« on: March 23, 2014, 04:15:09 PM »

Thank you very much for this

Regarding the "AngryShips" Project, I saw there are two enemie sint he rpoject, but none in the example scene, and if I simply drop ane nemy in the example scene it does nothing but shot forward without causing or taking damage.

Can I spawn the enemies in the scene, or were they never finished?



44
Playmaker Help / Set Fsm String not showing all fields
« on: February 05, 2014, 04:27:08 PM »
According tot he manual, the action "Set Fsm String" has five fields:

https://hutonggames.fogbugz.com/default.asp?W347

Howver when I add the action to my FSM it shows neither the "Fsm Name",nor the "Set Value" fields.

Can someone please help me?

45
User Showcase / Re: After! New RPG game with 100% Playmaker
« on: November 04, 2013, 05:29:48 AM »
Is there any news on the kit´s release date?

Pages: 1 2 [3] 4