Buff & Status Effect Manager

v1.0.0

Getting Started

Create your first status effect in under 5 minutes.

Quick Start

This guide walks you through creating a simple poison effect that deals damage over time. By the end, you'll have a working DoT effect with UI display.

What You'll Create

  • A "Debuffs" category for organizing harmful effects
  • A "Poison" effect that ticks every second for 5 seconds
  • UI display showing the poison icon and remaining duration

Step 1: Create a Category

Categories organize your effects (Buffs, Debuffs, Crowd Control, etc.) and can limit how many effects of each type can be active simultaneously.

  1. Right-click in Project window

    Create → Game Creator → Buff Status Effect Manager → Category

  2. Name it "Debuffs"
  3. Configure in Inspector:
    • • Display Name: Debuffs
    • • Category Type: Debuff
    • • Color: #FF4444 (red)
    • • Max Concurrent: 0 (unlimited)

Step 2: Create the Poison Effect

  1. Right-click in Project window

    Create → Game Creator → Buff Status Effect Manager → Effect Definition

  2. Name it "Poison"
  3. Configure Identity:
    • • Display Name: Poison
    • • Description: Deals damage over time
    • • Category: Assign your "Debuffs" category
    • • Tags: dot, poison
  4. Configure Duration:
    • • Duration Mode: Timed
    • • Duration: 5 seconds
  5. Configure Tick Behavior:
    • • Has Tick: ✓ Enabled
    • • Tick Interval: 1 second
    • • Tick On Apply: ✓ Enabled
Tip: The tick event fires every second. You'll handle the actual damage dealing using Game Creator's Visual Scripting Events (covered later).

Step 3: Setup the Manager

  1. Select your Player GameObject
  2. Add Component: Status Effect Manager

    Component → Game Creator → Buff Status Effect Manager → Status Effect Manager

  3. Configure (optional):
    • • Immunity Profile: Leave empty for now
    • • Max Active Effects: 0 (unlimited)

Step 4: Apply Your First Effect

Use Game Creator's Visual Scripting to apply the poison effect when something happens (e.g., player enters a trigger, enemy attacks, etc.).

Visual Scripting Setup

  1. Create a Trigger (On Trigger Enter, On Click, etc.)
  2. Add Actions to the Trigger
  3. Add Instruction: Buff Status Effect Manager → Apply Effect
  4. Set Target: Player
  5. Set Effect: Assign your "Poison" definition
// Or via C# script:
using BuffStatusEffectManager;

public class PoisonTrigger : MonoBehaviour
{
    public StatusEffectDefinition poison;
    
    private void OnTriggerEnter(Collider other)
    {
        var manager = other.GetComponent<StatusEffectManager>();
        if (manager != null)
        {
            manager.ApplyEffect(poison);
        }
    }
}

Step 5: Add UI Display

  1. Generate UI Prefabs

    Menu: Tools → BSM → Generate UI Prefabs → All

  2. Add Effect Bar to Scene

    Drag BSM_EffectBar.prefab into your Canvas

  3. Configure Effect Bar:
    • • Source Mode: Player (auto-finds player)
    • • Filter Mode: All (show all effects)
Done! Press Play and trigger your poison effect. You should see:
  • Poison icon appears in the effect bar
  • Timer counts down from 5 seconds
  • Console logs tick events every second
  • Icon disappears when effect expires