Delegates & Events

Delegates are type-safe function pointers — they hold a reference to a method and allow you to pass methods around as variables, store them, and invoke them later. Events build on delegates to create a publisher/subscriber pattern where one object broadcasts a signal and many others can listen for it.

More in C# Essentials

  1. Data Types
    1. Control Flow
      1. If
      2. else
      3. else if
      4. switch
    2. Primitive Data Types
      1. Int
        1. float
      2. bool
        1. char
  2. Methods
  3. Classes & Objects
    1. Constructors
    2. Properties
    3. Access Modifiers
  4. Inheritance
  5. Operators
  6. Loops
  7. Arrays
  8. Lists & Collections
  9. Interfaces
  10. Abstract Classes
  11. Enums
  12. Structs
  13. Generics
  14. Delegates & Events
  15. Lambda Expressions
  16. LINQ
  17. Async & Await

All 157 topics in the Learn Unity Roadmap