Playmaker Forum

PlayMaker News => General Discussion => Topic started by: jeanfabre on September 11, 2018, 03:03:15 AM

Title: Smooth Portals Demo [SAMPLE] [ECOSYSTEM] [SEPTEMBER 2018]
Post by: jeanfabre on September 11, 2018, 03:03:15 AM
Hi Everyone,

Ok, so I just released a very nice demo on the Ecosystem, showing off some a very cool Portal feature to transport the player in a different part of the world.

(http://fabrejean.net/projects/PlayMaker/Gifs/SmoothPortals.gif)

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

This is an advanced demo, using only 4 fsm, but the math involved in moving the cameras, transporting player are complex, and requires very advanced understanding of quaternions/rotation and general transforms operation.  So if you are beginning with Unity, and PlayMaker, this might not be the best sample to study.

The original sample is available on github: https://github.com/KillianMcCabe/SmoothPortals

Thanks to the author for letting me work with this demo :)

There is one thing that differ from the original code. Because all PlayMaker Fsm are executed within PlayMaker Framework, we can't have one fsm forced to be executed before another one, unlike scripts ( with script execution order), and so I moved the logic from Update to LateUpdate, which is not the case in the original scripts, the results is exactly the same.

Possible improvement:

-- currently, it's for one player, because the logic to move is on the door, so you can't have two players or npcs going through the portal at the same time, it would result is potential bugs. To solve this, each character should hold the logic to trigger the portal, then the gate is just a trigger and a shows the other world, but is not responsible of deciding about who gets to go through the portal.


Let me know if you have questions :)

Bye,

 Jean

Title: Re: Smooth Portals Demo [ECOSYSTEM] [SEPTEMBER 2018]
Post by: PolyMad on September 11, 2018, 05:22:15 PM
Wow this is cool  :o
Title: Re: Smooth Portals Demo [ECOSYSTEM] [SEPTEMBER 2018]
Post by: djaydino on September 12, 2018, 02:12:28 AM
Hi.
Nice, i saw this one on Brackeys channel.
I was actually planning to make a tutorial for it, but you beat me to it :P
Title: Re: Smooth Portals Demo [ECOSYSTEM] [SEPTEMBER 2018]
Post by: jeanfabre on September 12, 2018, 12:57:28 PM
Hi,

 I think it would be great you still do it, just take what I did, then you can concentrate on making the tut itself.

 Bye,

 Jean
Title: Re: Smooth Portals Demo [ECOSYSTEM] [SEPTEMBER 2018]
Post by: djaydino on September 17, 2018, 01:14:05 AM
Hi.
I haven't looked yet to your sample, but i think i will try to build myself 1st and then compare it with yours.
Just to see if there will be differences in setting this up. (for educative reasons :) )

After that i will make a video tutorial for it :)
Title: Re: Smooth Portals Demo [ECOSYSTEM] [SEPTEMBER 2018]
Post by: jeanfabre on September 17, 2018, 07:55:35 AM
Hi,

 yep, very good idea.

 Bye,

 Jean
Title: Re: Smooth Portals Demo [SAMPLE] [ECOSYSTEM] [SEPTEMBER 2018]
Post by: Handrews on October 10, 2018, 06:28:29 PM
I see the portals in black.
Title: Re: Smooth Portals Demo [SAMPLE] [ECOSYSTEM] [SEPTEMBER 2018]
Post by: jeanfabre on October 11, 2018, 03:59:41 AM
Hi,

what version of Unity are you in, is it a fresh project?

 Bye,

 Jean
Title: Re: Smooth Portals Demo [SAMPLE] [ECOSYSTEM] [SEPTEMBER 2018]
Post by: Handrews on October 12, 2018, 07:12:16 AM
Unity 2017.4.1f1 (64-bit)
Title: Re: Smooth Portals Demo [SAMPLE] [ECOSYSTEM] [SEPTEMBER 2018]
Post by: jeanfabre on October 16, 2018, 03:55:03 AM
Hi,

 uhm, I can't repro, all works well, fresh project, installed playmaker, ecosystem, downloaded sample and all is ok:

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

Can you try again on a fresh project, and if that doesn't work, can you zip that project and send it over?

 Bye,

 Jean
Title: Re: Smooth Portals Demo [SAMPLE] [ECOSYSTEM] [SEPTEMBER 2018]
Post by: S0ULART on April 03, 2022, 11:13:12 AM
this example and the one in the ecobrowser do not work on 2019+ upwards. The room the portal is going to doesn't activate but you can see it through the portal