Ask coding questions

← Back to all posts
Clock not working
h
okalisl

I am making a game and just started to make a clock. I got it so it was a little slower and all, but I couldn't find a way to get the if statement working. Anyone know whats wrong with the code? (main.js line 88)

Answered by AmoghTheCool [earned 5 cycles]
View Answer
Voters
okalisl
Comments
hotnewtop
AmoghTheCool

@okalisl, can you reply with the if code? I can't see where - you have a ton of files :)

okalisl

Sorry about that @AmoghTheCool. Its main.js line 88.

AmoghTheCool

@okalisl there isn't anything wrong with your if statement (syntax-wise), but before it you have a stray comma on line 86 so that might be causing an error. It might be a semantic error. I haven't used KaboomJS before so I don't know how to debug your code.

okalisl

It seems like that actually was part of the issue @AmoghTheCool . Thanks!

AmoghTheCool

@okalisl welcome!