Tomb-Editor
Tomb-Editor copied to clipboard
TE: Implement attractors
In TombEngine, I've introduced prototype interactable attractor objects that lay the foundation for upcoming enhancements and fixes related to ledge grabbing. Attractors are designed to provide a dynamic and dependable means of edge detection during gameplay. The engine-side implementation is about 80% complete, but I require real-world data to fully finish this feature.
Key properties of an attractor:
-
Type: Attractors will come in different types, such as
Edge
,ZipLine
,HorizontalPole
, and others, though only theEdge
type is relevant here. -
Points: Each attractor consists of a collection of n points that define a chain of lines. This chain describes a path. While a single point can define a valid attractor, an
Edge
type attractor must comprise at least 2 points. - Room ID: Room association in the level.
Current TombEngine implementation for better context: https://github.com/MontyTRC89/TombEngine/blob/sezz_edge_catch_refactor/TombEngine/Game/collision/Attractors.h
Tomb Editor requirements:
- Allow the user to dynamically place
Edge
type attractors anywhere in the level. - At level compile, automatically generate
Edge
type attractors around block edges.
Added notes on climbable wall attractors:
Unique from the Edge
type, WallEdge
attractors could be used to build climbable walls dynamically by stacking them 256 units apart when generated automatically in TE. In TEN, the threshold can be fairly lax to avoid strict alignment requirements when placing climbable wall attractors manually.
This implementation allows me to cover legacy setups where the player must strategically move a pushable to "complete" a climbable wall. To be considered valid and climbable, a WallEdge attractor must have a wall directly in front. Additionally, this attractor-based approach can be expanded upon to reimplement overhangs.
Because we don't currently have root motion available in animation handling, wall climb animations will have to be split in a particular way to facilitate correct parenting.