yohamta / donburi

Just another ECS library for Go/Ebitengine
https://pkg.go.dev/github.com/yohamta/donburi
Other
232 stars 21 forks source link

Adding functionality to unsubscribe from events. #95

Closed infiniteyak closed 1 year ago

infiniteyak commented 1 year ago

I had to use reflect to compare the subscribers. Otherwise you get an error saying you can only compare functions to nil.

yohamta commented 1 year ago

@infiniteyak Thank you for submitting the PR! I didn't realize that pointers to a function cannot be compared each other in Go, so I am grateful to have learned something new 🙂 Your work looks great and I appreciate your attention to detail. Thank you again for your contribution! This change is now available in version v1.3.3.