Schwenckenator / DungeonRoguelike

A roguelike in a dungeon
1 stars 0 forks source link

Thief needs special abilities #51

Closed Schwenckenator closed 4 years ago

Schwenckenator commented 4 years ago

The thief has no special abilities, and needs them to be an interesting character.

crushingCodes commented 4 years ago

I did what you suggested about the overtime effect, and made it a normal effect. added subscription to turn attempted to end the life of the skill over time, but it never decrements.

I think it might be something to do with a scriptable object not keeping state between turns, but could be wrong. I don't usually like to ask for help, but if you have a suggestion. Otherwise ill have to put the state somewhere else.

Schwenckenator commented 4 years ago

Alright, I've had a think, and this is how I'll go about it. We need a list of "Buff"s on EntityStats. A buff is a new class which holds Lists of all sorts of status effects, StatModifiers etc. It also has an end condition, which the buff itself keeps track of. If we make event hooks, like EndOfTurn, StartOfTurn, we can hook the buffs into those events, and have them count turns etc. Once the Buff decides it's done, it asks its entity to remove it, and the effect is gone This should re-use as much of our ability and effect code as possible, and not add weird interactions.