20 lines
697 B
C#
20 lines
697 B
C#
using Gamesmiths.Forge.Attributes;
|
|
|
|
namespace Movementtests.scenes.player_controller.scripts;
|
|
|
|
public class PlayerAttributeSet : AttributeSet
|
|
{
|
|
public EntityAttribute Health { get; }
|
|
public EntityAttribute Mana { get; }
|
|
public EntityAttribute Strength { get; }
|
|
public EntityAttribute Speed { get; }
|
|
|
|
public PlayerAttributeSet()
|
|
{
|
|
// Initialize the attributes with the current, min and max values.
|
|
Health = InitializeAttribute(nameof(Health), 100, 0, 150);
|
|
Mana = InitializeAttribute(nameof(Mana), 100, 0, 100);
|
|
Strength = InitializeAttribute(nameof(Strength), 10, 0, 99);
|
|
Speed = InitializeAttribute(nameof(Speed), 5, 0, 10);
|
|
}
|
|
} |