How to Create a Shadow Hearts Battle System?

One of my favorite games of all time are the Shadow Hearts series. They’re so unique, and I want to know how I can program something like it into my Unity game. There’s the Judgment Ring, in which you have to hit highlighted areas on the ring in order to carry out an attack. If you miss, you won’t be able to attack.
In addition to HP and MP, there are also SP. Sanity Points generally go down 1 with each turn, and when they reach 0, the character goes “Berserk”, and you lose control over him/her.
Here’s a basic video of their uses and what happens here: Shadow Hearts Covenant Boss #1 - Gargoyle - YouTube
They use the Judgment Ring all throughout the battle, and a character goes “Berserk” at 2:55.

Please, please, please help me with this. How do I create the Judgment Ring and Sanity Point systems?

The first part you need to think about is HOW this system works. Try and make logical connections between what you see and the logic that may be working behind it.

A quick example is Sanity points. Obviously this is a variable, and some event causes it to reduce or increase. Whether it be the end of the turn, or perhaps an enemy has an attack that directly affects this? The Sanity points would be represented as a float or an integer, and the events that modify it would be functions/voids.

If your asking how to code this, I suggest starting small and learning either C# or Javascript. Once you understand the logical connections that code requires it should be pretty easy to “Think Tank” a way of making a system like this.

Can I use Ruby to script this?