About a Sniper Game

3 posts

Flag Post

I have two questions that I cant seem to find the answer to. My first one seems like it would be simple but i dont know i cant find it. It is can i make it so when my character (using the arrow keys) scrolls off the frame, can i make it so it automatically goes to a certain frame?
My other question is how to set-up the actual shooting part. I want it to be like as if your looking through the scope and that with the mouse is how you move the scope, but i dont know how.

 
Flag Post

Moving offscreen:

if player.x is greater than stage width
and player.y is greater than stage height
do whatever

Scope following mouse

scope = shape or movieclip (circle with crosshairs most likely)
on every frame
    scope.x = mouse.x
    scope.y = mouse.y
 
Flag Post

Ok you didnt give me the whole code snippet for the scope you have to you use code snippets from Flash to make a custom mouse cursor and thats what i did. but how to make the moving offscreen one to work.