Page MenuHomeFeedback Tracker

A Event For objects being attached
New, NormalPublic

Description

Searching through the list of attached objects can be slow depending on how much is attached. Sometimes it better to just know if an object was attached rather than searching all the object. As such I would like to request an event of attaching objects.

objectAttached triggers for the attachedTo object, I.E. attaching a crate to a player, the event triggers on the player. _attachedToObject would be the player, and _attachedObject would be the crate.

this addEventHandler ["objectAttached", {
	params ["_attachedToObject", "_attachedObject"];
}];

objectAttach triggers for the attached object, I.E. attaching a crate to a player, the event triggers on the crate. _attachedObject would be the crate, _attachedToObject would be the player.

this addEventHandler ["objectAttach", {
	params ["_attachedObject", "_attachedToObject"];
}];

Details

Severity
Feature
Resolution
Open
Reproducibility
N/A
Operating System
Windows 10 x64
Category
Scripting

Event Timeline

killerswin2 changed Category from General to Scripting.Dec 27 2022, 11:59 PM
killerswin2 updated the task description. (Show Details)
killerswin2 updated the task description. (Show Details)Dec 28 2022, 12:01 AM
killerswin2 renamed this task from Add objectAttached Event Handler to A Event For objects being attached.Dec 28 2022, 3:54 AM
jaj22 added a subscriber: jaj22.May 26 2023, 3:57 AM

Could use other attachTo arguments in the EH as well.