Cervator edit: Header added, moved to Incubator Modules, quite dated by now
Skaldarnar edit: Changed Scope to Mod, opened for new curator.
Name: Status Effects and Potions
Summary: System to apply status effects to the player (and others) mainly through the use of potions
Scope: Mod
Current Goal: Final polish of initial potions, more potions, going beyond potions?
Phase: Implementation
Curator: Awaits new curator! (old curator: B!0HAX)
Related: #242, #262
StatusEffectComponent: Data for handling the different Effects.
·EffectType (enum) : HealthBoost, SpeedBoost, Poisoned, Fatigued...
·EffectDuration...
·EffectIcon (for making a buff/de·buff screen that shows current active stat. effects)
StatusAffectorSystem: Effect Specifications : What it does when the effect is applied.
DrinkPotionAction [EventHandler] : For the actual testing of a buff Im using a speedpotion.prefab that carries (potion component) the info that it is a cerulean (light blue) color and inside this eventhanlder the cerulean potions call the speed potions effect.
In this case example:
Currently I do all this from the DrinkPotionAction, but wanting to expand the effects to make them have a "timer" and maybe a place in the screen where it shows an icon if its active... I have thought of it being designed in this way, there will be many ways of doing this... lets see what you guys think about this layout.
Skaldarnar edit: Changed Scope to Mod, opened for new curator.
Name: Status Effects and Potions
Summary: System to apply status effects to the player (and others) mainly through the use of potions
Scope: Mod
Current Goal: Final polish of initial potions, more potions, going beyond potions?
Phase: Implementation
Curator: Awaits new curator! (old curator: B!0HAX)
Related: #242, #262
StatusEffectComponent: Data for handling the different Effects.
·EffectType (enum) : HealthBoost, SpeedBoost, Poisoned, Fatigued...
·EffectDuration...
·EffectIcon (for making a buff/de·buff screen that shows current active stat. effects)
StatusAffectorSystem: Effect Specifications : What it does when the effect is applied.
Code:
switch(effect.type)
case SpeedBoost:
[here call the components that is in charge of the effect]
charactermovementcomponent.runSpeed = xx;
statuseffectcomponent.effectDuration = xx;
"...".effectIcon = "SpeedBoost";
[call a guimanager new UIBuffScreen to add the newly applied bufficon while the timer is counting down.]
["Poisoned" status would be an icon that uses the UIDebuffScreen for example]
break;
[...]
In this case example:
Code:
switch(potion.type)
case Cerulean:
[Call the statusaffector with the specific effect we want]
call speed effect > statusaffectorsystem.SpeedBoost
//Give an empty vial, destroy empty vial if inventory is full...
[...]
break;
[...]
Last edited by a moderator: