![]() |
Gondwana Game Engine Development (master) - 2.6.1
Gondwana is a cross-platform 2.5D game and rendering engine written in C#/.NET 8. It provides fine-grained control over rendering, timing, and scene composition, with built-in support for parallax, z-ordering, pixel overhang, collision detection, and particle effects. Gondwana targets desktop and web platforms using SkiaSharp for graphics and pluggable audio backends for desktop and browser targets.
|
Base class for transient effects applied to a View or SceneLayer. More...
Public Member Functions | |
| void | Cancel () |
| Cancels the effect and restores the presentation state that existed when it began. | |
Protected Member Functions | |
| DisplayEffect (float durationSeconds, EasingKind easing=EasingKind.Linear) | |
Initializes a new instance of the DisplayEffect class. | |
| TTarget | GetTarget< TTarget > () |
| Gets the effect target as the requested reference type. | |
| virtual void | OnStarting () |
| Captures or prepares target state before the effect starts. | |
| void | ApplyProgress (float progress) |
| Applies the eased effect progress to the target. | |
| virtual void | OnCompleted () |
| Runs the effect-specific completion behavior. | |
| void | RestoreOriginalState () |
| Restores the target state captured when the effect started. | |
Properties | |
| Guid | Id = Guid.NewGuid() [get] |
| Gets the effect's unique identifier. | |
| float | DurationSeconds [get] |
| Gets the requested effect duration in seconds. | |
| EasingKind | Easing [get] |
| Gets the easing curve used to transform normalized progress. | |
| EffectStatus | Status = EffectStatus.Pending [get] |
| Gets the current lifecycle state. | |
| float | Progress [get] |
| Gets the normalized, uneased progress in the range 0 through 1. | |
Events | |
| Action< DisplayEffect >? | Completed |
| Occurs when the effect reaches its requested duration. | |
| Action< DisplayEffect >? | Cancelled |
| Occurs when the effect is cancelled or replaced. | |
Base class for transient effects applied to a View or SceneLayer.
Display effects update presentation-only state. They do not move world objects, change collision geometry, or alter a SceneLayer's canonical origin.
Definition at line 12 of file DisplayEffect.cs.
|
protected |
Initializes a new instance of the DisplayEffect class.
| durationSeconds | The duration in seconds. |
| easing | The easing function applied to progress. |
Definition at line 23 of file DisplayEffect.cs.
|
abstractprotected |
Applies the eased effect progress to the target.
| progress | The normalized progress of the operation. |
| void Gondwana.Effects.DisplayEffect.Cancel | ( | ) |
Cancels the effect and restores the presentation state that existed when it began.
|
protected |
Gets the effect target as the requested reference type.
| TTarget | The type of target. |
| TTarget | : | class |
|
protectedvirtual |
Runs the effect-specific completion behavior.
Reimplemented in Gondwana.Effects.ZoomEffect.
Definition at line 158 of file DisplayEffect.cs.
|
protectedvirtual |
Captures or prepares target state before the effect starts.
Reimplemented in Gondwana.Effects.EarthquakeEffect, Gondwana.Effects.FadeEffect, Gondwana.Effects.SlideEffect, Gondwana.Effects.WipeEffect, and Gondwana.Effects.ZoomEffect.
Definition at line 145 of file DisplayEffect.cs.
|
abstractprotected |
Restores the target state captured when the effect started.
|
get |
Gets the requested effect duration in seconds.
Definition at line 41 of file DisplayEffect.cs.
|
get |
Gets the easing curve used to transform normalized progress.
Definition at line 44 of file DisplayEffect.cs.
|
get |
Gets the effect's unique identifier.
Definition at line 38 of file DisplayEffect.cs.
|
get |
Gets the normalized, uneased progress in the range 0 through 1.
Definition at line 50 of file DisplayEffect.cs.
|
get |
Gets the current lifecycle state.
Definition at line 47 of file DisplayEffect.cs.
| Action<DisplayEffect>? Gondwana.Effects.DisplayEffect.Cancelled |
Occurs when the effect is cancelled or replaced.
Definition at line 35 of file DisplayEffect.cs.
| Action<DisplayEffect>? Gondwana.Effects.DisplayEffect.Completed |
Occurs when the effect reaches its requested duration.
Definition at line 32 of file DisplayEffect.cs.