World generation - general question

Hello!
I’m pretty new to game development and wanted to ask how can I generate a world for a game.

What I need is a flat map with some rivers, trees, rocks, etc.
Any ideas/suggestions on how to do it? Preferably in C++ rather than blueprints.

Using the terrain editor in the viewport is probably the easiest. You can’t really sculpt terrain from code.
I think their documentation have more information about what you are looking for than the forums here.
https://docs.unrealengine.com/latest/INT/Engine/Landscape/Creation/

What about the objects on the map? I want the map to be very big. Should I use procedural generation or some other method to place objects on the map?

There are some assets provided by epic games from game demos, you can download them for free and reproduce it in ur game. Some can be purchased in marketplace as well. as for procedure generation, see this: UE4 - Procedural Level Generation - YouTube

Ok. Let’s make it simpler maybe and change the idea. Now I want to create a map that will procedurally add tiles/polygons connected together (ex. tile with grass) and scatter trees on it.

Is there anything that will connect the tiles into one map or do I need to create and store static meshes (not talking about trees now, tiles only)?

It all depends on what you are trying to achieve.

If you are making an FPS, then you want to go with terrain which is often based on an imported heightmap, typically sculpted by hand or with a tool like WorldMachine.

If you are simply making a 2d top down tiled game, you could create the 2d tiles by hand and place them procedurally using some kind of grid system. (Or just use a grid designer and hand design them)

It is more difficult and time consuming to get procedural stuff to look as good as hand designed.
Often better to get started with hand designed unless the procedural nature is core to gameplay - eg Needs to be random every time

Thanks for reply.
I was thinking about 3D top-down game. Tiles are not necessary, but I thought it may be easier with them. As in first post I want a pretty much unlimited distance flat or at least generated X:Y map with trees on it.

My ideas:

  1. Add X:Y flat map in the designer and scatter the trees using algorithm on the whole map.
  2. Make tiles, scatter trees on them, save them and procedurally generate a map from them.
  3. Procedurally add tiles and scatter trees while adding them. – I think this would be the best.

Making the scattering algorithm shouldn’t be difficult for me and the tutorial imsarah provided teaches how to procedurally generate a map using ready tiles.

Now I have two problems only:

  1. Which idea is the best? Maybe there’s a better one?
  2. (Optional) How to generate a tile in a place where there are no tiles and the place is near player? (Video shows only how to generate NxM tiles) Just Tick and look if there should be a tile, but isn’t or use some kind of event?