After last week change, I finally wanted to have a rarity system for the units. It has been pretty straight forward: instead of having one array of game objects in the shop for the units, I have one for each Rarity. To manage the drop rates I use an AnimationCurve variable for each rarity, determining the percentage chance of a slot rolling a unit of that rarity at each player level; AnimationCurves are cery nice for this purpose: the X axis corresponds to the player level and the Y axis is the drop chance (between 0 and 1). This way when checking what is the percent i just return the value of the curve at the current player level.
When I am rolling each slot I first roll for wich rarity it’s going to drop, and then for a unit in the list of that rarity.
Just for demonstration purposes I created 1 unit of Epic rarity. As said previously I want Epic units to have 2 spells (this way I also demonstrate the ability of the Ability System to handle multiple abilities).
And that is basically it, it is ver simple now to make as many units and abilities as one wants; I won’t be creating new units and abilities probably, I want to focus on functionality and bug fixing over straight up content, especially since the 3D models I’ve been using so far don’t really come in a standardized dimension and I have to heavily edit them to make them work properly, which is very time consuming.
See you next week when I’ll be putting some variance into the game to make it less boring.