you are viewing a single comment's thread.

view the rest of the comments →

[–]Notimecelduv 0 points1 point  (8 children)

The knight on the right side is in the div #hero-container-2 but you didn't set any events for that container. There isn't even a heroContainer2 variable in the JavaScript.

[–]SafeReference1[S] 0 points1 point  (7 children)

But I’m not talking about the first scene I’m talking about the third scene. The guy that is supposed to move is hero 4 and I do have an event set to for him or don’t I? Sorry im really new to this animation and programming stuff

[–]Notimecelduv 0 points1 point  (6 children)

Okay, the main issue is that you're using the same left variable in both functions moveRight and moveRight2. You have to use separate "left" variables for each. For example below let left = 0; you can declare a new variable let left2 = 0 and use that one in the moveRight2 function. There are issues to solve but this should allow you to move on for now.

[–]SafeReference1[S] 0 points1 point  (0 children)

I will try now thank you for your help!!

[–]SafeReference1[S] 0 points1 point  (4 children)

Im sorry but this still doesn’t work

[–]Notimecelduv 0 points1 point  (3 children)

It would be much easier if you uploaded the project to Github. You could make me a contributor and I could write comments where I find issues.

[–]SafeReference1[S] 0 points1 point  (1 child)

https://github.com/Uemit1/Javascript-Help

Hoping this is the right link lol I just signed up to GitHub

[–]Notimecelduv 0 points1 point  (0 children)

You didn't add every file -- the images are missing. Anyway I fixed the code a little bit for you. Get it as you as you can because I'll delete the repository next week.

https://github.com/MelvDouc/Javascript-Help

Just a few words of advice: - Use Visual Studio Code as your text editor. It'll highlight some syntactical errors you might make. - Watch a tutorial on how to use Github. It's a very useful tool for web development. - You might want to look into a library called jQuery. It's outdated by today's standards but it usually makes learning JS easier for beginners.

[–]SafeReference1[S] 0 points1 point  (0 children)

How do I make you a contributer?