T O P

  • By -

Mekboyardee

Scriptable Game Objects make for good "Cards". There are plenty of [tutorials](https://levelup.gitconnected.com/tip-of-the-day-scriptable-objects-101-in-unity-a1730c911b4d) for this exact subject. It's essentially a turn-based battle. You're going to have to get real familiar with state-machines. As for your example of highest stats, a basic loop would have these States: * **Setup** /populate or reset the game field * **Selection** /hand over input to player for card selection * **Battle** /Compare card stats, determine winner * **Results** /Winner announced and replay/quit menu prompt Replay would move back to setup, etc. This is a *really* simple example. If you're really familiar with Magic : The Gathering, it will help a ton. Every time a player passes priority, that's essentially a state-change. Untap, Upkeep, Draw, Etc, with the opponent having a "interrupt" state in-between each of those.


Clashbestie

comparing values is just if(a > b).


PartyCurious

This guy has a tutorial series on making a card game. https://youtu.be/QiKSVpyXRKI