Hello,
I’m trying to follow though a book with a 2D project. The book is called “Learning 2D Game Development with Unity” and I am having a most difficult time. My current issue is with a script for moving the player. I am only partially done with it but at this point the book says I should be able to move horizontally but I get errors in the script. I have checked it 3 times against what the book says and I am confident I typed it in correctly. I am coming here to confirm my suspicions that the author of this book was wrong when he coded this script. The errors I am getting all seem to focus on the use of the void function “Flip” on line 45. It says I can not use void in this context and right after that I am getting an unexpected symbol error for using the “(” symbol.
I attached the script in a text file. Any help would be appreciated
2283198–153293–Script With Error.txt (1.1 KB)