Skip to content

[BUG] Function arguments can persist in other functions #346

Description

@NotHyper-474

This code snippet should be enough. Apparently this has been a bug for a very long time, considering Nene's script's moveByNoteKind seems to accidentally make use of it since, despite having a "kind" argument, it's using onNoteHit's "event" argument instead.

Image
import funkin.modding.module.Module;

class Issue346 extends Module
{
	override function onCreate(event)
	{
		someFunc();
	}

	function someFunc():Void
	{
		// Traces event even though it should only exist in the function that called it.
		trace(event);
	}
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions