Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

Thread Tools Display Modes
Cross Hairs
Posts: n/a
Default Cross Hairs - 12-13-2009, 11:16 AM

How do I create and use a cross hair for a shoot em game? Also, how do I keep camera moving with the cross hair movement?
Reply With Quote
Senior Member
Dameria's Avatar
Status: Offline
Posts: 978
Join Date: Sep 2009
Location: United States
Default 12-13-2009, 11:21 AM

Well you can create a cross-hair by using the objects in the objects folder, like a torus for the circle and cylinders for lines, and you can make them cylinders vehicle to the torus in the properties part of the objects. Then to make it follow the camera you make the torus vehicle to the camera.

You would have to either create a lot of cyliners, or make a method that resizes the cylinders by whatever you want them to, dimensions left to right.

EDIT: Here's an example of what I am talking about. I even put in let arrow keys move camera, so you can see as the camera moves the crosshair stays in the same place. Sorry if the ring of the crosshair is a little fat.
Attached Files
File Type: a2w CrosshairExample.a2w (179.9 KB, 64 views)

Check out my best projects so far and please comment:

Tic-Tac-Toe 2.0 ...................
Alice Paint ...........................
Real-Time Clock ..................
Maze Game .........................

Last edited by Dameria; 12-13-2009 at 11:44 AM.
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Copyright ©2018, Carnegie Mellon University
Alice 2.x 1999-2012, Alice 3.x 2008-2012, Carnegie Mellon University. All rights reserved.