Error: Incorrect number of arguments


(Illya) #1

Hello guys. I’m learning flashpunk with this tutorials http://www.youtube.com/watch?v=Ek0HLk6wBmQ and I have some error here:

override public function begin():void { add(new Player(new Point(FP.screen.width / 2 - 12, FP.screen.height / 2 - 12))); add(new Level(DEFAULT_MAP)); super.begin(); } Error: Incorrect number of arguments. Expected no more than 0. Link in comments, how to solve this, under that video does no longer exist. So I need help. Thanks for your attention


(Jacob Albano) #2

Either your Player class or your Level class has a constructor that takes no arguments.