C# Class OpenTKEngine.Collider

ファイルを表示 Open project: jikoriko/OpentkEngine Class Usage Examples

Public Properties

Property Type Description
Position Vector2
Size Vector2
Tags List

Public Methods

Method Description
CheckCollision ( Collider other ) : bool

BBOX collision test with colliders.

CheckCollision ( float x, float y, float w, float h ) : bool
CheckCollision ( int x, int y ) : bool

Check collision with a point.

Collider ( Vector2 startingPos, Vector2 size, List tags ) : System.Collections.Generic

Collider object to test collisions

Method Details

CheckCollision() public method

BBOX collision test with colliders.
public CheckCollision ( Collider other ) : bool
other Collider
return bool

CheckCollision() public method

public CheckCollision ( float x, float y, float w, float h ) : bool
x float
y float
w float
h float
return bool

CheckCollision() public method

Check collision with a point.
public CheckCollision ( int x, int y ) : bool
x int
y int
return bool

Collider() public method

Collider object to test collisions
public Collider ( Vector2 startingPos, Vector2 size, List tags ) : System.Collections.Generic
startingPos Vector2 inital (top left) position of hitbox.
size Vector2 the size of the hitbox
tags List tags of entities who should be interacted with. make null for all
return System.Collections.Generic

Property Details

Position public_oe property

public Vector2 Position
return Vector2

Size public_oe property

public Vector2 Size
return Vector2

Tags public_oe property

Who to collide with.
public List Tags
return List