How can i make a forced resolution system even in fullscreen like source games?

I am currently making a PS1 fps game at 320x240 resolution, things are going smoothly at least in Unity itself but when I test the build and turn on full screen the dithering is gone, and I am using the built-in render, please help.

What dithering? Is that a post effect that you are using?

One thing you can do is render to 320x240 rendertexture. That will preserve all of your low-res uglies. Then put that render texture on a quad and point a second camera to that quad to create your final output. Put that quad and the second camera on it’s own special layer.

The output one the screen will be a 320x240 image stretched to the user’s native resolution.

I did that. But the thing is I’ve implemented an aiming system and so when I aim the render texture get all funky and stuff, the other thing is about rendering the fps arms since I have 2 cameras, 1 main and 1 for rendering the arms, so if I put the render texture script in one camera it would only render what that camera sees and leave no fps arms.

provided script:

using UnityEngine;

public class LowRes : MonoBehaviour
{
    public int targetWidth;
    public int targetHeight;
    public bool stretch = false;
    public bool clearBK = true;

    private RenderTexture tex;
    private Camera cam;
    private Rect screenRect;

    private void Start()
    {
        screenRect = new Rect(0, 0, Screen.width, Screen.height);
        cam = GetComponent<Camera>();
        tex = new RenderTexture(targetWidth, targetHeight, 24);
        tex.filterMode = FilterMode.Point;
        cam.targetTexture = tex;
    }
    public Vector3 ScreenToCamPoint(Vector3 aScreenPoint)
    {
        aScreenPoint.x -= screenRect.x;
        aScreenPoint.y -= screenRect.y;
        aScreenPoint.x *= targetWidth / screenRect.width;
        aScreenPoint.y *= targetHeight / screenRect.height;
        return aScreenPoint;
    }

    void OnGUI ()
    {
        if (Event.current.type != EventType.Repaint)
            return;
        screenRect = new Rect(0,0,Screen.width, Screen.height);
        if (!stretch)
        {
            float sa = screenRect.width / screenRect.height;
            float ta = (float)tex.width / tex.height;
            if (sa > ta)
            { // pillar box
                screenRect.width = screenRect.height * ta;
                screenRect.x = (Screen.width - screenRect.width) * 0.5f;
            }
            else
            { // letter box
                screenRect.height = screenRect.width / ta;
                screenRect.y = (Screen.height - screenRect.height) * 0.5f;
            }
        }
        if (clearBK)
            GL.Clear(true, true, Color.black);
        GUI.DrawTexture(screenRect, tex);
    }
}

So render the arms on the other camera?

And the aiming issue, the only thing I was worried about. it goes all funky, do I remove the aiming system completely? I would think that ps1 game would even have an aiming system like modern games.

Oh and also the ui messes up and all the buttons are not interactable somehow

Actually, nevermind this post but thanks for the help I messed around and somehow it turned out that I don’t even need any scripts at all just then I accidentally set “set default resolution as native res” or something like that to true, so I got the native resolution of my screen instead of 320x240 sorry for the inconvenience. I mess up sometimes!