Billboarding Tutorial - Unity

Поділитися
Вставка
  • Опубліковано 21 сер 2024
  • Billboarding is a great technique that allows 2D objects to always face the camera creating the illusion of 3D as seen in retro FPS such as DOOM, Duke Nukem 3D, Blood, and more!
    ==================
    Download links
    ==================
    Project: drive.google.c...
    Enjoy!
  • Ігри

КОМЕНТАРІ • 78

  • @373Seven___
    @373Seven___ 2 місяці тому +3

    The real heroes are the ones who make these tutorials, thank you dude!

    • @expatstudios
      @expatstudios  Місяць тому

      You're welcome. Believe me when I say, you guys are the heroes for taking the time to check us out.
      Thank you!

  • @No.0.o.0
    @No.0.o.0 15 днів тому

    Perfect tutorial, no bullshit, no whacky zoomer edits, no long intro, no drawn out segment begging for subscribers.
    That's how to get me to watch all of someone's videos.

    • @expatstudios
      @expatstudios  15 днів тому

      Wow! Thank you very much for the high praise. We're glad our tutorial served you well. All the best to yourself and your projects. 🤝

  • @eGregiousGames
    @eGregiousGames 2 роки тому +6

    GREAT tutorial! I love the clear way you explain things. I'm actually using this for a top-down game that uses a perspective camera for buildings/terrain but billboards the sprites for a 2.5D Octopath Traveler-like style. This was far simpler than some other implementations.

    • @expatstudios
      @expatstudios  2 роки тому

      That's awesome to hear! Sounds like a great project. Happy the tutorial served you well. Thank you! 👍

  • @brensteff
    @brensteff Рік тому +1

    Best tutorial I've seen on this. Short and simple

    • @expatstudios
      @expatstudios  Рік тому

      Thank you kindly! Glad it was useful. All the best on your projects. 🙌

  • @techisaut8900
    @techisaut8900 2 роки тому +3

    you are a hidden gem! your content is well written and spoken! good job :D

    • @expatstudios
      @expatstudios  2 роки тому +1

      Thank you very much. Glad you are enjoying the tutorials and that they are proving helpful.
      All the best.

  • @Hayley_.z
    @Hayley_.z 6 місяців тому

    Thank u!!!!! This is exactly what I needed and you explained it perfectly :DD

    • @expatstudios
      @expatstudios  6 місяців тому

      Happy days! Thank you very much! All the best and have fun!

  • @Phniblet
    @Phniblet 7 місяців тому

    Exactly what I needed!

    • @expatstudios
      @expatstudios  7 місяців тому

      Happy days! We're glad it helped. Thanks for checking out our tutorials. All the best on your projects!

  • @robinantonjuj
    @robinantonjuj Рік тому

    I've used your work in my university assignment haha. I mention your video in my sources pdf :D

    • @expatstudios
      @expatstudios  Рік тому +2

      That's amazing! Thank you very much!
      When we studied game dev in university back in the late 2000s, there was a lack of tutorials and learning resources available at the time. It was a difficult process. We decided to make these tutorials to give others a better start than we did learning game dev, making it more accessible and easier than ever.
      Once again, thank you. It means a lot to us. All the best!

  • @vietnammc2896
    @vietnammc2896 2 роки тому

    Ur tutorial is really cool, hope you will become popular

    • @expatstudios
      @expatstudios  2 роки тому

      Thank you. We're glad you enjoyed it. Hope you're looking forward to more tutorials coming soon.
      All the best.

  • @hilbertsla1986
    @hilbertsla1986 Рік тому +1

    ty you helped me a lot

    • @expatstudios
      @expatstudios  Рік тому +1

      You're welcome. Happy to help. All the best on your project! 👍

  • @horriblegoosemana3382
    @horriblegoosemana3382 Рік тому +1

    Love the tutorial, great in explaining thing and really straight forward! Great job!!
    BUT
    I get the error. Quarternion does not contain a definition for lookRotation? Am I doing something wrong

    • @expatstudios
      @expatstudios  Рік тому +1

      Thank you very much!
      No worries, please double check capitalization of 'LookRotation'.
      All the best!

  • @henriquestealth9480
    @henriquestealth9480 Рік тому

    Amazing

    • @expatstudios
      @expatstudios  Рік тому +1

      You're amazing!
      Thanks for stopping by.

  • @kinda_history_nerd
    @kinda_history_nerd Рік тому

    Great tutorial! Just the one I needed! Keep it up, you'll get there soon.😊😊😊❤❤❤
    Quick question: Is the RedImp object you used a png?🤔🤔

    • @expatstudios
      @expatstudios  Рік тому

      Thank you very much. More tutorials are on the way! Yes, the Red Imp is a PNG and the hand.
      All the best and have fun!

  • @keeganmiller1328
    @keeganmiller1328 6 місяців тому +1

    Great Video! I do have a question though. My character spins in a circle due to the transform.rotation line of code. Any ideas?

    • @expatstudios
      @expatstudios  6 місяців тому

      Thank you for watching. Just to confirm, by character are you referring to your player character?

    • @keeganmiller1328
      @keeganmiller1328 6 місяців тому

      @@expatstudios yes sir, im playing around with network managers and when I spawn in my host character during runtime he will continously spin in a circle

    • @expatstudios
      @expatstudios  6 місяців тому

      Interesting. Does this happen when you don't spawn the character?

  • @christiangab1227
    @christiangab1227 2 роки тому +1

    Great tutorial and amazing content, thank you also just curious how can you make the sprite change its image based on camera's position basically the sprite is still looking at you but it changes image as you move around creating an illusion that looks as if the sprite is 3d

    • @expatstudios
      @expatstudios  2 роки тому +2

      Thank you very much. Glad they have been of help. Great question! I've actually been looking at how to achieve this. Once I've settled on a good method a tutorial will follow. All the best!

    • @christiangab1227
      @christiangab1227 2 роки тому

      Thank you so much ^^

  • @DW_69
    @DW_69 Рік тому

    Cheers!

    • @expatstudios
      @expatstudios  Рік тому

      You're welcome. Thanks for stopping by. 🙌

  • @gow9476
    @gow9476 2 роки тому

    THX SO MUCH

    • @expatstudios
      @expatstudios  2 роки тому

      You're welcome. Thank you for stopping by. 🙌

  • @emmanuelhenne
    @emmanuelhenne Рік тому +1

    Now, step 2: if i have all the rotated sprites ready, how do i tell the shader when to use what direction of the sprite based on the angle the camera looks at the billboard.

    • @expatstudios
      @expatstudios  Рік тому +1

      Thank you for stopping by. It's on the list for sure.

  • @janlos202
    @janlos202 Рік тому

    THANK U!!!

    • @expatstudios
      @expatstudios  Рік тому +1

      Thank you for being awesome! 👍

    • @janlos202
      @janlos202 Рік тому

      @@expatstudios haha! nono im just random noob! :DDD but when i finish my little project i will show you!! i need a lot of billboards hahah XDD THX!

    • @expatstudios
      @expatstudios  Рік тому

      Great! Looking forward to seeing it.

  • @dunderguy
    @dunderguy 2 роки тому +1

    This works but when I start the game I get a million errors that say object reference not set to an instance of an object. I checked the script and my project and everything was fine.

    • @expatstudios
      @expatstudios  2 роки тому

      Not to worry. To pin point which reference isn't set, please click on the error message and it shall take you to it. Is it referring to the camera?

    • @dunderguy
      @dunderguy 2 роки тому

      @@expatstudios I'm kind of new to Unity but I think I looked at the right place. It says the error is being caused on line 18 so I looked there and saw this line of code. (and yes, my camera's tag is marked as maincamera)
      cameraDir = Camera.main.transform.forward;

    • @expatstudios
      @expatstudios  2 роки тому

      @@dunderguy Just to confirm, is the tag the default of MainCamera? Thank you.

    • @dunderguy
      @dunderguy 2 роки тому

      @@expatstudios Yes

    • @expatstudios
      @expatstudios  2 роки тому +1

      @@dunderguy Hi. Just checking in to see how you're getting on. Have you found a solution to issue you were having? I've been super busy lately with moving to, and working in a new country. 👋

  • @JcBoi
    @JcBoi Рік тому +1

    How do I make it so that the object is facing away from me with a Boolean called "reverse", if you could reply with a script replacement. that would be awesome.

    • @expatstudios
      @expatstudios  Рік тому

      Thank you for your question. Would this be a static object or an enemy?

    • @JcBoi
      @JcBoi Рік тому

      @@expatstudios Static Object.

    • @expatstudios
      @expatstudios  Рік тому

      Just to confirm, is it the object's sprite you want to be facing away?

    • @JcBoi
      @JcBoi Рік тому

      @@expatstudios Yes.

    • @expatstudios
      @expatstudios  Рік тому

      I think I've a solution for you. What triggers the bool. Player distance from the object?

  • @j_ordinary4252
    @j_ordinary4252 Рік тому

    Isn't making a sprite an awful process? I tried finding a tutorial for making sprites and I have no idea what they all do. They use adders and dividers and stuff... I might as well learn how to use Godot

    • @expatstudios
      @expatstudios  Рік тому

      Not at all. It's as simple as drawing them in whichever program you wish then importing them into Unity. I use Clip Studio and GIMP for drawing sprites. 👍

  • @AidinZolghadr
    @AidinZolghadr 2 роки тому +1

    Please accept my request to get the files, thanks for the tutorial!

    • @expatstudios
      @expatstudios  2 роки тому +1

      No problem. All done. Thank you. 👍

    • @AidinZolghadr
      @AidinZolghadr 2 роки тому +1

      @@expatstudios Thanks!

    • @expatstudios
      @expatstudios  2 роки тому

      @@AidinZolghadr You're welcome. Best of luck on your project.

  • @fosforitoreviu732
    @fosforitoreviu732 2 роки тому

    hello! great video! but... i have a problem, when i press play in unity, the console says:" object reference not set to an instance of an object". i dont understand, how do i fix it?

    • @expatstudios
      @expatstudios  2 роки тому

      Thank you. Not to worry, it could be an issue with your Camera reference. Please run through and double check your code along with the tutorial. To go to the source of the issue, click on the error message and it will take you to it.
      All the best.

    • @Mr.Epsilion
      @Mr.Epsilion 2 роки тому +1

      Check if you have camera tag "Main Camera"

  • @AidinZolghadr
    @AidinZolghadr 2 роки тому

    One thing though, it throws "Look rotation viewing vector is zero" all over the console. Any fix?

    • @expatstudios
      @expatstudios  2 роки тому

      Interesting. We ran through the tutorial again and did not encounter this. Please, in what way have you applied billboarding? Thank you.

    • @AidinZolghadr
      @AidinZolghadr 2 роки тому

      @@expatstudios I followed the tutorial exactly. I ended up adding a small value to camDir.y like 0.00001 to suppress that warning log.