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.
Loading...
Searching...
No Matches
Gondwana.Physics.Collisions.CollisionProfile Class Referencesealed

Describes a reusable, scene-level collision-filtering role using collision group names rather than scene-specific integer masks. More...

Public Member Functions

 CollisionProfile (string name, string collisionGroup, IEnumerable< string >? collidesWith=null, bool collidesWithAll=false)
 Initializes a collision profile.
int ResolveCollisionGroup (CollisionGroupRegistry groups)
 Resolves this profile's own group through the supplied scene registry.
int ResolveCollidesWith (CollisionGroupRegistry groups)
 Resolves this profile's interaction mask through the supplied scene registry.

Properties

string Name [get]
 Gets the stable profile name.
string CollisionGroup [get, set]
 Gets or sets the registered collision group name assigned to this profile.
List< string > CollidesWith [get]
 Gets the registered group names with which this profile interacts.
bool CollidesWithAll [get, set]
 Gets or sets whether this profile interacts with every collision group.

Detailed Description

Describes a reusable, scene-level collision-filtering role using collision group names rather than scene-specific integer masks.

Definition at line 9 of file CollisionProfile.cs.

Constructor & Destructor Documentation

◆ CollisionProfile()

Gondwana.Physics.Collisions.CollisionProfile.CollisionProfile ( string name,
string collisionGroup,
IEnumerable< string >? collidesWith = null,
bool collidesWithAll = false )

Initializes a collision profile.

Parameters
nameThe name.
collisionGroupThe name of the collision group assigned to the profile.
collidesWithThe names of the groups that this profile can collide with.
collidesWithAllWhether this profile collides with every collision group.

Definition at line 19 of file CollisionProfile.cs.

Member Function Documentation

◆ ResolveCollidesWith()

int Gondwana.Physics.Collisions.CollisionProfile.ResolveCollidesWith ( CollisionGroupRegistry groups)

Resolves this profile's interaction mask through the supplied scene registry.

Parameters
groupsThe scene registry used to resolve named collision groups.
Returns
The mask of groups this profile can collide with.

Definition at line 73 of file CollisionProfile.cs.

◆ ResolveCollisionGroup()

int Gondwana.Physics.Collisions.CollisionProfile.ResolveCollisionGroup ( CollisionGroupRegistry groups)

Resolves this profile's own group through the supplied scene registry.

Parameters
groupsThe scene registry used to resolve named collision groups.
Returns
The bit flag of the profile's collision group.

Definition at line 62 of file CollisionProfile.cs.

Property Documentation

◆ CollidesWith

List<string> Gondwana.Physics.Collisions.CollisionProfile.CollidesWith
get

Gets the registered group names with which this profile interacts.

Definition at line 50 of file CollisionProfile.cs.

◆ CollidesWithAll

bool Gondwana.Physics.Collisions.CollisionProfile.CollidesWithAll
getset

Gets or sets whether this profile interacts with every collision group.

Definition at line 55 of file CollisionProfile.cs.

◆ CollisionGroup

string Gondwana.Physics.Collisions.CollisionProfile.CollisionGroup
getset

Gets or sets the registered collision group name assigned to this profile.

Definition at line 45 of file CollisionProfile.cs.

◆ Name

string Gondwana.Physics.Collisions.CollisionProfile.Name
get

Gets the stable profile name.

Definition at line 40 of file CollisionProfile.cs.