Lines
Slide
Slide
Slide
Slide
Slide
Slide
Slide
Slide

INVENTED
WORLDS

Unity

Смена темы

Edit → Preferences... General Editor Theme

Убрать заставку Unity

Edit → Project settings → Player → Splash Image Show Unity Logo

HDRP окружение

Для глобальных настроек добавить volume в Edit → Project settings → Quality → Hdrp → Volume Настройки по умолчанию в Edit → Project settings → Graphics Задаются в DefaultSettingsVolumeProfile (+DefaultLookDevProfile) 1. Устанавливаем плагины: High Definition RP (Window -> Rendering -> HDRP Wizard), Post Processing, Shader Graph, Visual Effect Graph, Cinemachine, Alembic, FBX Exporter, Recorder, Sequences, Terrain Tools, Timeline. Одежда https://soupday.github.io/cc_unity_tools/usage.html 2. Сортировка HDRP элементов В HDRenderPipelineAsset галку на Volumetric Clouds Создаём пустой объект (_VisualSettings). Добавляем в него компонент Volume. Для каждой сцены в его Profile создаём VisualSettings Profile (Main_VisualSettings Profile). В иерархии Assets\Scenes\Main\. Добавленные туда компоненты опишем через скрипт. (дописать в скрипте) В Main_VisualSettings Profile — Add overrides -> Volumetric Clouds. В камере увеличить cliping planes — far до 50000. Для HDRP объектов сделать директорию Assets\HDRPDefaultResources (DefaultLookDevProfile, DefaultSceneRoot, DefaultSettingsVolumeProfile, Foliage Diffusion Profile, Skin Diffusion Profile, HDRenderPipelineGlobalSettings, New HDRenderPipelineAsset, New Lighting Settings) 3. Скрипты для автоматической визуализации окружения (посмотреть настройки для эдитора в мазайке) Код вращения для теста освещения (на Directional Light)

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Rotation : MonoBehaviour
{
    [SerializeField]
    float smooth = 10.0f;
    float tiltAroundY;
    float tiltAroundX;

    private void Start()
    {
        tiltAroundY = transform.rotation.eulerAngles.y;
        tiltAroundX = transform.rotation.eulerAngles.x;
    }

    void Update()
    {
        if (Input.GetAxis("Horizontal") != 0)
        {
            tiltAroundY += Input.GetAxis("Horizontal");
        }
        if (Input.GetAxis("Vertical") != 0)
        {
            tiltAroundX += Input.GetAxis("Vertical");
        }
        

        // Конвертация углов в кватернионы
        Quaternion target = Quaternion.Euler(tiltAroundX, tiltAroundY, 0);

        // Сглаживание вращения
        transform.rotation = Quaternion.Slerp(transform.rotation, target, Time.deltaTime * smooth);
    }
}

Код для добавления компонентов в VisualSettings Profile


Создание сингелтона

private void Awake()
{
    MakeSingleton();
}
private void MakeSingleton()
{
    if (_instance != null && _instance != this)
    {
        Destroy(this.gameObject);
    }
    else
    {
        _instance = this;
    }
}

прога для персонажей в юнити https://www.reallusion.com/auto-setup/unity/download.html

HDRI в cubmap

https://matheowis.github.io/HDRI-to-CubeMap/ Звёздное небо https://svs.gsfc.nasa.gov/4851/ Качать формат equirectangular в 8k

Комментарии

Комментариев пока нет.