makspll / bevy_mod_scripting

Bevy Scripting Plugin
Apache License 2.0
390 stars 31 forks source link

Fix bug in Rhai Event Handler #76

Closed zwazel closed 11 months ago

zwazel commented 11 months ago

This should fix #75

Also added a new example for Rhai.

zwazel commented 11 months ago

I just noticed that i also updated the Rhai version. please tell me if I should revert this change or not.

zwazel commented 11 months ago

I also just changed it so that i no longer get errors printed out when a function can't be found in a script.

as far as i can tell, this is a similar behaviour as in the Lua solution: https://github.com/makspll/bevy_mod_scripting/blob/75902486147e48b509e07752f713bfff459dba46/languages/bevy_mod_scripting_lua/src/lib.rs#L169-L172

makspll commented 11 months ago

Hi @zwazel PR looks good, great catch! Love the examples. Please see to the clippy errors and LGTM

zwazel commented 11 months ago

Glad I can help with this great crate! I currently can't go on my PC, so i'll fix the clippy errros tomorrow!

I might also take a Look at how to tackle #75

Just saw your comment on it, will Look at it later. On mobile right now.

makspll commented 11 months ago

Appreciate it a lot! no problem!

zwazel commented 11 months ago

Hi, as far as I can tell the only clippy warning that I got was from lua derive. (I actually didnt get any locally, so kinda hard to reproduce, but that should have fixed it)

makspll commented 11 months ago

Yeah sorry about that, the CI runs on latest rust version meaning any new clippy warnings randomly popup on old code, I need to find a way to pick the clippy version somehow