r/Unity3D – Telegram
r/Unity3D
265 subscribers
12.7K photos
15.6K videos
14 files
48K links
News about the Unity engine and project showcases from Reddit. Made possible with @reddit2telegram (@r_channels).
Download Telegram
I feel like it’s impossible to find working shader tutorials

I feel like it’s impossible to find working shader tutorials nowadays. I’m working on a 3d game and need a simple outline shader, but none of the tutorials work with Unity 6, or URP.

I’ve tried this: https://roystan.net/articles/outline-shader/
And this: https://youtu.be/9fa4uFm1eCE?si=tfPAYdXgMcjUvmPV
But the first only works with HDRP and the second uses deprecated non working noscripts.
(I’ve also tried inverted hull technique but it doesn’t work consistently for all objects)


I'm a bit of a noob, so I've been following some shadergraph tutorials, but I want to learn how to use shaderlab noscripts, but none of what I found works with Unity 6 or with URP.

Does anyone have any tips on how to integrate HLSL shaders/where to learn shader noscripting
(Also if any outline shaders working with Unity 6 I would appreciate it)

I would ideally want to use an edge detection implementation that works through the depth buffer. (I could maybe figure this out but have no idea how to integrate HLSL shaders or write shaders)


TLDR: basically no tutorials work with Unity 6 URP shader noscripting help

https://redd.it/1h3nxf4
@r_Unity3D
Media is too big
VIEW IN TELEGRAM
My first attempt at a dynamic first-person and third-person camera for my puzzle game. How can I improve?

https://redd.it/1h3r5gf
@r_Unity3D
This media is not supported in your browser
VIEW IN TELEGRAM
Elephant Boss: Guardian of the desert. He's too heavy to dodge your attacks, but his immense strength makes him tough to beat!
https://redd.it/1h3xcut
@r_Unity3D
How to convert this class so i can use it with ecs

public class NodesMono : MonoBehaviour
{
public NodesMono NextNode,PreviousNode,IntersectionNode;
}

i want to bake this into an entity so i can make an array out of it and use in a system.
If anyone would be so kind to give me a rough idea on how to do it.
(i know about the baking part i just dont know how to make it as a component on an entity.)
🤧🤧🤧 tanks.

some more dumbahh code for context

using Unity.Entities;
using UnityEngine;

public class PedestrianManager : MonoBehaviour
{
public NodesMono nodesArray; // Array to store NodesMono objects

private void Start()
{
nodesArray = GameObject.FindObjectsByType<NodesMono>(FindObjectsSortMode.None);


Debug.Log("Found " + nodesArray.Length + " NodesMono objects.");
}
}

// This class is where the conversion from MonoBehaviour to Entity happens
class WaypointsBaker : Baker<PedestrianManager>
{
public override void Bake(PedestrianManager authoring)
{
// Iterate over each NodesMono object
foreach (var node in authoring.nodesArray)
{
// Create an Entity for each Node
Entity nodeEntity = GetEntity(TransformUsageFlags.Renderable);


var nodeComponent = new Node
{
NextNode = node.NextNode, // idk wut to put here
IntersectionNode = Entity.Null,
PreviousNode = Entity.Null
};


AddComponent(nodeEntity, nodeComponent);
}
}
}

// Data structure representing the node
public struct Node : IComponentData
{
public Entity NextNode;
public Entity IntersectionNode;
public Entity PreviousNode;
}

https://redd.it/1h3wcjj
@r_Unity3D
Switching from GameMaker to Unity.
https://redd.it/1h3yvla
@r_Unity3D
My starlit sky scene in Unity 6. Never seen a sky like this in real life since I moved to the city, so bad.
https://redd.it/1h3y2mt
@r_Unity3D