Procedural Generation in Unity

แชร์
ฝัง
  • เผยแพร่เมื่อ 30 พ.ย. 2024

ความคิดเห็น • 44

  • @iHeartGameDev
    @iHeartGameDev ปีที่แล้ว +29

    What a wonderful introduction to the subject! Loved the video 😍 Thank you both for putting it together!

    • @TNTCProject
      @TNTCProject  ปีที่แล้ว +1

      Thank you so much, Nicky, appreciate it!

  • @n00bslayherttv92
    @n00bslayherttv92 ปีที่แล้ว +2

    Thank you. the style in which you explain and then pause so we can look and understand is really appreciated thank you subscribed!

  • @LifeCodeGame
    @LifeCodeGame ปีที่แล้ว +2

    Wow, this looks like a great way to create some really cool and unique experiences! Can't wait to see what I can come up with!

    • @TNTCProject
      @TNTCProject  ปีที่แล้ว +1

      Yay, share your results!

  • @ha7anali313
    @ha7anali313 ปีที่แล้ว

    Way Way Better Than TH-camrs Bro Thanks

  • @dreamisover9813
    @dreamisover9813 ปีที่แล้ว +1

    Intersting topic and video! I've done some procedural mesh generation in Unity before, but only really light stuff. There are many amazing projects and assets though out there which always impress me

    • @TNTCProject
      @TNTCProject  ปีที่แล้ว

      Thank you :) What kind of stuff did you do?

    • @dreamisover9813
      @dreamisover9813 ปีที่แล้ว

      @@TNTCProject For example generating a slightly curved track for an endless runner type of game, so it curves a bit in random directions to make it feel a bit more varied. There weren't many rules, each track segment was just a rectangle made out of 2 triangles to have a certain width and length, it followed a path that would often change its angle slightly in a random direction.

  • @1JMGames
    @1JMGames ปีที่แล้ว +2

    Amazing video bro! Keep it up! You should make a step by step tutorial on how to do this!

    • @TNTCProject
      @TNTCProject  ปีที่แล้ว +1

      Thank you!
      Maybe, but I don't want to be tedious

    • @1JMGames
      @1JMGames ปีที่แล้ว +1

      @@TNTCProject i for one would love it! Good luck on your next video!

    • @ObsessiveGames
      @ObsessiveGames ปีที่แล้ว

      @TNTC I personally really want to create the procedural generation like you did with the walls streching the way you did it. I am going to go through your videos in hopes of achieving this. I will jump in your discord and if there is any more pinpoint videos you can point me to, then I would love that!
      Thank you for this video, was so great watching it through.
      Also maybe even if you just have the git repo for how this was achieved as a sample would really be helpfull 😁
      Edit: I just tried joining your discord link on your banner, it says the link has expired. Could you update it please :)

  • @ПавлоК-з9н
    @ПавлоК-з9н 8 หลายเดือนก่อน +2

    Great video, however what I entirely don't understand at all is why not to publish a code somewhere in github?

  • @brendancopot1025
    @brendancopot1025 ปีที่แล้ว +1

    This video really helped me improve the project I'm currently working on, it was very educational and inspired me to research more into instanced meshes. I was wondering how you would handle adding colliders to your walls and other meshes instanced in the scene as I am struggling to find any resources online about this.

    • @jingkai6730
      @jingkai6730 ปีที่แล้ว

      it could be already part of the prefab in the possible Objects list

    • @jprice3486
      @jprice3486 8 หลายเดือนก่อน

      I'm wondering the same thing also, I am looking into adding compound colliders on top of the meshes using the same m4x4 data, but this method seems like it would be taxing on performance.

  • @marcusmartinez423k
    @marcusmartinez423k 5 หลายเดือนก่อน +5

    using System.Collections.Generic;
    using UnityEngine;
    #if UNITY_EDITOR
    using UnityEditor;
    #endif
    public class RoomGridGenerator : MonoBehaviour
    {
    public int gridRows = 10; // Number of rows in the grid
    public int gridColumns = 10; // Number of columns in the grid
    public float gridHeight = 0.1f; // Height at which the grid is drawn
    private FloorPlanGenerator floorPlanGenerator;
    public List gridPositions; // List to store grid cell positions
    void Awake()
    {
    floorPlanGenerator = GetComponent();
    gridPositions = new List();
    }
    void OnDrawGizmos()
    {
    if (floorPlanGenerator == null || gridRows

  • @elenagalloni9146
    @elenagalloni9146 ปีที่แล้ว

    Wow I really loved those dungeons! I'll try on my own, adding some procedural dragons 😏
    Also, the horned monster is super cute ❤

  • @amolnk
    @amolnk ปีที่แล้ว +1

    Can we use houdini to create such systems? I had created procedural systems using geometry but, for now at least, unity does not let me import the node system from blender. Does houdini work?

    • @gameDev-is9ly
      @gameDev-is9ly 4 หลายเดือนก่อน

      For both of them there's some plugins that help you import this asset's

    • @amolnk
      @amolnk 4 หลายเดือนก่อน

      @@gameDev-is9ly do you know what plugin it is for blender?

    • @gameDev-is9ly
      @gameDev-is9ly 4 หลายเดือนก่อน

      @@amolnk Houdini have their own plugin for unity if you search in TH-cam you'll find it , and for blender geometry nodes the plugin is called " B engine " the Channel of inspiration tutors made a video about it

  • @WelshGuitarDude
    @WelshGuitarDude ปีที่แล้ว

    I'm struggling with uvs when it's a curve.. How the heck do you make correct uvs for curved meshes especially if the curve is longer or shorter than default uv length such as a fractional part to the length of the mesh

  • @bigjermini
    @bigjermini ปีที่แล้ว

    Do you have the full code to share? I'd like to learn more on this and be able to use it.
    Some things I don't understand is:
    How are you calling "create walls and render mesh"? Not in update as it would constantly keep trying to build it.
    as well as some of the variables

  • @ChokeHammer
    @ChokeHammer ปีที่แล้ว

    This is a brilliant tutorial; really helped motivate me! Thank you! ^.^
    One question though, how does one get this to work in URP? It appears drawmeshinstanced does not work with custom shaders in URP, and instead just doesnt render any of the meshes. Any advice? 😅

  • @SketchpunkLabs
    @SketchpunkLabs ปีที่แล้ว

    What math did you use to warp a mesh on a curve for the roller things? it had a ui with a "curvature' value. Curios how you curved the red rails with the silver rollers

    • @TNTCProject
      @TNTCProject  ปีที่แล้ว

      Well, the rollers (cone sections) are instantiated meshes, just like the wall of the room. Each red rail, however, is a single generated mesh. For each roller, we created a point and generated a basic mesh around it. We used the same technique in our procedural ivy video.

  • @therealpeter2267
    @therealpeter2267 ปีที่แล้ว +1

    Awesome vid bro, but... who uses camelCase in c# for functions? 😭

    • @TNTCProject
      @TNTCProject  ปีที่แล้ว

      Thank you!
      Hahaha, everyone should, don't let me even start to talk about code convention :P
      ~ Erik

  • @אורימימון-ע3ה
    @אורימימון-ע3ה ปีที่แล้ว

    Amazing! can you explain more about the monster part? and how i can create it

  • @aaaalord
    @aaaalord ปีที่แล้ว

    How can we bake it at runtime ?

  • @simonstabbryndum8854
    @simonstabbryndum8854 6 วันที่ผ่านมา

    I don't understand how to it can anyone help me :(

  • @Raccoon0710
    @Raccoon0710 ปีที่แล้ว +1

    Can you please share the code?

    • @Raccoon0710
      @Raccoon0710 ปีที่แล้ว

      Actually I have developed wall generation and circular wall generation in those 3 hours :) but I don't understand so far: how did you bend meshes for circular house. Did you subdivide that mesh in blender and bend it in code?

    • @KoopaTheQuick3
      @KoopaTheQuick3 ปีที่แล้ว

      @@Raccoon0710 what data structure is used for things like room and wall size?

    • @KoopaTheQuick3
      @KoopaTheQuick3 ปีที่แล้ว

      Nevermind. I figured that part out. Now I just need to figure out how to reflect the results properly to get 4 walls instead of 2

    • @KoopaTheQuick3
      @KoopaTheQuick3 ปีที่แล้ว

      @@Raccoon0710 I'm completely stuck on the createFloor function. Any help would be greatly appreciated

    • @tvrtkokaurinovic7370
      @tvrtkokaurinovic7370 ปีที่แล้ว +1

      Can you share your code if you succeeded

  • @mathiskunzel8616
    @mathiskunzel8616 ปีที่แล้ว +7

    Please give us the source code :)

  • @zes7215
    @zes7215 ปีที่แล้ว +1

    wrg