Hard Light Productions Forums
Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: Goober5000 on December 07, 2013, 05:14:09 pm
-
I needed a ship to slow down rapidly after emerging from subspace. After trying a number of sexps without success, I ended up making a duplicate ship class with the "supercap" flag. This slows the ship down satisfactorily, but is obviously not an ideal solution.
Then I ran across this interesting quote in Battuta's mission checkpoint tutorial...
Immediately kill the ship's entry momentum with a SEXP (this is glitchy and requires some work)
Anyone know which sexp he is describing? I would PM him myself but he's currently on leave from HLP.
-
would either of these table entries help?
http://www.hard-light.net/wiki/index.php/Ships.tbl#.24Warpin_Speed:
$Warpin Speed:
FS2 Open 3.6.10:
Sets the speed at which the ship warps in for default warpin effect
Sets the time that the ships warp in (not the animation itself) takes for BTRL type warpin effects
Syntax: Float, meters per second or miiliseconds
$Warpin Time:
FS2 Open 3.6.10:
Defines the effect duration
Syntax: Float, seconds
edit
alternatively you could use the supercap warpin and then sexp to switch the ship class to the regular version
-
would either of these table entries help?
http://www.hard-light.net/wiki/index.php/Ships.tbl#.24Warpin_Speed:
$Warpin Speed:
FS2 Open 3.6.10:
Sets the speed at which the ship warps in for default warpin effect
Sets the time that the ships warp in (not the animation itself) takes for BTRL type warpin effects
Syntax: Float, meters per second or miiliseconds
$Warpin Time:
FS2 Open 3.6.10:
Defines the effect duration
Syntax: Float, seconds
No, unfortunately. That was the first thing I tried, but those only work for BTRL and Hyperspace warp effects, not the FS2 warp effect.
alternatively you could use the supercap warpin and then sexp to switch the ship class to the regular version
That's what I did.
-
drat. ok, no idea then
-
Funnily enough I was discussing this issue yesterday. The WCS release has a SEXP called set-forward-deceleration which apparently they used for exactly this reason. I thought the SEXP was rather useless outside the WCS universe cause these features really should be part of the warpin code rather than requiring a SEXP.
That said, couldn't you simply set the speed of the ship with SEXPs? Or does it retain the original deceleration values?
-
I forget what I used exactly, but I'm pretty sure I tried a repeating set-speed approach and didn't like it. You're right in that the best solution would be an enhancement of the warpin code, but I was wearing my FREDding hat and didn't care to code it.
-
Or maybe make a loop triggered by the ships arrival, decreasing its speed by 1 each 5 milisecs? That would give you decceleration of about 200 m/s each second...
-
Shouldn't there be made a way to customize warp arrival anyways? Different FTL methods will be different. I mean so that current FS1/2 (are they different? then we could make FSPort more original if they were) is emulated by default, but different distance traveled and time to travel can be specified? IDK, just thoughts.
-
Did you try to use 0 as initial velocity in the ship editor? (You probably did, but checking anyway...)
-
Am I writing my posts in code? Did I forget to turn off my time machine? Seriously, what is the explanation for these three responses from three different people?
I ended up making a duplicate ship class with the "supercap" flag
alternatively you could use the supercap warpin
I tried a repeating set-speed approach and didn't like it
Or maybe make a loop triggered by the ships arrival, decreasing its speed by 1 each 5 milisecs?
the best solution would be an enhancement of the warpin code
Shouldn't there be made a way to customize warp arrival anyways?
Maybe I'm just that good at inception. :p
Did you try to use 0 as initial velocity in the ship editor? (You probably did, but checking anyway...)
That isn't applicable for ships that warp in, only for ships that are present at mission start.
-
That isn't applicable for ships that warp in, only for ships that are present at mission start.
A ship with lower initial velocity (like 0) will make full stop sooner than a ship with higher initial velocity (like default 33) upon exiting from warp. In case of a bigger ship, the difference in distance traveled should be quite remarkable.
At least that is my experience from the few missions I fredded back in the old days.
-
Interesting. I'll have to take another look.
-
I was trying to say that if you end up tweaking warpin settings make sure they can be adjusted to all the different universes we support and future ones we might, i.e., make it as flexible as possible. Yes, I mangled that horribly in my previous post. :P
-
would either of these table entries help?
http://www.hard-light.net/wiki/index.php/Ships.tbl#.24Warpin_Speed:
$Warpin Speed:
FS2 Open 3.6.10:
Sets the speed at which the ship warps in for default warpin effect
Sets the time that the ships warp in (not the animation itself) takes for BTRL type warpin effects
Syntax: Float, meters per second or miiliseconds
$Warpin Time:
FS2 Open 3.6.10:
Defines the effect duration
Syntax: Float, seconds
No, unfortunately. That was the first thing I tried, but those only work for BTRL and Hyperspace warp effects, not the FS2 warp effect.
I'm pretty sure at least one of those two works for FS2 warp effect. It's how Spoon got his Hertak Armageddons to have a super slow warpin to make it seem like a much larger and more imposing ship, IIRC.
Because those things take quite a long time to warp in and move slowly while doing so.
As for the checkpoint thing, it might just be a set-speed SEXP. I'm not sure what you mean by "you didn't like it" - but for the checkpoint purposes, it didn't need to look like a smooth/visually-acceptable transition warping in, it just needed the ship not to keep hurling forwards and messing up mission-timing.
-
Where did Spoon do this? Is that Wings of Dawn?
And I need a slower warpin for visual purposes, not for checkpoint purposes. The set-speed approach didn't look visually smooth enough.
-
Where did Spoon do this? Is that Wings of Dawn?
And I need a slower warpin for visual purposes, not for checkpoint purposes. The set-speed approach didn't look visually smooth enough.
It is indeed.
You'll probably like the Armageddon warp in then. You can see it here about 1:30 in:
http://www.youtube.com/watch?v=uk_eql49h7c&feature=c4-overview&list=UUxW-7zwlLDcTmdpn2sOKEWg
-
As headdie said, for the slow Hertak warping speed I used $Warpin Speed: 100
If you want a different deceleration speed after the warpin itself has completed change the $Forward decel:
That's all I know
-
And you used the standard subspace warp effect, not your own custom effect?
-
Dude, maybe you could, like, look at the goddamn mod instead of doubting what everyone's telling you.
-
There's a difference between doubting and asking for more information.
-
And you used the standard subspace warp effect, not your own custom effect?
The maps are from ASW I think. (I'm not completely sure ill be honest) Aside from that its the same old subspace.
-
The maps are from ASW I think. (I'm not completely sure ill be honest) Aside from that its the same old subspace.
Okay, cool.
As it turns out, editing those ship fields would require me to create a duplicate ship entry anyway. I was hoping there would be a purely sexp-based solution.
That isn't applicable for ships that warp in, only for ships that are present at mission start.
A ship with lower initial velocity (like 0) will make full stop sooner than a ship with higher initial velocity (like default 33) upon exiting from warp. In case of a bigger ship, the difference in distance traveled should be quite remarkable.
At least that is my experience from the few missions I fredded back in the old days.
I just tested this, and the initial velocity made not one whit of difference, either on retail or latest SVN. I used a mission with two Hatshepsuts, one set at 0 initial velocity and one set at 100, with both cued to warp in at the same time.
-
I just tested this, and the initial velocity made not one whit of difference, either on retail or latest SVN. I used a mission with two Hatshepsuts, one set at 0 initial velocity and one set at 100, with both cued to warp in at the same time.
Interesting. There used to be a difference at some point because I remember testing this in the early days of FSO. Might have been something else causing the behavior then. At least that's certain now then.
-
As it turns out, editing those ship fields would require me to create a duplicate ship entry anyway. I was hoping there would be a purely sexp-based solution.
WCS released it's source code, so you could always port that SEXP of theirs to FSO. Would be handy for cutscenes, and more SEXPs won't hurt anyone.
-
Karaj was looking at it, I remember him saying that if that sexp was gonna make it into FSO it would have to be made more generalist first.
-
Would there be anywhere it would be useful other than warpin though? Cause if it's that specific, it should be handled in code, either by a new table entry or by a new field in the ships editor.