2 registered members (Ayumi, kzhao),
1,354
guests, and 5
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: Isometric camera - need some help!
[Re: DrGonzo]
#173842
12/22/07 13:07
12/22/07 13:07
|
Joined: Aug 2005
Posts: 1,558 HK
vlau
Serious User
|
Serious User
Joined: Aug 2005
Posts: 1,558
HK
|
Hey, don't be angry, isn't that you've already write the code above (post #807081)? and I've modified your code above too. All you need is just do some modifications. Code:
if (mouse_right == 1) { camera.y += mouse_force.x * 40 * time_step; camera.z += mouse_force.y * 40 * time_step; }
if (mouse_right==1 && key_alt) { camera.pan += mouse_force.x * 20 * time_step;// mouse movement changes PAN camera.tilt += mouse_force.y * 20 * time_step;// mouse movement changes TILT }
That's it!
|
|
|
Re: Isometric camera - need some help!
[Re: vlau]
#173843
12/22/07 14:18
12/22/07 14:18
|
Joined: May 2007
Posts: 34 California
DrGonzo
OP
Newbie
|
OP
Newbie
Joined: May 2007
Posts: 34
California
|
Quote:
Hey, don't be angry...
Vlau, I'm not angry with you at all! In fact, you're the only one in this great & helpful community who offered me some help so far.
I just got very frustrated because I can't get this camera movement to work and nobody here is helping me out besides you. Your original code just doesn't work for me. I pasted it into a script and got very strange camera movements when I ran it.
If you're still interested in helping me out, please write a script that controls the camera just like it's being controlled in WED's 3D view and make sure that you test it out before posting it. I would very much appreciate that!
|
|
|
Re: Isometric camera - need some help!
[Re: vlau]
#173845
12/22/07 22:14
12/22/07 22:14
|
Joined: May 2007
Posts: 34 California
DrGonzo
OP
Newbie
|
OP
Newbie
Joined: May 2007
Posts: 34
California
|
Thanks vlau, that's a good idea. Find my test level hereI included a snapshot that shows you how the level looks like when it's first started. At least on my system. Since you tested your code out, maybe you could post your level so that I can try it out? Thanks for your help!
|
|
|
Re: Isometric camera - need some help!
[Re: DrGonzo]
#173846
12/23/07 01:31
12/23/07 01:31
|
Joined: May 2007
Posts: 34 California
DrGonzo
OP
Newbie
|
OP
Newbie
Joined: May 2007
Posts: 34
California
|
Ok, after doing some more research, I came across this script from Orange Bratt: hereThe script does almost exactly what I'm looking for. I would just have to revise some of the camera controls (WASD should be mouse movement + right MB, rotation should be mouse movement + middle MB). The script is pretty big though, and I was wondering if there was a shorter way to achieve this kind of camera movement?
|
|
|
Re: Isometric camera - need some help!
[Re: DrGonzo]
#173847
12/24/07 10:37
12/24/07 10:37
|
Joined: Aug 2005
Posts: 1,558 HK
vlau
Serious User
|
Serious User
Joined: Aug 2005
Posts: 1,558
HK
|
I see what problem with my previous code, now I have rewrite the whole script and added 2 dummys in the level, you may download it from here : cam_test_new.zip If there is no response, you may need to sign up first : http://www.filefront.com/If you like the code from OB, you may contact him directly.
|
|
|
Re: Isometric camera - need some help! [solved]
[Re: vlau]
#173848
12/25/07 03:29
12/25/07 03:29
|
Joined: May 2007
Posts: 34 California
DrGonzo
OP
Newbie
|
OP
Newbie
Joined: May 2007
Posts: 34
California
|
Quote:
I see what problem with my previous code, now I have rewrite the whole script and added 2 dummys in the level...
Thanks vlau, that's pretty good code!
I too have been rewriting my code, using a dummy entity as a camera guide this time, just like you and OB did. I'm very pleased with the code so far, as it does exactly what I wanted it to do.
Thanks for all your help and merry Xmas!
|
|
|
Moderated by mk_1, Perro, rayp, Realspawn, Rei_Ayanami, rvL_eXile, Spirit, Superku, Tobias, TSG_Torsten, VeT
|