Reverse up-down control when looking astern?

An area for discussing new ideas and additions to Oolite.

Moderators: winston, another_commander

cag
Dangerous
Dangerous
Posts: 84
Joined: Fri Mar 17, 2017 1:49 am

Re: Reverse up-down control when looking astern?

Post by cag » Mon Oct 23, 2017 11:34 pm

hoqllnq wrote:
Sun Oct 22, 2017 10:25 pm
I don't think you can remap what controls do on the fly.
No but it would open up some possibilities. But for this, all I need is to dectect them. I suppose I could monitor the delta V in each axis frame to frame to infer it ...
hoqllnq wrote:
Sun Oct 22, 2017 10:25 pm
Now, if ship.pitch and ship.roll were writable, then you could flip the motion on view change (i.e. ps.roll = -ps.roll; for aft view, ps.roll = ps.pitch; for left, ps.roll = -ps.pitch; for right, etc.. ) so that the combined effect would be that the ship keeps rotating in the same direction, but they aren't, according to the wiki.
They're not writable, I just tried - it would simplify things immensely. But as you saw, he's inverting the angular motion each frame, so it's doable, except for the previous point. I'll let this roll around my attic for a while and see if I get hit w/ an 'ahaa!' moment.
"Better to be thought a fool, boy, than to open your trap and remove all doubt." - Grandma [over time, just "Shut your trap... fool"]
"The only stupid questions are the ones you fail to ask." - Dad
How do I...? Nevermind.

User avatar
hoqllnq
Commodore
Commodore
Posts: 154
Joined: Sun Jan 08, 2006 7:32 pm

Re: Reverse up-down control when looking astern?

Post by hoqllnq » Sun Oct 29, 2017 6:32 pm

Diziet Sma wrote:
Mon Oct 23, 2017 6:05 am
You can always submit a request that they be made writable..
This is in todays nightly.

cag
Dangerous
Dangerous
Posts: 84
Joined: Fri Mar 17, 2017 1:49 am

Re: Reverse up-down control when looking astern?

Post by cag » Wed Jul 04, 2018 3:04 am

hoqllnq wrote:
Sun Oct 22, 2017 1:03 pm
There is something about the reverse control thing that doesn't feel right..
(I play on keyboard. I guess this is not really an issue when using a joystick?)

When you dive/climb or rotate (diving/climbing is really also rotating) and then let go of the keys, you don't stop rotating immediately.
This is actually a good thing. It would be horrible if it would. It is really 'control damping' but it _feels_ like momentum.

If you switch view while the controls are still on their way back to neutral, you immediately and abruptly start rotating in the opposite direction.
Now I guess this is technically correct, since it is control damping and not momentum, but it feels unnatural. It feels like it is reverse physics instead of reverse control.
If you want 'horrible', try holding down a key and press its opposite one. :shock: Same thing if you immediately switch to the opposite direction: no momentum.

The game treats joysticks differently than keyboard controls; the time it takes you to physically move the stick from one limit to the other gives it time to slow down and move in the opposite direction. For keyboards, it just sets your rate to zero!

Also, the damping times differ. If you let go of the stick when it's at max, it takes about 0.5 sec to stop - this time is equal for all axes. But on a keyboard, the damping time is about 1 sec for pitch & yaw and 2 sec for roll (actually, it's whatever your ship.max<Axis> value is). So the 'reverse physics' is more apparent.

I've added a new component, inertia, which I think is what you're looking for. Give it a try and let me know what you think.

https://www.dropbox.com/s/4609bj3d2btwz ... l.oxz?dl=0

You can toggle both reverse control & inertia using 'Config for AddOns' on the F4 screen. They operate independently, so there are 4 possible configurations.

The inertia feature is meant for keyboard controls and (probably ...) won't affect joysticks, so those players should probably turn if off (for a tiny performance gain).
hoqllnq wrote:
Sun Oct 22, 2017 10:25 pm
I don't think you can remap what controls do on the fly. When I look left or right, my roll controls make the ship pitch, but they still move the roll indicator in the same direction. That is what you would really want: Have the same key/control move the pitch/roll indicators in the opposite direction, or have the same control move the other indicator.
I've never done any work on a HUD. Does anyone know if the pitch/roll indicators are HUD specific? It would be nice if they reflected the change in controls but it's not something I'd want to invest a lot of time in.
"Better to be thought a fool, boy, than to open your trap and remove all doubt." - Grandma [over time, just "Shut your trap... fool"]
"The only stupid questions are the ones you fail to ask." - Dad
How do I...? Nevermind.

