#``` if not event.element or not event
1 messages · Page 1 of 1 (latest)
I tested it and it still returns the error, funny thing is when I change the position of the two if clauses the other button crashes the game.
well somehow it cannot find the element 🤔
is the element destroyed when clicked upon?
ahh, got it, if the first if clause is true the whole window is destroyed.
If the secound if clause then tries to access a child of the destroyed element.
Fixed it with:
local name = event.element.name
I wasted so much time on this,
Thanks for the help🥳
No problem, sometimes a rubber duck is all you need.