playMaker

Author Topic: BillBoard action  (Read 11841 times)

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
BillBoard action
« on: October 11, 2012, 03:34:17 AM »
Hi,

 Following an interesting thread,

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 or download it here

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
« Last Edit: October 05, 2014, 05:50:46 AM by jeanfabre »

Sjones

  • Full Member
  • ***
  • Posts: 203
Re: BillBoard action
« Reply #1 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

Andrew.Lukasik

  • Full Member
  • ***
  • Posts: 134
    • my twitter @andrewlukasik
Re: BillBoard action
« Reply #2 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).

Andrew.Lukasik

  • Full Member
  • ***
  • Posts: 134
    • my twitter @andrewlukasik
Re: BillBoard action
« Reply #3 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 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.
« Last Edit: October 11, 2012, 01:17:25 PM by Andrew_Raphael_Lukasik »

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: BillBoard action
« Reply #4 on: October 15, 2012, 05:42:23 AM »
Hi,

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

bye,

 Jean

Andrew.Lukasik

  • Full Member
  • ***
  • Posts: 134
    • my twitter @andrewlukasik
Re: BillBoard action
« Reply #5 on: October 28, 2012, 02:10:17 PM »
<bump>

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: BillBoard action
« Reply #6 on: October 29, 2012, 02:05:24 AM »
Hi,

 Done, thanks for reminding me :)

bye,

 Jean

Nitrohex

  • Junior Playmaker
  • **
  • Posts: 50
Re: BillBoard action
« Reply #7 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
Sign Up Now @ StartApp.com

Nitrohex

  • Junior Playmaker
  • **
  • Posts: 50
Re: BillBoard action
« Reply #8 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
Sign Up Now @ StartApp.com

Nitrohex

  • Junior Playmaker
  • **
  • Posts: 50
Re: BillBoard action
« Reply #9 on: October 03, 2014, 03:09:34 PM »
Bump
Sign Up Now @ StartApp.com

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: BillBoard action
« Reply #10 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


Nitrohex

  • Junior Playmaker
  • **
  • Posts: 50
Re: BillBoard action
« Reply #11 on: October 05, 2014, 09:43:29 AM »
Thanks a lot Jean, i will give it a try now  :)
Sign Up Now @ StartApp.com

clandestine

  • Sr. Member
  • ****
  • Posts: 255
    • ЯKD.ZONE
Re: BillBoard action
« Reply #12 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 and it works... can it be implemented/converted to an action?

Thanks in advance.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: BillBoard action
« Reply #13 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.



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


 Bye,

 Jean

clandestine

  • Sr. Member
  • ****
  • Posts: 255
    • ЯKD.ZONE
Re: BillBoard action
« Reply #14 on: June 03, 2015, 06:31:59 AM »
Yay, thanks Jean, will check it out asap!