I am making a carnival game involving a coin shooter and a coin. What I want to know is, How can I make the coin point at the mouse pointer at the same time as the coin shooter? Then I need it to stop when it leaves the coin shooter (How do I get the coin shooter to stop facing as well?) And also point again when it goes back into the shooter in the same game (not pressing the green flag). How can I get all of these to work?
Thanks,
DoowNimajneb
Offline
Put this script on your coin sprite:
when gf clicked forever if <touching [shooter v] ?> point towards [mouse-pointer v] end if <not <touching [shooter v] ?> > repeat until <touching [target v] ?> //change to name of target sprite move (10) steps //change this amount to the travel speed you want end go to [shooter v] end endAnd then add this to your shooter sprite:
when gf clicked forever if <touching [coin v] ?> point towards [mouse-pointer v] end if <not <touching [coin v] ?> > change x by (0) change y by (0) end endThen the whole thing should work fine.
Last edited by SOScratch (2012-07-01 10:16:36)
Offline
In answer to SOSscratch's question, yes, I am shooting at multiple targets.
Offline