Roblox Create A Crop Farming System
What you'll learn
- Import the project model, and organise the project ready to start.
- Use the changed event to update the GUI whenever the gold value changes.
- Create a functions module script, and add a function to display feedback to the player.
- Change the colour of the plots as they progress through their stages of growth using a variable called State.
- Code the Rake, Bucket, and Seed Bag tools to use on the farm and grow crops.
- Create a sunflower, pumpkin and corn seed to grow on the farm.
- Add all the details about your crops to the seed module script.
- Create conditional statements that guide the player to equip and use the right tools to get the job done.
- Allow the player to collect water from the well to water the crops on the farm.
- Create a special GUI that allows you to see your variables change during the game, and adjusts itself as you increase or decrease the number of variables in the
- Create a start game script that gives each player their own farm.
- Begin to develop a GUI that will hover above the ground showing the player which seeds they can plant, and allow them to click on a button to plant the seed.
- Create a button for each seed that the player has in their inventory.
- Write some code to get all the info about a seed from the seed dictionary and place it into the plot the seed is being planted in.
- Spawn the correct plant and assign it to the plot ready to grow and harvest.
- Use ray casting to change the colour of anything you click on in the project.
- Use ray cast parameters to change the behaviour of the plot as we move it around in the workspace.
- Stop players colliding with other players, and plots colliding with players allowing for smoother game play.
- Let your players buy new seeds when they have made enough gold.
- Test the game using 2 farm models and creating a 2 player test server in Roblox Studio.
- Create a data store for each player using the data module you create.
- Restore player saved data back to the game when they return.
- Make adjustments to the user input script that will create mobile buttons for players using touch enabled devices allowing them to play the game on phones, and
- Create a module script and an animation controller script to handle all the animations you might use in your project.
- Create an animation of the player collecting water from the well using the bucket, and also watering the plants from the bucket.
- Create an animation of the player jumping in the air when harvesting their crops.
Requirements
- Complete course 1 - Learn How To Code Games In Roblox Studio
- Complete course 2 - Roblox Intermediate Coding Course
- A file decompression tool such as WinZip (Windows) or Archive (Mac)
- A Roblox account and character
- Internet connection
Description
This course provides you with all the basic models, tools, and GUIs needed. It focuses primarily on coding and gives students an expandable and adaptable project they can use in their game development.
Some central concepts taught are
using module scripts in different ways
Using co-routines to pause and resume plant growth
creating and using animations
saving part positions and attributes to the data store.
ray casting to move and place parts
creating dictionaries of data that can be referred to from other scripts
coding and using surface, screen, and billboard GUI's
By the end of the project, students should have a farm to which they can add new crops and expand the farm to make it bigger.
As some coding concepts are complex, students should complete the following courses.
Learn To Code Games In Roblox Studio - Beginner
Roblox Intermediate Coding Course - Intermediate
The course structure has been designed to allow a working example to be tested at the end of most lessons.
Many concepts taught in the course can be re-purposed and used in entirely different projects.
To get the most out of the course, students should complete all videos in sequential order for sections one to five. The sixth section about animation is optional but does add a great finishing touch to the project.
Who this course is for:
- Intermediate Roblox Coders
- Roblox Developers
Instructor
I have been learning and teaching computing and programming for over 20 years.
My lectures are organised, well presented, and easy to follow.
I was introduced to playing Roblox, and creating in Roblox Studio by my 10 year old son.
I love the Roblox platform, and the resources available to create a professional Roblox game.
I have created these courses to teach you step by step how to turn your ideas into working games, and once you have the basics you can begin to create any game you can imagine.