it depends, here i use the Forge project that is a rule engine, i only did the UI and UX but all the cards and mecanics are for Forge, ap orject more than 10 years old, is a lot of work to do such a game like this without the engine done already
they have both the Magic rules engine and an interface built-in. The thing is, I didn't like their interface, so I built my own UI using their underlying engine—and that’s how Neo Forge was born.