![]() ![]() ![]() change by (1) end if then set to ((angle) + (180)) // If something goes very wrong just turn the bullet 180 degrees. repeat until or > change x by ( of (angle)) change y by ( of (angle)) //To get a TAN, I did a bad SIN. This makes sure it can only go wrong 100 times. set to (y position) set to //Sometimes things go wrong. set to (x position) //Where the sprite was. set to (YT) set to (direction) broadcast end end when I receive //Put this script in a custom block with screen refresh off. Just make sure you do the same for the others. if then //You can use touching colour here if you like. Don't make it too high though, or it starts to glitch a bit. when (time starts v) forever move (YT) steps //number of steps is anything you want. Press “quote” at the bottom, then press the green tick (the preview button) to see the entire thing. Try it out!Doesn't work on vertical walls This is my answer. the missile is traveling in direction 20 degrees it would turn to 160 degrees. When Flag clicked Forever If Touching colour ( border Colour ) Point in direction 180 - Direction Basically 180 will be subtracted by the direction that the missile is going in. ![]() Maxhup010 wrote:This is my script for my wall bounce game! The same principles, but you would need a border around your battlefield. I can't believe you were able to do all that but get stuck on bouncing a bullet. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |