Announcement

Collapse
No announcement yet.

Terrain Issues

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Terrain Issues

    I have some terrain issues I haven't been able to solve, most are painting issues.

    1.)I guess I'll start off explaining when it first started. I was working on my map DM-CanyonFear and finished the heightmap and decided to changed the materials at AnubanUT2 request...so I selected the new materials and went into my terrain edit, right clicked the material and selected "use selected" the materials changed correctly .... it seemed, I then saved and re-built and I now get the error "Terrain > Invalid Material Index 4 DM-CanyonFear.TheWorld:PersistentLevel.Terrain_1!"

    so I attempted to cook to see if it gave me an error..it did.

    "warning, Shader compile error: error x4546 maximum sampler register index exceeded"

    followed by "Warning, Shader compile error: J:\Unreal Tournament 3\Binaries\memory(117,45): warning x3550: sampler array index must be a literal expression, forcing loop to unroll error x4510, maximum number of samplers exceeded, ps_3_0 target can have a maximum or 16 samplers."

    so I'm thinking I messed it up and should start over, I go back and delete the materials and my terrain is now white...shouldn't it be checkered?. I re-add the rock material first and it shows up as grass? ok, so i add a new material that i never used before..shows up as my old dirt path..wtf?...then I get some rainbow colors when I try and paint...so I revert back to my original and try all this again...same story....

    anyone have an idea what I did wrong or how to fix this?

    #2
    It sounds like you added a layer that then exceeded the number of supported texture samplers.
    Go into the Terrain actor itself, not the Terrain Edit dialog, and clear out the Layers array and re-add the TerrainLayerSetups there.
    Then display the Terrain Edit dialog and click on the RM button to recache the materials.

    Comment


      #3
      Originally posted by DGUnreal View Post
      It sounds like you added a layer that then exceeded the number of supported texture samplers.
      Go into the Terrain actor itself, not the Terrain Edit dialog, and clear out the Layers array and re-add the TerrainLayerSetups there.
      Then display the Terrain Edit dialog and click on the RM button to recache the materials.
      tried that. I deleted all the layer arrays and then added new ones...but they don't let me add the TerrainLayerSetups....or maybe I don't know how to do that? I also can't add any materials to the layer because " has no setups"

      and the RM button didn't do anything?

      there's definately something wrong here, when I do get a material added, it always shows up as the wrong material. ei: i add a layer with a grass texture and I get dirt, I add dirt and I get rock, I add rock and I get grass...

      Comment


        #4
        The way that the terrain system works is:

        Textures -> Materials -> TerrainMaterials -> TerrainLayerSetups.

        You use Textures to create Materials.
        You assign Materials to TerrainMaterials along with their Tile values.
        You assign one or more TerrainMaterials to a TerrainLayerSetup with optional Height/Slope values.
        One or more TerrainLayerSetups are added to the array of Layers on the Terrain actor.

        You can't shortcut and simply apply a Texture or Material or TerrainMaterial directly to a Terrain Layer.
        And the Terrain only supports (usually) a maximum of around 4 to 6 Materials depending on the design and number of underlying Textures in the Materials.

        Have a look at Hourences tutorials.

        Comment


          #5
          Thanks DG.

          I followed your suggestions and nothing seemed to work but eventually it seemed to miraculously work right...I think might have been that I deleted the old rock layer and created a new one which wasn't painted. so basically none of my painted layers covered the entire terrain.

          Comment


            #6
            I have a similar issue now, do you think re-chaching the materials in the terain editor will solve this issue. Ill try when I get home (at work for 12 hour shift...). Just asking as its 12 hours away till that happens...

            Comment


              #7
              That depends on exactly what the issue you are having is.
              If recaching materials doesn't fix it, you may have to try restarting, or even temporarily changing layer order to refresh things.
              The total count of TextureSamples in all combined materials, along with where they are painted on the terrain, affects how the system works.

              Comment

              Working...
              X