User avatar
Norby
---- E L I T E ----
---- E L I T E ----
Posts: 2542
Joined: Mon May 20, 2013 9:53 pm
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
Contact:

Re: Reverse up-down control when looking astern?

Post by Norby » Wed Jul 04, 2018 7:27 am

Inertia is working well so I uploaded it as ReverseControl v1.7. Thank you cag!

Algernon
Mostly Harmless
Mostly Harmless
Posts: 2
Joined: Tue Jul 17, 2018 7:49 pm

Re: Reverse up-down control when looking astern?

Post by Algernon » Tue Jul 17, 2018 8:03 pm

I just updated from V1.6 to V1.7 and it no longer works: pitch is not reversed and left and right roll controls both cause roll in the same direction in aft view (Oolite V1.86)

User avatar
Norby
---- E L I T E ----
---- E L I T E ----
Posts: 2542
Joined: Mon May 20, 2013 9:53 pm
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
Contact:

Re: Reverse up-down control when looking astern?

Post by Norby » Tue Jul 17, 2018 9:53 pm

Welcome Algernon!

I tested in trunk (aka Oolite 1.87) where it is working well, but now I checked in 1.86 where I got the same problems as you.

So now I uploaded ReverseControl_1.6.oxz also and renamed v1.7 to "Reverse control with inertia".

If you want the new inertia feature then you must use trunk version of Oolite, otherwise please remove the v1.7 then install back the v1.6 in the manager.

User avatar
phkb
Commodore
Commodore
Posts: 2313
Joined: Tue Jan 21, 2014 10:37 pm
Location: [p]laying [h]ard and [k]icking [b]utt somewhere in G7...

Re: Reverse up-down control when looking astern?

Post by phkb » Tue Jul 17, 2018 9:57 pm

Welcome to the boards, Algernon.

(Irrelevant side note) Whenever I see the name "Algernon" I'm always reminded of "Biggles", who had a side-kick with that name. :D

User avatar
Cody
Sharp Shooter Spam Assassin
Sharp Shooter Spam Assassin
Posts: 13567
Joined: Sat Jul 04, 2009 9:31 pm
Location: Corke's Drift
Contact:

Re: Reverse up-down control when looking astern?

Post by Cody » Tue Jul 17, 2018 11:09 pm

phkb wrote:
Tue Jul 17, 2018 9:57 pm
Whenever I see the name "Algernon" I'm always reminded of "Biggles", who had a side-kick with that name.
With me, it's Algernon Blackwood, author of many a ghostly tale.

User avatar
Disembodied
Jedi Spam Assassin
Jedi Spam Assassin
Posts: 6227
Joined: Thu Jul 12, 2007 10:54 pm
Location: Carter's Snort

Re: Reverse up-down control when looking astern?

Post by Disembodied » Wed Jul 18, 2018 8:39 am

For me, it's the mouse with enhanced intelligence from Daniel Keyes' "Flowers for Algernon". It's a name with a fine literary pedigree!

cag
Dangerous
Dangerous
Posts: 84
Joined: Fri Mar 17, 2017 1:49 am

Re: Reverse up-down control when looking astern?

Post by cag » Thu Jul 19, 2018 4:34 am

I've updated it to be version aware (d'Oh)

IF it checks out, you won't have to continue with 2 versions ...

https://www.dropbox.com/s/4609bj3d2btwz ... l.oxz?dl=0
"Better to be thought a fool, boy, than to open your trap and remove all doubt." - Grandma [over time, just "Shut your trap... fool"]
"The only stupid questions are the ones you fail to ask." - Dad
How do I...? Nevermind.

User avatar
Norby
---- E L I T E ----
---- E L I T E ----
Posts: 2542
Joined: Mon May 20, 2013 9:53 pm
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
Contact:

Re: Reverse up-down control when looking astern?

Post by Norby » Thu Jul 19, 2018 4:35 pm

Thank you cag, now the fixed Reverse control with inertia v1.8 is available.

Algernon
Mostly Harmless
Mostly Harmless
Posts: 2
Joined: Tue Jul 17, 2018 7:49 pm

Re: Reverse up-down control when looking astern?

Post by Algernon » Fri Jul 20, 2018 4:51 pm

Thanks for the responses. How about Algernon Moncrieff?

User avatar
Cody
Sharp Shooter Spam Assassin
Sharp Shooter Spam Assassin
Posts: 13567
Joined: Sat Jul 04, 2009 9:31 pm
Location: Corke's Drift
Contact:

Re: Reverse up-down control when looking astern?

Post by Cody » Fri Jul 20, 2018 5:24 pm

<grins> As Big D said, it's a name with a fine literary pedigree.

Post Reply