A Simple Farm

Grow crops and sell them to earn money to buy more seeds.


Project Overview

Developed a farming game by incorporating my code with existing code developed by others.

Check out the GitHub repository here!

Technical Components

  • Data Structures: Utilized various data structures for efficient retrieval of data for smooth gameplay.
  • Scriptable Objects: Implemented for consistent data management and retrieval.
  • SOLID Principles: Adhered to principles for scalability. 

My Role:

  • Data Storage: Used a list to keep track of each harvest made and a dictionary to track the total number of crops collected overall. Implemented methods to simultaneously update both data structures to maintain consistency. 
  • Data Algorithm: Implemented a quick sort method to sort the list so that users can view their harvests in ascending order of amount.

Obstacles

Obstacles I encountered and the skills I developed and improved to overcome them.

  • While extending inherited code, Code Comprehension was necessary for me to understand the foundational code of the software in order to develop my own components for the game.
  • Debugging - One of the bugs that stumped me for a while involved methods from existing code and ones I coded. After harvesting a crop and collecting seeds, the number of seeds available to be planted was not updating correctly and user could not plant more than 1 type of crop. The fix: a method from the existing code was updating the wrong plant when seeds were added. Instead of updating the plant the seed belonged to, it was updating the plant the user currently selected. Although the fix was simple, it took a lot of attention to detail to realize which function was the culprit as the action of the user collecting seeds required a chain of methods to complete the event. 
  • Optimization - Choosing the most efficient data structures for my needs. I needed to be aware of the characteristics of different structures and what built-in methods were available for use. Data retrieval with partial information was required in some cases while quick add, read, and delete were needed in others.



StatusReleased
PlatformsHTML5
Rating
Rated 4.0 out of 5 stars
(1 total ratings)
AuthorNaNaNaNatalie
GenreSimulation
Tags2D, Farming Simulator, Relaxing, Singleplayer

Leave a comment

Log in with itch.io to leave a comment.