Collider ("Collision Check") class - handles collisions between actors.
It also includes logic that handles collisions within a horizontally looping stage (like 2-C).
Definition at line 12 of file d_cc.hpp.
|
| enum | CC_SHAPE_e {
CC_SHAPE_BOX
,
CC_SHAPE_CIRCLE
,
CC_SHAPE_DAIKEI_UD
,
CC_SHAPE_DAIKEI_LR
} |
| |
| enum | CC_DATA_FLAG_e {
CC_DATA_NO_OFFSET = 1
,
CC_DATA_PASSIVE = 4
} |
| |
| enum | CC_FLAG_e { CC_DISABLE = 2
} |
| |
| enum | CC_CATEGORY_e {
CAT_PLAYER_GENERIC
,
CAT_PLAYER_ATTACK
,
CAT_YOSHI
,
CAT_ENTITY
,
CAT_BALLOON
,
CAT_ITEM
,
CAT_PROJECTILE
,
CAT_CANNON
,
CAT_GOAL_POLE
} |
| |
| enum | CC_ATTACK_e {
ATTACK_FIRE = 1
,
ATTACK_ICE
,
ATTACK_STAR
,
ATTACK_ICE_BREAK
,
ATTACK_SLIP
,
ATTACK_KOOPA_FIRE
,
ATTACK_HIP_ATTK
,
ATTACK_WIRE_NET
,
ATTACK_SHELL
,
ATTACK_PENGUIN_SLIDE
,
ATTACK_SPIN
,
ATTACK_UNK12
,
ATTACK_SPIN_FALL
,
ATTACK_FIRE_2
,
ATTACK_YOSHI_EAT
,
ATTACK_YOSHI_MOUTH
,
ATTACK_CANNON
,
ATTACK_SPIN_LIFT_UP
,
ATTACK_YOSHI_BULLET
,
ATTACK_YOSHI_FIRE
,
ATTACK_ICE_2
,
ATTACK_SAND_PILLAR
} |
| |
|
| | dCc_c () |
| | Constructs a new collider.
|
| |
| virtual | ~dCc_c () |
| | Destroys the collider.
|
| |
| void | clear () |
| | Clear the data related to previous collisions.
|
| |
| void | entry () |
| | Places this collider in the collider list.
|
| |
| void | release () |
| | Removes this collider from the collider list.
|
| |
| void | registerCc (dBaseActor_c *actor, CcData_s *collInfo) |
| | Registers an owner actor to this collider and sets the collider data.
|
| |
| void | registerCc (dBaseActor_c *actor, CcData_s *collInfo, u8 nonCollideMask) |
| | Registers an owner actor to this collider and sets the collider data.
|
| |
| void | setFriendActor (dBaseActor_c *actor) |
| | Sets a friend actor for this collider.
|
| |
| u16 | isHit (u16 mask) const |
| | Gets the result of a hit check.
|
| |
| u16 | isHitAtDmg (u16 mask) const |
| | Gets the result of an attack hit check.
|
| |
| float | getTopPos () |
| | Gets the Y position of the top of the collider.
|
| |
| float | getUnderPos () |
| | Gets the Y position of the bottom of the collider.
|
| |
| float | getCenterPosY () |
| | Gets the Y position of the center of the collider.
|
| |
| float | getRightPos () |
| | Gets the X position of the right side of the collider.
|
| |
| float | getLeftPos () |
| | Gets the X position of the left side of the collider.
|
| |
| float | getCenterPosX () |
| | Gets the X position of the center of the collider.
|
| |
| mVec2_c | getCenterVec () |
| | Gets the center of the collider as a vector.
|
| |
| bool | isInside (dCc_c *other) |
| | Checks if this collider is inside another collider.
|
| |
|
| static bool | _hitCheckSquare (dCc_c *c1, dCc_c *c2, mVec2_c pos1, mVec2_c pos2) |
| | A hit check function for rectangular colliders. Used in _hitCheckNormal and _hitCheckLoop.
|
| |
| static bool | _hitCheckNormal (dCc_c *c1, dCc_c *c2) |
| | Check two rectangular colliders against each other for collisions without stage looping.
|
| |
| static bool | _hitCheckLoop (dCc_c *c1, dCc_c *c2) |
| | Check two rectangular colliders against each other for collisions with stage looping.
|
| |
| static bool | _hitCheckCircle (dCc_c *c1, dCc_c *c2) |
| | Check two circle colliders against each other for collisions.
|
| |
| static bool | _hitCheckBoxCircle (dCc_c *c1, dCc_c *c2) |
| | Check a rectangular and a circle collider against each other for collisions.
|
| |
| static int | _lineCheckUD (mVec2_c p1, mVec2_c p2, float p3, float p4) |
| |
| static bool | _hitCheckDaikeiUD_R (dCc_c *ccBox, dCc_c *ccTrp) |
| | Check a rectangular collider against a trapezoid-shaped collider for collisions.
|
| |
| static bool | _hitCheckDaikeiUD (dCc_c *ccTrp, dCc_c *ccBox) |
| | Check a trapezoid-shaped collider against a rectangular collider for collisions.
|
| |
| static int | _lineCheckLR (mVec2_c p1, mVec2_c p2, float p3, float p4) |
| |
| static bool | _hitCheckDaikeiLR_R (dCc_c *ccBox, dCc_c *ccTrp) |
| | Check a rectangular collider against a trapezoid-shaped collider for collisions.
|
| |
| static bool | _hitCheckDaikeiLR (dCc_c *ccTrp, dCc_c *ccBox) |
| | Check a trapezoid-shaped collider against a rectangular collider for collisions.
|
| |