Alice Community  

Go Back   Alice Community > Alice 2 > Share Worlds

Reply
 
Thread Tools Display Modes
New Mouse Look Code!-FirstPerson
Old
Ch0pStickS
Guest
 
Status:
Posts: n/a
Default New Mouse Look Code!-FirstPerson - 11-21-2008, 10:58 PM

Hey guys, I have almost a year ago stopped using Alice, but when I was working with other programs, I figured out a way to make a mouse-look code the way i wanted to. I previously created one before, but it was less-sophisticated, less-user-friendly, and less-organized. To see it Look at this previous post.
http://www.alice.org/community/showthread.php?t=1305

Instructions:
W- move forward
A- move left
S- move backward
D- move right

hold enter and click on the crossfire to calibrate screen.

Look by using the mouse.

Also, this works best by enlarging the screen. Note that you cannot look using the mouse until you calibrate it.

I may/will add more functionality to it, including sensitivity, less-lagginess, and so forth, and produce another version within a week after thanksgiving weekend.

Helpful suggestions/criticism/comments/questions welcomed.

Attached below is the world.
Attached Files
File Type: a2w FirstPersonScroll.a2w (483.0 KB, 550 views)
   
Reply With Quote
Old
x2495iiii
Super Moderator
 
x2495iiii's Avatar
 
Status: Offline
Posts: 3,508
Join Date: Dec 2008
Location: Somewhere in the Continental U.S.
Default 12-02-2008, 09:42 PM

is there any way to get the mouse to act as a sort of rollover indicator, like having an object glow when the cursor is over it?
   
Reply With Quote
Old
Ch0pStickS
Guest
 
Status:
Posts: n/a
Default 12-03-2008, 03:42 PM

Well, if you are making a static menu, then yes. You could have it set so that if the mouse distance from left edge and mouse distance from top edge is between 50 and 100, then you could have the object that is in that area glow. Shouldn't be too hard if you think about it long enough. Ask me if you want a demo.
   
Reply With Quote
Old
smithno13
Guest
 
Status:
Posts: n/a
Default 12-05-2008, 04:20 PM

So if I wanted to use this in an alice program, how would I import it? Or would I have to build my program around it?
   
Reply With Quote
Old
Ch0pStickS
Guest
 
Status:
Posts: n/a
Default 12-05-2008, 11:34 PM

Well, actualy, the code isn't that long, so you could try to recreate it onto your file. you could also build around it if you wish. Or, im willing to put it in your project myself, if need be. Just ask, it shouldn't be hard for me at all, maybe like 5-20 minutes, depending on the current size of your world.
   
Reply With Quote
Old
smithno13
Guest
 
Status:
Posts: n/a
Default 12-06-2008, 11:14 AM

Quote:
Originally Posted by Ch0pStickS View Post
Well, actualy, the code isn't that long, so you could try to recreate it onto your file. you could also build around it if you wish. Or, im willing to put it in your project myself, if need be. Just ask, it shouldn't be hard for me at all, maybe like 5-20 minutes, depending on the current size of your world.
My world currently is nothing - I am just in the planning process for a school project, a shooting range. What I am really wanting is a way to limit an object to a 2d plane (up, down, left, right) so you could just click and drag the crosshair to aim. Unfortunately, the default "Let mouse move object" moves it on a horizontal plane, parallel with the ground.
   
Reply With Quote
Old
Ch0pStickS
Guest
 
Status:
Posts: n/a
Default 12-08-2008, 08:57 AM

it would pretty much be like this world, but instead of rotating the camera, it would just move the cursor, which i could make if you wanted.
   
Reply With Quote
Old
Ch0pStickS
Guest
 
Status:
Posts: n/a
Default 12-08-2008, 08:41 PM

actually about what that x2 guy said, you could actually just have a line of dots coming out from the camera, and set it so that if an object is touching that line, then it would do something. Picture a set of dots in your vision that go off to infinity, kind of like that.
   
Reply With Quote
Old
b00kworm
Guest
 
Status:
Posts: n/a
Default 12-30-2008, 04:39 PM

Smithno, I got it -turn the world sideways! At the beginning of your program, have some code that sets everything's vehicle to camera, rolls the camera 90 degrees, and sets everything back to their normal vehicles. One problem - lighting gets messed up since you can't set "light"'s vehicle. Just put in some lightbulbs and turn on the secular highlighting of the crosshairs.
   
Reply With Quote
or
Old
rich0e0rick
Senior Member
 
rich0e0rick's Avatar
 
Status: Offline
Posts: 141
Join Date: Jan 2008
Location: Sturgeon Falls
Talking or - 12-30-2008, 06:33 PM

or make a object, then make it so its at the same place as the light, then vehicle it to the camera, then turn the camera, and move the light to the object you made!

....

and by the way, you can vehicle the light, its under the SELDOM USED PROPERTIES


im back!!! FINNALY!!! got windows working on my mac again!!!

Last edited by rich0e0rick; 12-30-2008 at 06:36 PM.
   
Reply With Quote
Reply


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