Timeline for Issue translating objects by one unit in the y direction
Current License: CC BY-SA 3.0
9 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Mar 16, 2016 at 18:57 | comment | added | loremIpsum1771 | If you're curious, check my answer at the bottom. | |
Mar 10, 2016 at 16:10 | comment | added | Jon |
@loremIpsum1771, I revised the code. Add only "breakpoint 1" and, once it fires, add "breakpoint 2" and verify the value of xDirect . It should be -1 and fall-through to the else . Add a third breakpoint where xDirect reverses the second time and inspect the conditions that are making it fire.
|
|
Mar 10, 2016 at 16:07 | comment | added | Jon | @loremIpsum1771, I agree that you are moving them past the edge so you'll either need to move them back, or just don't move them past the edge in the first place and I went with the latter. The structure of the flow-control should have shortcut out, but I don't have the project to step through. | |
Mar 10, 2016 at 16:01 | history | edited | Jon | CC BY-SA 3.0 |
added 88 characters in body
|
Mar 10, 2016 at 5:55 | comment | added | loremIpsum1771 | Sorry for the late response, I've been extremely busy! I tried the code ( and I applied the same logic for the collision with the left side of the screen) but for some reason, I seem to be having the same problem as before. I think the MikeG was right in saying that I need to move the aliens back to the left during the collision, but the only way I can think to do that is to add another two loops nest in the if statement for if the right side has been hit. Is there a better way to implement this? | |
Mar 7, 2016 at 10:49 | history | edited | Jon | CC BY-SA 3.0 |
added 108 characters in body
|
Mar 7, 2016 at 10:33 | history | edited | Jon | CC BY-SA 3.0 |
added 6 characters in body
|
Mar 7, 2016 at 10:27 | history | edited | Jon | CC BY-SA 3.0 |
added 206 characters in body
|
Mar 7, 2016 at 10:20 | history | answered | Jon | CC BY-SA 3.0 |