0.3 glancing mod
0.3 glancing mod
Hey,
I know there is a branch with old 0.2.8 camera glancing but i wanted to keep the 0.3 code and just mod it a bit to make glancing more usable.
https://code.launchpad.net/~clime7/arma ... edGlancing
Two things are changed. Glancing is relative to cycle direction, so if you tap glance back twice fast, you won't end up looking right or left, etc. And mainly, returning from glance is implemented as forward glance, which unifies movement there and back. That means returning from glance is influenced by all glance settings, particularly camera_glance_angular_velocity.
The original glancing is still available though. camera_glance_return 0 enables it. Setting this parameter to positive number gives my mod, which is also default.
There seem to be two minor bugs in the original code that remain in my branch too. Both exhibit if you press/hold glance key before start of a round. Camera then does not align correctly immediatelly. In one case it stays in a grid corner, in the second case it aligns but with rise = 0. Mainly with custom cam it occrus. The first case is division by zero but I haven't found a cause of the second (and i really think there are two different causes). Holding glance (and continue holding with the original glancing) while pressing enter on Local Game is the easiest way to reproduce the first one. But it is not so important matter i suppose. Ye, and I haven't found a right way to fix these things so far.
The branch also contains all the fixes that are needed for build on Windows.
I know there is a branch with old 0.2.8 camera glancing but i wanted to keep the 0.3 code and just mod it a bit to make glancing more usable.
https://code.launchpad.net/~clime7/arma ... edGlancing
Two things are changed. Glancing is relative to cycle direction, so if you tap glance back twice fast, you won't end up looking right or left, etc. And mainly, returning from glance is implemented as forward glance, which unifies movement there and back. That means returning from glance is influenced by all glance settings, particularly camera_glance_angular_velocity.
The original glancing is still available though. camera_glance_return 0 enables it. Setting this parameter to positive number gives my mod, which is also default.
There seem to be two minor bugs in the original code that remain in my branch too. Both exhibit if you press/hold glance key before start of a round. Camera then does not align correctly immediatelly. In one case it stays in a grid corner, in the second case it aligns but with rise = 0. Mainly with custom cam it occrus. The first case is division by zero but I haven't found a cause of the second (and i really think there are two different causes). Holding glance (and continue holding with the original glancing) while pressing enter on Local Game is the easiest way to reproduce the first one. But it is not so important matter i suppose. Ye, and I haven't found a right way to fix these things so far.
The branch also contains all the fixes that are needed for build on Windows.
- Lackadaisical
- Shutout Match Winner
- Posts: 823
- Joined: Sun Dec 21, 2003 4:58 pm
- Location: Amsterdam, Netherlands
- Contact:
Re: 0.3 glancing mod
Good stuff! The fact that the turning back of the camera after glancing was determined by custom_camera_turn_speed has always bothered me a bit.
Official Officiant of the Official Armagetron Clan Registration Office
Back (in the sig) by popular demand: Lack draws
Back (in the sig) by popular demand: Lack draws
Re: 0.3 glancing mod
Do you have a clean diff of your changes? I'm not sure how you got this massive diff, unless you completely rewrote eCamera.{h,cpp}…
Aside from that, your changes sound good.
Aside from that, your changes sound good.
Last edited by dlh on Wed Jul 06, 2011 10:04 am, edited 1 time in total.
Re: 0.3 glancing mod
Yeah, definitely good changes. The massive diff may come from line end code differences, he's on Windows and bzr isn't too good with them, last I read.
Re: 0.3 glancing mod
Thx, just one more thing...glancing direction in my mod is relative to the cycle direction !at the time the glance key was pressed!. So cycle turns does not turn camera when glance key is down. Idk if it is good or bad, I don't mind it. Please, tell me if it is a problem. Diffs are in attachment, i'll try to make code::blocks to use LF or i'll get some converter. Sry for that.
- Attachments
-
- eCamerah-diff.txt
- (375 Bytes) Downloaded 246 times
-
- eCameracpp-diff.txt
- (4.03 KiB) Downloaded 242 times
Re: 0.3 glancing mod
Tested it: it's neat and an elegant way to get a bit of the old glancing back. I'll commit it, if I may, with one small change: with smartcam enabled, if you release a glance key, it'll first do the movements as if you were glancing forward (because that's what it really is doing, and it's a good thing for the other camera modes since the only difference between the regular and glance motions there is the speed) and only return control to the smartcam after that glance turn is practically complete. This gives an irritating change of camera motion. I'll try to remedy that. Easiest way would be to only switch back to the regular camera on the next turn.
Keeping the camera looking in one direction is fine; I guess this is the change from 0.2.8 glance nobody disagreed with.
Keeping the camera looking in one direction is fine; I guess this is the change from 0.2.8 glance nobody disagreed with.
Re: 0.3 glancing mod
Done. I also fixed at least one of the initialization bugs, possibly the other as well, I could not reproduce it. And by default, glancing back now snaps the view again and does not slowly turn the camera.
FAQ:
Q: You changed it! It sucks now!
A: You can back to the behavior before this commit by following instructions in settings_visual.cfg.
Q: It's still not completely like in 0.2.8!
A: Yep. IMHO, it's better.
Q: No, it's not! It sucks! Change it back!
A: None of those were questions, and no, it's not feasible to keep both codes coexisting. However, if you have a concrete feature you feel is missing now (like the glancing stopping on turns), we can emulate it no problem.
Q: Wasn't meriton against such changes?
A: I can't remember, really. He hasn't been around for some years, however, and submitted his work under the GPL. The choice was to make those changes or discard his work and start over.
FAQ:
Q: You changed it! It sucks now!
A: You can back to the behavior before this commit by following instructions in settings_visual.cfg.
Q: It's still not completely like in 0.2.8!
A: Yep. IMHO, it's better.
Q: No, it's not! It sucks! Change it back!
A: None of those were questions, and no, it's not feasible to keep both codes coexisting. However, if you have a concrete feature you feel is missing now (like the glancing stopping on turns), we can emulate it no problem.
Q: Wasn't meriton against such changes?
A: I can't remember, really. He hasn't been around for some years, however, and submitted his work under the GPL. The choice was to make those changes or discard his work and start over.
Re: 0.3 glancing mod
That was hilarious z-man! Thanks, you cheered me up!
Re: 0.3 glancing mod
A few years back I used the armagetronad-old-glancing branch which was updated by dlh.
I assume this is the way to go now? Is it both in 0.4 and trunk?
I assume this is the way to go now? Is it both in 0.4 and trunk?
Winner of the How Many Pages Before The Lock® competition and a grand total of 18,93 euros in Euromillions.
Re: 0.3 glancing mod
this seems like a solution no one needs. If it works for you though thanks for giving back.
Re: 0.3 glancing mod
I was never able to figure out how to get 0.2x glances in 0.4x. I looked through settings_visual.cfg but nothing I changed seem to make a difference. Can someone explain to me what setting(s) needs to be changed?