Shader Semi-Transparent to self, but masks what's behind it

Basically brand new to shaders. Need to create a coloured, semi-transparent shader, that shows all sides of an object (no backface culling), however despite being transparent, objects will be opaque to any objects behind them, and mask objects further back. The object to be transparent to itself, but opaque to other objects in the scene (the OPPOSITE of what’s shown in the pic below, that is transparent globally, but opaque locally).

Shader “Custom/Self Transparent”
_Color (“Color”, Color) = (1,1,1,1)
_MainTex (“Albedo (RGB)”, 2D) = “white” {}
_Glossiness (“Smoothness”, Range(0,1)) = 0.5
_Metallic (“Metallic”, Range(0,1)) = 0.0


    // Use shader model 3.0 target, to get nicer looking lighting
    #pragma target 3.0

    sampler2D _MainTex;

    struct Input
        float2 uv_MainTex;

    half _Glossiness;
    half _Metallic;
    fixed4 _Color;

    // Add instancing support for this shader. You need to check 'Enable Instancing' on materials that use the shader.
    // See for more information about instancing.
    // #pragma instancing_options assumeuniformscaling
        // put more per-instance properties here

	void vert (inout appdata_full v)
		float3 op = mul (unity_WorldToObject, float4 (, 1)).xyz;
		float3 viewDir = - op; *= dot (viewDir, > 0.0 ? -1.0 : 1.0;

    void surf (Input IN, inout SurfaceOutputStandard o)
        // Albedo comes from a texture tinted by color
        fixed4 c = tex2D (_MainTex, IN.uv_MainTex) * _Color;
        o.Albedo = c.rgb;
        // Metallic and smoothness come from slider variables
        o.Metallic = _Metallic;
        o.Smoothness = _Glossiness;
        o.Alpha = c.a;


        Tags { "RenderType"="Opaque" }
        LOD 200

		ZWrite On
		Cull Front

		//Optional to stop Z-fighting
		//Offset -1,-10

        #pragma surface surf Standard vertex:vert noshadow 

		ZWrite Off
		Cull Back

		#pragma surface surf Standard alpha:fade noshadow
    FallBack "Diffuse"

The basic idea here is to split rendering into two sections; internal and external rendering. We render the inside first as opaque with depth-writing on to make sure nothing is drawn behind it. We also flip the normals so that they face the right direction. Then, we draw the front faces with depth-write off and alpha blending such that you can see the inside of the object like a normal semi-transparent shader. There is also a line commented out that can help fix z-fighting if your object’s internal faces are too close to those of another object.