Alice Community  

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

Reply
 
Thread Tools Display Modes
make the camera point at the mouse
Old
axeraider131
Guest
 
Status:
Posts: n/a
Talking make the camera point at the mouse - 02-04-2007, 05:51 PM

I am wondering if it is possible to make the camera follow the mouse without having to click. like in first person shooters. if anybody could tell me if this is possible or how to do it, any help would be greatly appreciated

-----------------------------------
Axeraider 131
<[}{]>
---------
+++++
   
Reply With Quote
Best I could come up with.
Old
DrJim
Guest
 
Status:
Posts: n/a
Arrow Best I could come up with. - 02-04-2007, 06:13 PM

See: http://www.alice.org/community/showt...ighlight=mouse

Maybe you can come up with something better.

(You could, of course, have the camera's point of view set to an invisible object that in turn follows the shooter instead of trying to follow the mouse.)
   
Reply With Quote
Ding! An idea, watson!
Old
Shadow Sovereign
Guest
 
Status:
Posts: n/a
Lightbulb Ding! An idea, watson! - 02-05-2007, 09:53 AM

There is an Example (assuming you installed alice with the CD) where a biplane flies thru several rings and wins a 6-pack of what seems to be Heineken's bastard cousin... I recall the camera steadily following the plane, so you may wish to look into that.

A link is below for those of you without CDs.
Attached Files
File Type: a2w flightSimulator.a2w (635.1 KB, 356 views)
   
Reply With Quote
Old
PogoDaMonkey
Guest
 
Status:
Posts: n/a
Unhappy 02-05-2007, 12:42 PM

Er...Shadow...he means to have the mouse follow the camera, not an object. Like if the mouse moves left, the camera moves with it, left mouse button shoots, kind of like Doom or something, minus the keyboard. Havent figured out how to do this, and I don't think its possible in Alice 2.0, but if i figure something out, I'll tell you.
   
Reply With Quote
^.^
Old
axeraider131
Guest
 
Status:
Posts: n/a
Talking ^.^ - 02-05-2007, 08:41 PM

yeah that is wat i meant. but thanks guys for trying to help.
   
Reply With Quote
Actually it probably can be done.
Old
DrJim
Guest
 
Status:
Posts: n/a
Cool Actually it probably can be done. - 02-06-2007, 11:24 AM

What axeraider131 wants probably actually can be done - but I wonder if it's worth the effort.

Take a look at the attached. It's very similar to the program I did earlier but I've set the camera's vehicle and point of view to the sphere that the mouse is moving through the scene. I also very haphazardly put a little scenery in the world so you can see the mouse really is controling the camera's view without having to click a mouse button - so the button is free for "fire control".

The camera response is slow in this case, but that could easily be fixed by making the spere move faster. To make this useful for a game, however, one would have to figure out where to place the reference targets that the sphere moves towards and maybe even change to another target if the sphere had moved close to a specific target. This is where I stopped with the idea the first time I tried since I didn't have any specific goal in mind.

The key point I want to make is that you can use the mouse position functions alone to control camera position. Can this be useful - ???
Attached Files
File Type: a2w CameraFollowMouse.a2w (427.7 KB, 434 views)
   
Reply With Quote
Ooookay...
Old
Shadow Sovereign
Guest
 
Status:
Posts: n/a
Question Ooookay... - 02-09-2007, 07:46 AM

Quote:
Originally Posted by PogoDaMonkey View Post
Er...Shadow...he means to have the mouse follow the camera, not an object. Like if the mouse moves left, the camera moves with it, left mouse button shoots, kind of like Doom or something, minus the keyboard. Havent figured out how to do this, and I don't think its possible in Alice 2.0, but if i figure something out, I'll tell you.
....whoops. I guess I didn't quite understand the question before.

Well, I do have another suggestion, but before I say it again, have you tried using the event handler in the top-right corner to use the mouse to control the camera?
Attached Images
File Type: jpg Example with events.JPG (14.2 KB, 425 views)
   
Reply With Quote
Old
tmorgan1689
Guest
 
Status:
Posts: n/a
Default 02-09-2007, 02:01 PM

I think he wants it to automatically follow the camera, like if he moves the mouse to the left the camera goes to the left. Is there a way to do it with the position of the camera? I'm just throwing out some ideas because i've never tried it.
   
Reply With Quote
Reply

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 ©2023, Carnegie Mellon University
Alice 2.x © 1999-2012, Alice 3.x © 2008-2012, Carnegie Mellon University. All rights reserved.