URP Upgrading

This section describes how to upgrade an SCK project to URP.

Install the URP Package

Open the Package Manager and install the Universal RP package into your project.

Create A URP Asset

After installing URP, it's necessary to create a Pipeline Asset for your project.

  1. Right click in Project tab and select Create > Rendering > Universal Render Pipeline > Pipeline Asset (Forward Renderer)

  2. Click Edit > Project Settings > Graphics and set the Scriptable Render Pipeline Settings field to the pipeline asset you just created.

Upgrade Materials

After installing URP and creating the pipeline asset, the materials in your scenes will be pink, because they haven't yet been converted to URP materials. Let's do this now.

Click Edit > Render Pipeline > Universal Render Pipeline > Upgrade Project Materials To UniversalRP Materials.

Import SRP Shaders

The kits come with URP compatible (shader graph) shaders for:

  • The energy shield

  • The target hologram

To set these up, simply import the SRP_Shaders_ClickMe unitypackage into the project. It will automatically update the shaders for the relevant materials in the project.

Set Up Camera Layering

If you are using the Mech Combat Kit you don't need this section.

In the Space Combat Kit, the Vehicle Camera uses layered cameras for rendering the background. This must be configured in URP or the Game View will just show blue.

Open the Vehicle Camera hierarchy and go Horizontal Pivot > Vertical Pivot > Gimbal Child > MainCamera, open the Camera component and set the Render Type to Overlay.

Open the Background object's hierarchy and go to the Camera object, open the Camera component and in the Stack add the Main Camera's camera.

The cameras should now render correctly.

Update Shader Keys

The UVC kits have several scripts that control shaders for visual effects. The main key used to access the color for Particle Unlit shaders in the built-in render pipeline was _Color, but in the equivalent URP shader it is _BaseColor.

Flash Controller

Open the Muzzle Flash prefab, find the Flash Controller script, and set the Color Property Name to _BaseColor.

Jet Exhaust Visual Effects Controller

On all your spaceship prefabs, in the hierarchy under the Exhaust object, you will find this component. Change all the shader color names to _BaseColor.

Effects Color Manager

This component is used as a generic way to control the color of effect shaders. On all prefabs that use it, set the Color ID to _BaseColor.

Beam Weapon Unit

The Beam Weapon Unit component controls the color of various beam effects. Set all the Color Keys to _BaseColor.

Post Processing

URP has its own Post Processing that needs to be set up from scratch, please check out Unity's relevant documentation for more information.

Last updated