Mining


Hi all, 

This week I added mines as a new place-able item. Here are some quick notes on this minor update. 

This new Minable type can be used to create any object the player would interact with to gather resources. This includes actual mines, rocks trees, fields and even ponds for fishing. 

Though not designed to be placed by the player, these new items allow for mining of resources such as coal, stone and iron. Mines can be placed at as part of you level build. 

Mines have a limited number of a given resource and once depleted the mine will de-spawn.

There are methods to limit the speed at which the player can extract items from mines. When an item is mined it will automatically be placed in the players inventory. If the players inventory is full the item will be dropped on the ground.

The current selected item will be used as the tool to mine with. The tool used must have a higher damage value then the resource being mined to succeed. for example a stick that has a damage value of one can not mine coal if it has a damage value of 2, but an item with damage value 3 can mine it. And the greater the difference the faster the resource can be mined.

What still needs doing...

There are no new animations to depict the action of mining. 

Mines are currently not included in the save file meaning the resource count resets each time the game starts. 

I also want to add the ability to provide a list of different resources that the minable object may spawn instead of a single a fixed item. Just not sure on the form this will take yet.

Thanks to everyone for the positive comments and feedback so far on this project it means a lot.

TC,

Fidel

Files

Git Repo (Newest version)
External
Jul 15, 2023

Get Player Inventory System

Leave a comment

Log in with itch.io to leave a comment.