Playmaker Forum

PlayMaker Updates & Downloads => Share New Actions => Topic started by: jeanfabre on October 11, 2012, 03:34:17 AM

Title: BillBoard action
Post by: jeanfabre on October 11, 2012, 03:34:17 AM
Hi,

 Following an interesting thread,

http://hutonggames.com/playmakerforum/index.php?topic=2405.0 (http://hutonggames.com/playmakerforum/index.php?topic=2405.0)

 I decided to make a convenient billboard action so that you can have gameObjects in your world always facing the camera, it's very useful for trees, or UI elements, etc etc.

You can download it directly on your project with the Ecosystem Browser (https://hutonggames.fogbugz.com/default.asp?W1181) or download it here (https://github.com/jeanfabre/PlayMakerCustomActions_U3/blob/1fd61b476743489bc9ef516c11cac249e57c8f13/Assets/PlayMaker%20Custom%20Actions/GameObject/BillBoard.cs)

There is an option to keep constant screensize. this works best with flat mesh for UI.

[EDIT] Added the option to define the distance at which the object should be scaled to 1.

bye,

 Jean
Title: Re: BillBoard action
Post by: Sjones on October 11, 2012, 04:20:11 AM
awesome! was thinking of implementing something like this but was going to test performance as I was considering doing a lot of these, this will most certainly speed up that process when I come to it
Title: Re: BillBoard action
Post by: Andrew.Lukasik on October 11, 2012, 12:22:11 PM
Thanks Jean! I hope it will be added to release someday (and many other of your actions too).
Title: Re: BillBoard action
Post by: Andrew.Lukasik on October 11, 2012, 01:13:45 PM
PS:
I think it would be great to add to this action a constant size, but not based on initial scale and distance but rather somehow with constant and shared size on screen.

 I'm sure there is better way to make this but in my example (http://hutonggames.com/playmakerforum/index.php?topic=2405.msg10732#msg10732) I achieved this by doing something like this:
   distance to camera  / distance on which object is scaled to 1.0 = scale factor
 I don't know if <distance on which object is scaled to 1.0> is clear enough for users. Scale in relation to screen size would better but I'm not sure how to approach this since it's 3d object.
Title: Re: BillBoard action
Post by: jeanfabre on October 15, 2012, 05:42:23 AM
Hi,

 Can you bump this next week? I'll see what I can do.

bye,

 Jean
Title: Re: BillBoard action
Post by: Andrew.Lukasik on October 28, 2012, 02:10:17 PM
<bump>
Title: Re: BillBoard action
Post by: jeanfabre on October 29, 2012, 02:05:24 AM
Hi,

 Done, thanks for reminding me :)

bye,

 Jean
Title: Re: BillBoard action
Post by: Nitrohex on September 23, 2014, 12:35:04 PM
Hi,

When i try to add Bill Board action in a state i get:

NullReferenceException: Object reference not set to an instance of an object
HutongGames.PlayMaker.Actions.BillBoard.Reset () (at
Assets/PlayMaker/Actions/BillBoard.cs:24)


Any ideas on why i get this error?

Thanks
Title: Re: BillBoard action
Post by: Nitrohex on September 24, 2014, 08:37:54 AM
Bump

Also i get the same error when the action is imported via the ecosystem or manually.

Can anyone help me with this issue?

Thanks
Title: Re: BillBoard action
Post by: Nitrohex on October 03, 2014, 03:09:34 PM
Bump
Title: Re: BillBoard action
Post by: jeanfabre on October 05, 2014, 05:48:00 AM
Hi,

It's because you don't have a Camera tagged "MainCamera". You should always have one tho.

 I have updated the action on the Ecosystem, redownload it and it will now work.

Bye,

 Jean

Title: Re: BillBoard action
Post by: Nitrohex on October 05, 2014, 09:43:29 AM
Thanks a lot Jean, i will give it a try now  :)
Title: Re: BillBoard action
Post by: clandestine on June 03, 2015, 04:42:54 AM
Hey guys i see this is old, but... Jean is it possible to modify the action to lock one axis and for example rotate the billboard only on X and Z around an Y pole stuck in the ground?

I found this script (http://wiki.unity3d.com/index.php/LookAtCameraYonly) and it works... can it be implemented/converted to an action?

Thanks in advance.
Title: Re: BillBoard action
Post by: jeanfabre on June 03, 2015, 05:09:34 AM
Hi,

 I think it's covered already with the "look at 2d" types of actions you'll find on the Ecosystem (https://hutonggames.fogbugz.com/default.asp?W1181).

(http://snag.gy/5qoKB.jpg)

let me know if you can't find anything suitable.


 Bye,

 Jean
Title: Re: BillBoard action
Post by: clandestine on June 03, 2015, 06:31:59 AM
Yay, thanks Jean, will check it out asap!
Title: Re: BillBoard action
Post by: clandestine on June 04, 2015, 06:05:48 AM
Those work, the easiest to use (for billboard people in archviz scene) is Look At with the Keep Vertical option.

Thanks Jean
Title: Re: BillBoard action
Post by: jeanfabre on June 04, 2015, 07:30:11 AM
Hi,

 Very good

Bye,

 Jean
Title: Re: BillBoard action
Post by: clandestine on June 05, 2015, 05:56:36 AM
Ok, here is the player of the thing i used the script for, a quick (1 week) project.

click here (http://sas.rkd.zone/player/) for player

Thanks again!