handzlikchris / Unity.MissingUnityEvents

Editor extension to generate events that are executed before property set, eg. Transform-position, Transform-rotation, Transform-parent which allows to write more event driven code or debug property changes that are not simple to track down. Easily customisable to allow adding events to different property setters / types.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

how to insert event in functions

zx1299 opened this issue · comments

commented

if i want insert event when function call start or end, how to do?
such as when a gameobject.SetActive is called

thx

I'm afraid the tool won't support that. Right now it's only working with properties.

I'd probably not be too difficult to add, the actual code that does the weaving is here
https://github.com/handzlikchris/AddingEventsToCompiled3rdPartyLibrary - potentally could get you going to get methods hooked up as well.

Also there's another tool that does IL rewriting on your code (rather than Unity dlls) which would also need a change but it should be simpler than trying to hook up into Unity extern methods.

https://github.com/handzlikchris/Unity.TransformSetterInterceptor