Sending Events - Flexibility
Posted: Fri Jul 20, 2007 9:27 pm
I've been making control scripts for items and would like them to be able to receive custom events. So far the best workaround I've found is to just create a cprop on the item with the script that would be sending the event, and check for it in the item's control loop. This however forces me to make the control loop iterate much much faster than it should otherwise so that it checks the cprop in time.
I tried SendEvent(), and as the manual suggests, it only works for an NPC's control script.
Is there a way to send an event to an item's control script? Or better yet, a way to send an event to any process given the proper process object would be nice!
I tried SendEvent(), and as the manual suggests, it only works for an NPC's control script.
Is there a way to send an event to an item's control script? Or better yet, a way to send an event to any process given the proper process object would be nice!