Playmaker Forum

PlayMaker Updates & Downloads => Share New Actions => Topic started by: jeanfabre on July 16, 2018, 04:33:53 AM

Title: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: jeanfabre on July 16, 2018, 04:33:53 AM
Hi Everyone,

 So Unity Module Cinemachine is supported via the PlayMaker Ecosystem, make sure you grab this to get all the custom actions and proxies you need to control cinemachine.

(https://i.imgur.com/ejrVz4m.png)


Make sure you get the right version. The 2017 version works with the Asset store version, while the 2018 version works with the Package Manager version.

 Bye,

 Jean
Title: Re: Cinemachine Support [JULY 2018]
Post by: shamo on September 06, 2018, 08:47:40 AM
Just playing with this now...awesome .. thanks!
Title: Re: Cinemachine Support [JULY 2018]
Post by: Thore on September 20, 2018, 07:11:36 PM
Perfect, thanks!
Title: Re: Cinemachine Support [JULY 2018]
Post by: craigz on September 25, 2018, 11:04:44 PM
Hi Jean!

I just imported this (and the Cinemachine 2.2.7 from package manager) into Unity 2018.3.0b2 and am getting a couple errors. Not sure if beta specific or not, just wanted to give a headsup :)

(https://i.imgur.com/23SK0t7.png)

Code: [Select]
Assets/PlayMaker Cinemachine/Actions/Common/CinemachineActionGetAxisSettingsBase.cs(75,49): error CS1061: Type `Cinemachine.AxisState' does not contain a definition for `m_InvertInput' and no extension method `m_InvertInput' of type `Cinemachine.AxisState' could be found. Are you missing an assembly reference?
Code: [Select]
Assets/PlayMaker Cinemachine/Actions/Common/CinemachineActionSetAxisSettingsBase.cs(74,30): error CS1061: Type `Cinemachine.AxisState' does not contain a definition for `m_InvertInput' and no extension method `m_InvertInput' of type `Cinemachine.AxisState' could be found. Are you missing an assembly reference?
Title: Re: Cinemachine Support [JULY 2018]
Post by: Thore on September 26, 2018, 09:57:11 AM
Thanks for the actions, Jean. Wanted to report that I have the same/similar errors like craigz (I know it was with the same file).
Title: Re: Cinemachine Support [JULY 2018]
Post by: craigz on September 27, 2018, 11:41:33 AM
Bumpity bump :)

@Thore
Good to know it wasnt't just me ;D
Title: Re: Cinemachine Support [JULY 2018]
Post by: craigz on September 27, 2018, 04:40:38 PM
Also wanted to follow up, I removed cinemachine, did a fresh import, then reimported ALL, and the previous errors went away.

Though now I get this error.

Code: [Select]
Assets/PlayMaker Cinemachine/Components/CinemachineBrainProxy.cs(30,43): error CS0123: A method or delegate `CinemachineBrainProxy.HandleCameraActivatedAction(Cinemachine.ICinemachineCamera)' parameters do not match delegate `UnityEngine.Events.UnityAction<Cinemachine.ICinemachineCamera,Cinemachine.ICinemachineCamera>(Cinemachine.ICinemachineCamera, Cinemachine.ICinemachineCamera)' parameters
Title: Re: Cinemachine Support [JULY 2018]
Post by: jeanfabre on October 01, 2018, 03:00:00 AM
Hi,

 ok, I updated Cinemachine on the Ecosystem.

Make sure you get the 2018 version if you are working on 2018. The 2017 version is not compatible.

