Procedural RPG OT: every action has consequences

Started by Legend, Apr 20, 2019, 09:02 PM

previous topic - next topic

0 Members and 2 Guests are viewing this topic.

Go Down

Legend

I haven't mentioned the crafting system in a while, but it has become really cool!

It's physics based. Anything can be crafted from anything.

For example if making a sword, there is the blade and the handle. Use different items for construction and you get different results. Put steel in the blade and steel+gold in the handle to get a sword fit for a king (if crafted with enough skill). On the other end of things, put a fish in the blade and a pie in the handle to get a very useless weapon.

This lets crafting have a bit of creativity and work in all situations. A player can be lost in the woods and craft stone tools and a stick shelter for example even though those aren't hard coded for that rare situation.

Legend

I am blown away by how big this game could become. Will start with a free alpha that only includes survival elements in a forest. I can use that as a vertical slice of sorts and get that element of the game working great. Start building a community around the game too.

From there it'll enter paid early access or fully release, and then continue expanding as long as players are playing. Could end up with an rpg dream game.

Legend

@the-Pi-guy

Any neural network advice you could share? I haven't investigated it yet but I thought of using a neural network for land generation when zoomed in. Essentially take a 2048x2048 heightmap and upscale a small section with added detail. Needs to only take a second or two to make the detail map. Sound like a good or bad idea?

the-pi-guy

@the-Pi-guy

Any neural network advice you could share? I haven't investigated it yet but I thought of using a neural network for land generation when zoomed in. Essentially take a 2048x2048 heightmap and upscale a small section with added detail. Needs to only take a second or two to make the detail map. Sound like a good or bad idea?
I can't imagine at this point I could give you advice.  ;D

I do know that some companies are using neural networks for something similar.  

The difficult part is whether you could make enough examples to train it well.  

Legend

I can't imagine at this point I could give you advice.  ;D

I do know that some companies are using neural networks for something similar.  

The difficult part is whether you could make enough examples to train it well.  
Yeah I think I've decided against it. There are plenty of height maps from Earth but I'm not making Earth, I'm making a fantasy world. It would be very hard to fine tune the output to fit my needs.


Legend



Not good but very functional terrain. Gives me a lot of control over things.

Legend

Sep 11, 2019, 04:29 PM Last Edit: Sep 11, 2019, 05:45 PM by Legend
The Forged Kingdoms: Survival

TFK: Survival is all about the basics. Just the massive open world and a lone player. This is the base game I'm focused on. Everything else will come in expansions.

This game only has 3 major things to worry about which is nice.

1: world interactions-running, climbing, swimming, hunting, fishing, etc.
2: world generation-making a good world with trees, birds, fish, deer, etc.
3: crafting-player building stuff.

1 and 2 are mostly solved. 3 is still a bit unknown.

Everything can be crafted from anything, but how does crafting work in general? Is a house just a single thing placed in one action, or is it built wall by wall? Is a quarry built or is it dug?


EDT:

I think I've come to a solution.

Buildings are physically built somewhat like real buildings. A blueprint is placed on the ground with the general shape of the building and material piles are generated for each part of the building. So let's say the player is building a nice house. The general scope and design of the house is set from the crafting menu and the player stamps the blueprint into the world. All this does is produce a basic outline of the structure. It also designates a section of ground for wall materials, a section of ground for roof materials, and a section of ground for furnishing materials. These ground sections are open air chests that the player can fill with construction materials such as stone, wood, gold, etc. Simultaneously the player needs to actually build the house. This first starts with digging the basement and setting up the foundation. The player, either using a tool or their bare hands, digs this automatically. It takes less time depending on the circumstances. Then the player builds the walls using a similar system, then the roof, and then the furnishing.

This time based system is needed imo since labor is a major element of construction. Ignoring it would result in unrealistic expansion for massive kingdoms, and would make massive mines and quarries free to build at any moment.


Legend


Legend



It's amazing how much grass helps pull the image together.

Legend

More or less I've finalized my terrain LOD method. A whopping 10 levels of detail will be used.

The highest level of detail is a 128*128 map of the area immediately around the player. It extends ~30 meters in each direction. A single pixel of this map covers ~19 inches. For comparison, the heightmap in Fallout 4 had one pixel per 18 inches. That seems like a good enough resolution considering it was good enough for a AAA game and I'm not pursuing realistic graphics.

The second LOD is another 128*128 map that covers an area twice as wide. Third is a 128*128 map four times as wide, fourth is eight times as wide, etc. After ten of these the texel density matches that of the 2048*2048 prerendered world map.

All ten maps can be packed into a single 512*512 texture so it becomes very efficient. The ground shader transforms its UV based off distance and doesn't need to change anything else.


During normal conditions all maps will be centered around the player, but this is not hardcoded. Each map is updated separately and can be positioned separately. So for example while walking down a path, the smallest map is updated almost every frame while the rest are updated sporadically. If the player teleported to the opposite corner of the world, the LOD levels could pop in from highest detail to lowest detail, opposite of normal texture streaming.

Last but not least, this system is flexible. The texture containing all the maps can be rendered at a higher or lower resolution depending on graphics settings. 64*64 maps can be packed into a 256*256 texture or 256*256 maps can be packed into a 1024*1024 texture and the shader would be fine with that.

Initially these maps will be rendered on the CPU but the end goal will be rendering them on the GPU in between frames.

Legend

Sep 20, 2019, 09:34 PM Last Edit: Sep 21, 2019, 10:45 PM by Legend




Using random colors to set things up, the terrain LODs are mostly working. The third picture shows which pixels correspond to which LOD.

Since these maps will be used for terrain height, normal direction, rock to soil ratio, paved roads/paths, and vegetation rates, there is no need to improve texel consistency any farther. I might however add some trilinear filtering between the levels of detail to make the transitions more seamless when moving.

EDT:

Better example pictures with point filtering.



Legend

Trilinear filtering equivalent is up and running. It makes the transition between lods smooth.




Normal map texturing with simple noise, showing the smooth blend between high resolution at the center and low resolution near the edges.


Go Up