Search Unity

_WaveScale Error

Discussion in 'Editor & General Support' started by NathanielEdwards, May 27, 2009.

  1. NathanielEdwards

    NathanielEdwards

    Joined:
    May 17, 2009
    Posts:
    12
    This problem has (last post) appeared on the board before, but it wasn't solved. On Unity Indie, I am getting spammed with error messages related to the regular Daylight Simple Water asset that comes packaged in. This isn't actually preventing my program from working (at the moment) but it's getting rather irritating. Here's one of the errors:

    Code (csharp):
    1. Material doesn't have a float or range property '_WaveScale'
    2. UnityEngine.Material:GetFloat(String)
    3. UnityEngine.Material:GetFloat(String)
    4. WaterSimple:Update() (at Assets\Standard Assets\Water\Sources\WaterSimple.cs:18)
    5.  
    6. [..\..\Runtime\Shaders\Material.cpp line 503]
    I'm sure this is some simple mistake as usual, but I'm getting basically that error message for _WaveScale and WaveSpeed. Thanks in advance for any help.[/code]
     
  2. jonas-echterhoff

    jonas-echterhoff

    Unity Technologies

    Joined:
    Aug 18, 2005
    Posts:
    1,666
    This looks like you assigned the WaterSimple script to some GameObject, but the Material on that GameObject's renderer isn't using the water shader (ie, it doesn't have the properties expected by the script). Did you maybe drag the water prefab somewhere into your scene, and then change it's material?
     
  3. NathanielEdwards

    NathanielEdwards

    Joined:
    May 17, 2009
    Posts:
    12
    I don't think so. I dragged in the water prefab, then scaled it up as is fairly normal, and unless I'm wrong, I didn't do anything else to it. I can try taking it out and putting the prefab back in without any modifications and see what happens.

    EDIT: Alright, dragging a new daylight or night simple water in gives me the same problem every time.
     
  4. NathanielEdwards

    NathanielEdwards

    Joined:
    May 17, 2009
    Posts:
    12
    EDIT: Just started a new topic for my other issue I had mentioned here.