I'm having a problem with everything bouncing. I can't figure a way to make it stop when hitting a wall except by making it bounce. Also, they shoot you even if a wall is in the way.
Offline
<when green flag clicked>
<forever>
<if><touching[ edge
<broadcast[ wallhit
<when I receive[ wallHit
<stop all>
Offline
Or you could use the less complicated:
<when green flag clicked>
<forever>
<if><touching[ edge
<stop script>
<end>
<end>
Offline
henley wrote:
Or you could use the less complicated:
<when green flag clicked>
<forever>
<if><touching[ edge
<end>
<end>
keeps the forever running.
Offline
To bounce when hitting a wall just make an x-velocity and/or y-velocity and multiply them by 1: Here is an example.
Offline
bbbeb wrote:
henley wrote:
Or you could use the less complicated:
<when green flag clicked>
<forever>
<if><touching[ edge
<end>
<end>keeps the forever running.
![]()
You never added the
<stop script>
block.
Offline
I need it to stop the script if touching the color red, not stop everything. Also, I need the script to reactivate after it stops touching.
Offline
<when green flag clicked>
<forever>
<if><touching color[ Red
<stop script>
Offline
[blocks]<when green flag clicked>
<forever if><not> <touching color[ red >>
do script
<end>
[/blocks]
or...
[blocks]<forever>
do stuff
<if> <touching color[ red
<wait until><not> <touching color[ red >>
<end>
<end>
[/blocks]
Last edited by floppy_gunk (2011-02-11 14:19:53)
Offline
How do I get my forever blocks to allow more blocks on the bottom.
Offline
RedAlertFan wrote:
How do I get my forever blocks to allow more blocks on the bottom.
You can't, because a forever block will repeat without stopping unless the red stop sign is pressed or a stop script block is put in it. There can't be anything underneath because it would never run.
Offline