PhysicsEntity¶
BETA
PhysicsEntity
is a struct containing information of a PhysicsEntity that simulates physics.Functions¶
void OnHitEnter(function callback<YaEntity, number, float3>)¶
SERVER ONLY BETA
Fired when the entity has been hit by a character.
callback
callback functionYaEntity
The entity that has been hitint
The direction in which the hit comes: 0 from the sides, 1 from the top, -1 from the down sidefloat3
The normal of contact point
void OnHitExit(function callback<YaEntity>)¶
SERVER ONLY BETA
Fired when the entity stops being hit by the character.
callback
callback functionYaEntity
The entity that has been hit
void OnTriggerEnter(function callback<YaEntity>)¶
BETA
Fired when the entity enters a trigger box.
callback
callback functionYaEntity
The entity that enters a trigger box
void OnTriggerExit(function callback<YaEntity>)¶
BETA
Fired when the entity exits a trigger box.
callback
callback functionYaEntity
The entity that enters a trigger box
void OnContactExit(function callback<YaEntity>)¶
SERVER ONLY BETA
Fired when the entity exits another character or rigidbody.