# Coding Assistance

**URL:** <https://forum.code.org/t/coding-assistance/27188>\
**Category:** Coding and Debugging Help\
**Created:** [June 4, 2019, 5:24pm UTC](https://forum.code.org/t/coding-assistance/27188 "2019-06-04T17:24:47Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![karen\_black](https://avatars.discourse-cdn.com/v4/letter/k/57b2e6/32.png) [@karen\_black](https://forum.code.org/u/karen_black)\
**Post date:** [June 4, 2019, 5:24pm UTC](https://forum.code.org/t/coding-assistance/27188/1 "2019-06-04T17:24:47Z")

</div>

I’m a first year CS Discoveries teacher and am trying to code a sprite to travel back and forth (not randomly) across part of the screen (think fish in a fish bowl. Attached is the current version of the code.

![Fish1](https://us1.discourse-cdn.com/flex016/uploads/codeorgforum/original/2X/7/704456b6c79521b3fd3ec5e7eec0b91ec16790bc.jpeg) ![fish2](https://us1.discourse-cdn.com/flex016/uploads/codeorgforum/original/2X/6/6ec4a5c6072152eed6d858551289ed2927b663aa.jpeg) !

With this code the fish starts on the right of the bowl, gets to the left side and switches to the right facing fish and doesn’t move. I understand why…but I don’t know what to do instead.

Thank you in advance for whatever suggestions you can throw my way. I have also been playing with If/Else and If/Else if…not sucessfully.

---

<div class="post-metadata">

**Author:** ![kevinsukhoo](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.code.org/kevinsukhoo/32/3617_2.png) [@kevinsukhoo](https://forum.code.org/u/kevinsukhoo)\
**Post date:** [June 5, 2019, 2:29am UTC](https://forum.code.org/t/coding-assistance/27188/2 "2019-06-05T02:29:37Z")

</div>

hi @karen_black,

Would you be able to share the link to your project? I’d like to try some things out

thanks!  
Kevin

---

<div class="post-metadata">

**Author:** ![karen\_black](https://avatars.discourse-cdn.com/v4/letter/k/57b2e6/32.png) [@karen\_black](https://forum.code.org/u/karen_black)\
**Post date:** [June 5, 2019, 3:06am UTC](https://forum.code.org/t/coding-assistance/27188/3 "2019-06-05T03:06:54Z")

</div>

Thank you! I appreciate your time.

[https://studio.code.org/s/csd3-2018/stage/14/puzzle/4?section\_id=2147049](https://studio.code.org/s/csd3-2018/stage/14/puzzle/4?section_id=2147049)

---

<div class="post-metadata">

**Author:** ![edavis](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.code.org/edavis/32/4927_2.png) [@edavis](https://forum.code.org/u/edavis)\
**Post date:** [June 5, 2019, 8:40pm UTC](https://forum.code.org/t/coding-assistance/27188/4 "2019-06-05T20:40:34Z")

</div>

Hi @karen_black,  
The link you shared doesn’t take me to the actual project. If you click on the ‘Share’ button on the top of your screen that’ll give you a link directly to your project. That way we can see the code and help you out better. Thanks!

---

<div class="post-metadata">

**Author:** ![karen\_black](https://avatars.discourse-cdn.com/v4/letter/k/57b2e6/32.png) [@karen\_black](https://forum.code.org/u/karen_black)\
**Post date:** [June 5, 2019, 8:53pm UTC](https://forum.code.org/t/coding-assistance/27188/5 "2019-06-05T20:53:09Z")

</div>

Oh! Thank you. I didn’t realize…

[https://studio.code.org/projects/gamelab/96YnakUQf8iD5Lf7OXcz0rpgqGxVUZRbWkaK66Y0iCI](https://studio.code.org/projects/gamelab/96YnakUQf8iD5Lf7OXcz0rpgqGxVUZRbWkaK66Y0iCI)

---

<div class="post-metadata">

**Author:** ![karenma](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.code.org/karenma/32/4924_2.png) [@karenma](https://forum.code.org/u/karenma)\
**Post date:** [June 7, 2019, 4:14pm UTC](https://forum.code.org/t/coding-assistance/27188/6 "2019-06-07T16:14:29Z")

</div>

Hi Karen,

Here is one way to cause this to happen. There are other ways also.

> **[Check out what I made](https://studio.code.org/projects/gamelab/A2fPtoMp82YJzN61scwTa_dpcxR3QD9F6ya3M5LZcL4)**
>
> I wrote the code myself with Code.org

---

<div class="post-metadata">

**Author:** ![karen\_black](https://avatars.discourse-cdn.com/v4/letter/k/57b2e6/32.png) [@karen\_black](https://forum.code.org/u/karen_black)\
**Post date:** [June 7, 2019, 4:58pm UTC](https://forum.code.org/t/coding-assistance/27188/7 "2019-06-07T16:58:51Z")

</div>

Oh wow! That’s perfect! I haven’t used velocity before…I’ll play with it. I appreciate you taking the time to help me out. Thank you so much!