(https://i.imgur.com/ejrVz4m.png)

 Bye,

 Jean
Title: Re: Cinemachine Support [OCTOBER 2018]
Post by: craigz on October 01, 2018, 11:31:36 AM
Excellent! Thanks Jean :D
Title: Re: Cinemachine Support [OCTOBER 2018]
Post by: kwint on November 06, 2018, 12:20:17 PM
Hi,

I can't get the Cinemachine package actions working ?

Code: [Select]
Assets/PlayMaker Cinemachine/Actions/Common/CinemachineActionSetAxisSettingsBase.cs(30,10): error CS0246: The type or namespace name `DisplayOrder' could not be found. Are you missing an assembly reference?
I'm working with Unity 2018.1.0.f2 and Cinemachine 2.2.7 (package manager)

I would really appreciate any help !

Thanks in advance.
Title: Re: Cinemachine Support [OCTOBER 2018]
Post by: jeanfabre on November 07, 2018, 03:23:46 AM
Hi,

make sure you update PlayMaker, it's likely because you have an old version.


 Bye,

 Jean
Title: Re: Cinemachine Support [OCTOBER 2018]
Post by: kwint on November 07, 2018, 02:53:56 PM
It's working now !

Merci beaucoup Jean !
Title: Re: Cinemachine Support [DECEMBER 2018]
Post by: jeanfabre on December 19, 2018, 02:43:01 AM
Hi,

 New version to support Impulse Extension to be generated with an action, mind you, you can use callMethod to call the component to generate the impulse, but an action is nicer.

https://twitter.com/JeanAtPlayMaker/status/1075294325007884288 (https://twitter.com/JeanAtPlayMaker/status/1075294325007884288)

 You also have getter and setter actions for Impulse Source and Listener Component. I tried to cover all of the properties, let me know if you need something else :)

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: Krillan87 on April 24, 2019, 04:06:24 AM
Hi!
Will there be any updates on this packaged? I feel that there are alot of usable actions that are missing (or maybe I misunderstand how to use the actions?).

For instance. I can't find a way to change any of the "body values"? These are (more or less) the only values I would like to change but I can't change them with either "Set property" nor "Call method" nor these new actions.

https://imgur.com/a/aOpzrw6

/ Christian
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: jeanfabre on May 20, 2019, 03:00:35 AM
Hi,

 yes, for sure, the api is not complete, and indeed, it's good that you raise your voice and make requests on what you would like to access.

basically, it's way too much to port everything from such a huge api in one go,  nor cost effective The cinemachine api is very complex ( it's an understatement, it's the same level of complexity as the playable api... just jaw dropping... it seems they did it on purpose to prevent average developers to understand it...),

So I ported what I think is the core and essential part, relying on :

- developers who can script to simply create more actions based on the existing ones
- non developers to make requests like you did.

I have few more todos ( understatement), so please bump me mid week ok? and I'll get it done.


 Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: Krillan87 on June 14, 2019, 05:21:19 AM
Hi,

 yes, for sure, the api is not complete, and indeed, it's good that you raise your voice and make requests on what you would like to access.

basically, it's way too much to port everything from such a huge api in one go,  nor cost effective The cinemachine api is very complex ( it's an understatement, it's the same level of complexity as the playable api... just jaw dropping... it seems they did it on purpose to prevent average developers to understand it...),

So I ported what I think is the core and essential part, relying on :

- developers who can script to simply create more actions based on the existing ones
- non developers to make requests like you did.

I have few more todos ( understatement), so please bump me mid week ok? and I'll get it done.


 Bye,

 Jean

Hi! Just wanna check in on how the process on the porting are moving on? If I could request I would like some way of interacting with the properties that a marked on the picture above. Right now I need one separate CM camera just to change the "Screen Y" value with 2.0, which makes a lot of cameras in my scene hehe

/Christian
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: jeanfabre on June 14, 2019, 09:58:22 AM
Hi,

 please bump me mid next week, right now, I have to publish and finish few more work before tackling this.

 thanks for your patience! :)

 Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: Krillan87 on June 24, 2019, 05:21:31 AM
Hi,

 please bump me mid next week, right now, I have to publish and finish few more work before tackling this.

 thanks for your patience! :)

 Bye,

 Jean

Bump! ;)
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: jeanfabre on July 04, 2019, 03:54:58 AM
Hi,

 yeah.. sorry guys, I was out for all these weeks, but I am back now, but it means I have to do some catch up as well...

Please bump me again end of next week. thanks for your patience! :)

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: Krillan87 on September 09, 2019, 03:46:20 AM
Hi,

 yeah.. sorry guys, I was out for all these weeks, but I am back now, but it means I have to do some catch up as well...

Please bump me again end of next week. thanks for your patience! :)

Bye,

 Jean

Bumpie bump  ;)
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: jeanfabre on September 10, 2019, 03:14:09 AM
Hi,

 yes, I am on it!

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: jeanfabre on September 11, 2019, 04:50:35 AM
Hi,

 ok, done, it's on the ecosystem, you can now access the body framing transposer values to set and get them.

VirtualCameraGetFramingTransposerSettings
VirtualCameraSetFramingTransposerSettings

Let me know how it goes!

 Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [DECEMBER 2018]
Post by: Krillan87 on September 11, 2019, 06:44:58 AM
Hi,

 ok, done, it's on the ecosystem, you can now access the body framing transposer values to set and get them.

VirtualCameraGetFramingTransposerSettings
VirtualCameraSetFramingTransposerSettings

Let me know how it goes!

 Bye,

 Jean

Amazing work! It works very well. I have one request, if it is not to hard to make. Right now when I change values in the framing transposer, the camera almost snaps to the new value. So if I change the Screen Y from 0.3 to 0.6 the change happens instant without a nice smooth transition like when I change the priority between cameras.

The info text on the every frame box says: "repeat every frame, useful for animations". If i tick the box it feels like it is more smooth but I would be nice to have the transition/change be more smoother.

Of course I can just use a float interpolate between the two values and then use that as a transition but I was wondering if it is possible to add this option straight in the action itself?

Edit:
Never mind, Jean. I just realize t hat the interpolate-action is very easy so you do not need to put in a lot of work for my lazy request. However, I guess that now when we have access to the transposer settings people will use this instead of swapping cameras back and forth so in the future the smooth-feature could be very useful.
Title: Re: Cinemachine Support [ECOSYSTEM] [SEPTEMBER 2019]
Post by: jeanfabre on September 11, 2019, 06:57:07 AM
Hi,

 I'd rather not... that would be way too much duplication of code, because each property would need this treatment individually, it's best to animate the value yourself with the ease action really.

Sorry :)

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [APRIL 2020]
Post by: jeanfabre on April 09, 2020, 03:32:01 AM
Hi,

 new update for cinemachine, with more controls over axis properties for the free look, you can now control recentering.

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: jeanfabre on May 26, 2020, 02:40:13 AM
Hi,

 New version on the Ecosystem, with updated PlayMaker Utils and new actions to get and set Virtual Camera Aim/POV axis settings.

Make sure you post requests on Cinemachine support, their api is very large and so it helps me if you tell me what you want to control from playmaker.

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: CommanderPete on May 26, 2020, 05:31:23 PM
Hey.
I asked this question in the forum a while ago on a different thread. I am using Ecosystem 0.6.8 and can find most of the things I need. However, Cinemachine does not pop up when I search for it. I know it should, but it doesn't.
I am puzzled :D
Does anyone have or, hopefully, has had that problem, too?
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: jeanfabre on May 27, 2020, 01:31:42 AM
Hi,

 what version of Unity are you using? I am aware of this, you are not the only one, but I can't repro currently, I am investigating.

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: Hayato on June 02, 2020, 12:01:13 AM
Hi Jean,

Could you add Value or InputAxisValue controls with FreeLookCameraSetXaxisSettings and FreeLookCameraSetYaxisSettings ?
It's useful  with some situation for example move camera angle depend on phone orientation.

Please take a look with it.
Thank you !
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: jeanfabre on June 02, 2020, 01:41:45 AM
Hi,

 these are accessible already via Free Look Camera Set Yaxis Settings and Free Look Camera Set Xaxis Settings.

however, I think you need to set it up properly, that is you need to prevent the regular input to affect these values, so you need the CinemachineCoreGetInputTouchAxis component on the main camera to disable inputs.

Make sure you properly set up the freelook, else the x axis may be locked.

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: Hayato on June 02, 2020, 03:04:46 AM
Hi,

 these are accessible already via Free Look Camera Set Yaxis Settings and Free Look Camera Set Xaxis Settings.

however, I think you need to set it up properly, that is you need to prevent the regular input to affect these values, so you need the CinemachineCoreGetInputTouchAxis component on the main camera to disable inputs.

Make sure you properly set up the freelook, else the x axis may be locked.

Bye,

 Jean

Opps ! I found I just failed to update latest version of Cinemachine (MAY 2020) package and using a old one , after I upgrade ecosystem 0.6.6 to 0.6.8 it success to upgrade Chinemachine package , then I have see the latest version of FreeLookCameraSetXaixsSettings do have Value and InputValue paramaters.
 
I'm sorry for my thoughtless and thank you for the hint !
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: jeanfabre on June 03, 2020, 02:07:07 AM
Hi,

 no worries, it happens to me always... too many versions of too many things for too many projects with too little time :)

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: BlizStudio on September 15, 2020, 03:31:30 PM
Anyone have a tutorial on how to use the Cinemachine package and Playmaker?  Bullet hits, explosions, etc...  Just not sure how to use the actions.
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: maxrostov on December 17, 2020, 01:27:54 PM
Anyone have a tutorial on how to use the Cinemachine package and Playmaker?  Bullet hits, explosions, etc...  Just not sure how to use the actions.

Bump on this!

I'm trying to figure out how to mouse drag to rotate camera with "Cinemachine free look camera".

In FSM i found "Free Look Camera Get Xaxis Settings", but I don't how how to use it.
There are no instructions for that action.

Has anyone here used it?

Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: curb47 on January 28, 2021, 02:58:04 PM
Hiya,

I'm working on a small paid job, a cinematic sequence, rendering out camera shots in Unity and editing them together in Premiere.

An action I would really love to get is some kind of event trigger for the Path Position parameter in the Body section on the virtual camera. I'm imagining something similar to a Float Range type thing.

I'd like to be able to send an event, to trigger background animations for example, at very specific moments as the camera moves along the track/path.

I've had a look in the actions/ecosystem but I can't find anything. Please, would there be a chance of getting this created? It would literally be amazing! Huge thanks.

(https://i.postimg.cc/LXWwfC8Z/cine-Machine.jpg)
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: jeanfabre on February 12, 2021, 03:01:15 AM
Hi,

 I don't see in the cinemachine component a way to get triggers like that.

 is that simply something you could do by placing simple triggers along the path? that's how I would go about it.

Let me know, maybe I am missing something.

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: craigz on February 12, 2021, 08:44:35 AM
Hiya curb47 :)

Cinemachine values can be tricky to get sometimes 😅

I was able to find this tracked dolly path helper script that I edited to just take an input value. Though the value for it doesnt seem to line up with the path length on the dolly 🤷‍♂️

(https://i.imgur.com/5WwBfma.gif)

Original Link (but the script animated by default)
https://www.tutorialfor.com/questions-126815.htm



Otherwise, depending on how specific you need the function of this type of interaction (with particular parts of the environment etc), might be totally easier to do as Jean suggests with manual placed triggers 💪

cheers,
craigz
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: curb47 on March 23, 2021, 08:32:40 AM
Thanks CraigZ & JeanFabre,

I'll look into this.

Jean- how do you mean, place triggers along the path? How can i place triggers along the Cinemachine Dolly path? I really don't see how that can be done?

Thanks.

Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: jeanfabre on May 10, 2021, 03:30:51 AM
Hi,

 sorry for the long wait.

 you just place regular colliders, that's what I mean by triggers.

Bye,

 Jean
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: Christoph on June 05, 2021, 05:19:14 PM
Are there actions for the Noise part of Cinemachine?

I would like to do camera shakes like explained here:
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: hoyoyo80 on June 14, 2021, 09:12:01 AM
Hi all, im am using unity2020.11f LTS with cinemachine. The package i get from ecosystem causing error missing a using directive or an assembly reference most of them. Any body have the same problem and solution? Thanks
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: djaydino on June 14, 2021, 04:38:03 PM
Hi hoyoyo80

have you installed the cinemachine asset before importing the actions?
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: hoyoyo80 on June 14, 2021, 07:27:49 PM
Yes. i install cinemachine from package manager first then i get the cinemachine action package from the ecosystem 0.6.11. TQ
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: samsss on October 12, 2021, 07:45:15 AM
Is there any actions to set noise property of virtual cameras?
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: samsss on November 22, 2021, 03:48:49 AM
Why no reply? I still need it.
Or it cannot be done? If so, I will use alternative way by myself.
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: Twood on January 02, 2022, 04:12:56 PM
Why no reply? I still need it.
Or it cannot be done? If so, I will use alternative way by myself.

@samsss Your request was a while ago, but I recently made that C# script for myself to change Cinemachine noise levels while using PM.

To use it first make sure you have enabled Basic Perlin Channel Noise on the Noise setting of this Cinemachine camera, then put this script on it.

Assign the camera object where it asks, and it has open settings for 3 different noise levels.

To start a noise level in-game, you use the Call Method action in Playmaker and the CinemachineNoiseAdjust script you just placed as target, and you will see the different noise profiles as method names in a dropdown.

You could also change the values directly with Set Property on the script, but make sure you Call Method any time you want to update the value. In that case you'd probably just one only one set of the variables and one method and can ignore the others.
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: craigz on January 18, 2022, 03:11:56 PM
Thanks for this Twood! :D
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: Twood on January 25, 2022, 01:21:52 AM
No prob. It's probably much better to build it as a playmaker action instead of doing it this way. I will likely be doing that at some point.
Title: Re: Cinemachine Support [ECOSYSTEM] [MAY 2020]
Post by: Twood on January 25, 2022, 05:30:47 PM
Update. I turned cinemachine noise adjustment into a Playmaker action.

Coding is NOT my main thing so let me know if I'm doing anything weird, but it runs fine for me in Unity.

Code: [Select]
using UnityEngine;


namespace HutongGames.PlayMaker.Actions.ecosystem.cinemachine

{
    [ActionCategory("Cinemachine")]
    [Tooltip("Allows you to adjust noise on a Cinemachine camera that has perlin noise enabled.")]


    public class CinemachineNoiseAdjust : FsmStateAction
    {

       
        [CheckForComponent(typeof(Cinemachine.CinemachineVirtualCamera))]
        [RequiredField]
        public Cinemachine.CinemachineVirtualCamera vcam;
        private Cinemachine.CinemachineBasicMultiChannelPerlin noiseChannel;
       

        public FsmFloat Amplitude;

        public FsmFloat Frequency;

        public FsmBool everyFrame;

        private bool goEveryFrame;
        private float goAmplitude;
        private float goFrequency;

         
        public override void OnEnter()

        {
            goAmplitude = Amplitude.Value;
            goFrequency = Frequency.Value;
            goEveryFrame = everyFrame.Value;


            vcam.GetCinemachineComponent<Cinemachine.CinemachineBasicMultiChannelPerlin>().m_AmplitudeGain = goAmplitude;
            vcam.GetCinemachineComponent<Cinemachine.CinemachineBasicMultiChannelPerlin>().m_FrequencyGain = goFrequency;

            if (!goEveryFrame)
            Finish();

        }

        public override void OnUpdate()
        {
            base.OnUpdate();
            if (goEveryFrame == true)
            {
                goAmplitude = Amplitude.Value;
                goFrequency = Frequency.Value;
                goEveryFrame = everyFrame.Value;


                vcam.GetCinemachineComponent<Cinemachine.CinemachineBasicMultiChannelPerlin>().m_AmplitudeGain = goAmplitude;
                vcam.GetCinemachineComponent<Cinemachine.CinemachineBasicMultiChannelPerlin>().m_FrequencyGain = goFrequency;
            }

        }

        public override void Reset()
        {
            Amplitude = null;
            Frequency = null;
            vcam = null;
            noiseChannel = null;
            goFrequency = 0;
            goAmplitude = 0;
            everyFrame = false;
            goEveryFrame = false;

        }

    }
}