Hello! I'm having problems with my code

So basically I’m trying to make a mod for a game called Friday Night Funkin. I’m starting to get a swing of source code as I already know a few other languages.

The problem im having is this:

D:/Lime/haxe/lib/flixel/4,11,0/flixel/FlxBasic.hx:184: characters 40-44 : Unexpected true

I looked at the code, and I have no idea what to do. Im just staring at it without a clue in the world on how to fix this.

Here’s the one line im staring at right now.

public function remove(arg0:FlxBasic, true:Bool) {}

i’m also guessing the “true” is the one unexpected - but im not sure how to fix that.


true is reserved keyword, you can’t use it as a variable name.

Oh! Then if I can’t use the word then If i simply remove it will it work? Or am I required to put something before the “true” so it works? Because I tried removing all the code and it simply broke also, leading to more errors.

I don’t know if remove is your custom function, or you are implementing some interface, can’t see.

Just give other name (not true) to second argument of the remove function.

Ok i’ll try this

I tried renaming the second argument and it gave me more errors then before.

The only word that leads to only 1 error being the name written “true”.

It seems you are modifying FlxBasic which is used by FlxObject and FlxGroup having remove function declared as

public function remove(Object:T, Splice:Bool = false):T