1. Dismiss Notice
  2. GOG.com logo

    Thanks to YOUR votes, GOG.com now sells:
    - Sea Dogs - Sea Dogs: Caribbean Tales
    - Sea Dogs: City of Abandoned Ships

    Vote now to add Pirates of the Caribbean to the list!

    Dismiss Notice
  3. Under the Crossbones Podcast

    A Pirate Podcast with Interviews
    Music, Comedy and all things Pirate!

    - Episode Guide - About - Subscribe -
    - Twitter - Facebook - iTunes - Android -
    - Youtube - Fill the Coffers -

    Dismiss Notice
  4. New Horizons logo

    Quick links for PotC: New Horizons
    - Download latest version
    - Wiki - FAQ - Report bugs here
    - ModDB profile

  5. GOF logo

    Quick links for AoP2: Gentlemen of Fortune 2
    - Downloads and info
    - Historical Immersion Supermod
    - ModDB Profile

Dismiss Notice
New to the forum?
Please take a moment to read our Welcome Message and Forum Rules.

Shaders and material setup

May 26, 2015
Shaders and material setup
  • Shaders and material setup
    Under review for transition to PBR!

    Hearts of Oak is being made in Unity 5 and taking advantage of the new Physically-Based Rendering systems. Please use Unity 5 default shaders to familiarize with PBR workflow. Modelers are also encouraged to download free Viking Village scene from asset store, to try materials in advanced lighting situations.

    Installing shaders:
    Put .shader files in C:/Users/UserName/My Documents/UnityProjectName/Assets/Shaders.

    Creating materials:

    In Unity editor, open project browser in Window > Project. Materials should be saved alongside models they are assigned to. Rclick, Create > Material in chosen folder.
    To apply material, select mesh in scene viewport and under Mesh renderer > Materials > Element 0, browse and select desired material.

    Setting Material Properties:

    At first, select which Shader you want any particular material to use. Simply expand the Shader drop-down in the Inspector, and choose desired shader. Ashinokami's shaders are found under Shader Forge list item.
    The shader you choose will dictate the available properties to change. The properties can be checkboxes, numbers, sliders, colors, textures or vectors. If you have applied the Material to an active object in the Scene, you will see your property changes applied to the object in real-time.

    PM Ashinokami with title "ShaderName - problem report" for any quirks or deviations from supposed functioning,
    and use title "ShaderName - feature request" asking for additional functionality or change in present one. PMs will not be answered unless necessary.

    "How do I..?" questions are handled in Hearts of Oak: 3D Modeling PM conversation.

    Q: Why so many different shaders, why not 1 do-it-all?
    It is performance optimization: Unity shader compiler, on loading a game scene, compiles ubershader into multiple variations, each for unique combination of features, used in that scene (that artists select in material inspector). Each new feature multiplies variations generated, that might bloat shader cache to hundreds of MBs, and significantly slow performance both drawcall and Vram wise. Thus with more and specialized "editor" shaders, we might limit the different ways materials are setup.