top of page

Random Fruits - Slot Game - C++

Simple slot game to demonstrate some concepts about C++. It was made

This mini game was done in our Game Dev Society at University of Plymouth, just to test some coding skills. The challenge was print some random fruits according to their weighted probability. And, at the end, the code should show how many of each fruit has been called.




For accomplish the task, I have used some object-oriented knowledge. I have tried to make sure that some key-parts of the project could be easily changed, such as the weights, number of fruits, their names, and how to show the final result.







The final files can be founded on my GitHub page:

https://github.com/thethiagosena/RandomFruits/blob/main/RandomFruits/RandomFruits.cpp


Project Gallery

Technical Specifications

When

15 November 2024

Whom

Plymouth

Roles

Coder

Software

Visual Studio

Methodology

Used Object Oriented Techniques

Learnings

Objected Oriented Codding, some C++ functions, how to use classes

Problems faced?

Use the random function was not easy to understand, since C++ also use the seeds to generate fake random numbers. Completely understand how it works to correctly apply in the game was challenging.

Solutions?

So better understand how to use the random function on C++ I have consulted the official documentation as well as some internet websites.

bottom of page