Skip to content

edyangel/generador-2D

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

2D Procedural Island Template (Unity 6 / URP RenderGraph)

This project is a Unity 2D template extended for massive RTS-style maps with giant biomes and smooth coast transitions. It targets Unity 6 (6000.x) with URP 17 using RenderGraph.

Highlights

  • URP RenderGraph enabled, compatibility mode disabled.
  • Cinemachine intro zoom from far → follow player (CM3/CM2 supported).
  • Optional 2D Pixel Perfect guidance for crisp 16x16 tiles.
  • New biome pipeline:
    • BiomeGenerationStep → world-scale biomes (Ocean, Coast, Desert, Grassland, Forest, Mountain)
    • BiomeToTilesGenerationStep → converts BiomeType → TileType
    • BiomeTransitionsGenerationStep → adds Sand/SandGrass bands for smooth lagoon/grass/sand/sea

Requirements

  • Unity 6000.x (Unity 6) or 2022.3 LTS (with packages updated accordingly)
  • URP 17.x
  • Cinemachine 3.x (or 2.9.x)
  • Optional: 2D Pixel Perfect package

RenderGraph settings

Already enabled. If needed:

  • Assets/Settings/UniversalRP.asset → RenderGraph enabled
  • Assets/UniversalRenderPipelineGlobalSettings.asset → RenderGraph enabled, Compatibility Mode off

Camera setup

  • Main Camera: add CinemachineBrain
  • Have one CinemachineCamera (CM3) or CinemachineVirtualCamera (CM2) in scene
  • Player GameObject has CinemachineCameraHelper:
    • Assign vcam field (or it will auto-find one)
    • Default lens size: 100 → zoom to 6 over 3s (configurable)
    • Force Orthographic enabled (2D)

Pixel art clarity (16x16 tiles)

  • Sprite Import: Filter Mode = Point (no filter), Compression = None, Mip Maps = Off, PPU = 16
  • Add Pixel Perfect Camera to Main Camera:
    • Assets PPU = 16
    • Reference Resolution = 640x360 (or 320x180/960x540)
    • Upscale Render Texture = On
  • URP: MSAA Off, Render Scale = 1.0

Biome generation pipeline

Add these steps to the MapGenerator list in this order:

  1. BiomeGenerationStep
  2. BiomeToTilesGenerationStep
  3. BiomeTransitionsGenerationStep (optional)
  4. ShoreLineGenerationStep
  5. ShallowSeaGenerationStep
  6. HillsGenerationStep
  7. GrassGenerationStep
  8. TreeGenerationStep
  9. EdgeFlatteningGenerationStep / FixMapEdgesStep

Disable BaseIslandMapGenerationStep or turn off its masks so it doesn't overwrite biome tiles.

Noise assets

  • For biomes: use large Scale (300–1000), low octaves (2–4)
  • Thresholds (suggested): Ocean ~0.35, CoastBand 0.05, Desert <0.30, Forest >0.60

How to run

  • Open the project in Unity 6000.x
  • Open a scene from Assets/Scenes
  • Press Play. Camera starts far away → zooms in → follows player; move with WASD

Notes

  • If you see blurry/pixelated tiles when zooming, ensure Point filter + Pixel Perfect Camera config above.
  • If Cinemachine compile errors appear, confirm package version (3.x) and the namespace Unity.Cinemachine.

License

See original asset license files inside Assets/ for third-party content.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages