Adventure Game Studio | Forums

AGS Development => Editor Development => Topic started by: Snarky on 12 May 2020, 19:39

Title: [Feature Suggestion] Auto-link event handlers
Post by: Snarky on 12 May 2020, 19:39
One of the most common newbie errors is to not link an event handler to an event property, so that the function never runs. (And honestly, not even just a newbie error, though more experienced AGS devs know how to fix it on our own.)

So I was thinking: why not do it for them? At compile time, for each event property that doesn't have an event handler set, check if the default function name (with the correct function signature) exists in the relevant script, and if so, automatically link it. (Probably with a warning in the output pane, or maybe even a popup dialog box.)
Title: Re: [Feature Suggestion] Auto-link event handlers
Post by: Gurok on 15 May 2020, 01:47
Nice idea. Perhaps even with support for an annotation a la
Code: [Select]
// $AUTOCOMPLETEIGNORE$ that will tell the compiler not to spit a warning for a particular function.