Add initial implementation of game mechanics and resources management

This commit is contained in:
2025-08-23 00:38:46 +02:00
commit e12acb0238
91 changed files with 2018 additions and 0 deletions

View File

@@ -0,0 +1,30 @@
using Godot;
namespace ParasiticGod.Scripts.Core.Effects;
[GlobalClass]
public partial class ModifyStatEffect : Effect
{
public enum Stat { FaithPerFollower }
public enum Operation { Add, Multiply }
[Export] public Stat TargetStat { get; set; }
[Export] public Operation Op { get; set; }
[Export] public double Value { get; set; }
public override void Execute(GameState gameState)
{
if (TargetStat == Stat.FaithPerFollower)
{
switch (Op)
{
case Operation.Add:
gameState.FaithPerFollower += Value;
break;
case Operation.Multiply:
gameState.FaithPerFollower *= Value;
break;
}
}
}
}