I patched telescope to add collision exceptions between the telescope markers and the player ship, so now my torus speed factor can get above 32x.
After that I've several episodes of my movement direction reversing while torusing at high speeds: I'm still looking forward, but the forward direction is my previous aft direction. Most times, it happens as I'm decanted from Torus by someone just spawned ahead of me by Deep Space Pirates or Space Crowds, but it also happens withou being decanted from Torus.
Assuming that's an OXP problem, is there any way for a script to change the ship's movement direction other than modifying ship.orientation?
Investigating movement direction reversing while in Torus
Moderators: winston, another_commander, Getafix
Re: Investigating movement direction reversing while in Torus
Put a trace on OOJSEntity.m for when the player ship' orientation is modified, and it looks like the culprit is SniperLock.
- Cholmondely
- Archivist
- Posts: 5364
- Joined: Tue Jul 07, 2020 11:00 am
- Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
- Contact:
Re: Investigating movement direction reversing while in Torus
I've had the identical issue. Also with telescope and sniperlock loaded along with a zillion other oxz's.
Comments wanted:
•Missing OXPs? What do you think is missing?
•Lore: The economics of ship building How many built for Aronar?
•Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
•Missing OXPs? What do you think is missing?
•Lore: The economics of ship building How many built for Aronar?
•Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
Re: Investigating movement direction reversing while in Torus
It looks as if torusing with SniperLock not locked (i.e. not allowing SniperLock to steer the ship to keep on target by keeping the corsshairs slightly off the target) avoids the issue - it's a good enough work-around until I really find out what's happening and find a fix - but if the trouble really is in SniperLock code, we have a license problem: it's CC BY-NC-SA 3.0 with the "Thargoid clauses" and unless CommonSenseOTB has publicly waived the clauses away, as Thargoid himself did, it can't be directly updated - we might have to do something like montana05 is doing with Shipbuilder's ships OXPs and override a function.
Re: Investigating movement direction reversing while in Torus
I think I understand the problem.
When the direction reversal happens, the player is targetting a farway object through Telescope... that's what it looks to the player, but in reality the player ship's target is the telescope marker at the border of the scanner range, aligned between the player ship and the "real" target.
That telescope marker is being moved forward at each frame, repositioned based on the player ship's position at the time the telescope FCB is called (this is a conjecture, I didn't look at the Telescope code to validate it)
But as the torus speed increases, the distance the player ship covers in the small time interval between the telescope and sniperlock FCBs being called increases too, until it's greater than the scanner range and the telescope marker that sniperlock is aiming at is behind the ship and we get a direction reversal.
I think the simpler solution would be for sniperlock to refuse locking on telescope markers, at least while in Torus (so we can still snipe beyond scanner range...)
When the direction reversal happens, the player is targetting a farway object through Telescope... that's what it looks to the player, but in reality the player ship's target is the telescope marker at the border of the scanner range, aligned between the player ship and the "real" target.
That telescope marker is being moved forward at each frame, repositioned based on the player ship's position at the time the telescope FCB is called (this is a conjecture, I didn't look at the Telescope code to validate it)
But as the torus speed increases, the distance the player ship covers in the small time interval between the telescope and sniperlock FCBs being called increases too, until it's greater than the scanner range and the telescope marker that sniperlock is aiming at is behind the ship and we get a direction reversal.
I think the simpler solution would be for sniperlock to refuse locking on telescope markers, at least while in Torus (so we can still snipe beyond scanner range...)
- montana05
- ---- E L I T E ----
- Posts: 1166
- Joined: Mon May 30, 2016 3:54 am
- Location: lurking in The Devils Triangle (G1)
Re: Investigating movement direction reversing while in Torus
If you need my key please let me know, at least for Windows I could override nearly everything.
Scars remind us where we've been. They don't have to dictate where we're going.
Re: Investigating movement direction reversing while in Torus
SniperLock_Fix 1.0 fixes this issue and is available on the Expansion Manager and here.