After fiddling around with animated weapons for a while, I decided to try making one from scratch that would be unique to my ship.
(gif is pretty low quality, online converters fail badly)
Essentially what I did was..
- Cut/paste panel from ship into a new .PNG
- Make red outline of the area being animated
- For the first couple frames, lightly shadow the edges of the panel, to simulate it retracting into the hull
- For the rest of the frames, moved the panel back one pixel each time while trimming anything that stuck out of the outline off (At the last few pixels let it stay for a few seconds, as to allow missiles to get out and so the hole isn't completely black)
- (Out of laziness) colored the part where the panel is on the ship black. You could also re-color the outline in each frame of the animation, but I realized I hadn't made a hole under the panel yet.
- Did the animation again backwards (file copy/paste/rename)
- Made the .wpn file (look at existing animated weapons for reference on how to set them up.)
- Timed the weapon data with the animation so that the bay was open while it was actually firing: chargeup = (# of frames / framerate) / 2, chargedown should at least be the same value as chargeup.
- Positioned weapon mounts correctly on ship. TurnRate must be 0.
- Test until perfect!
All done with Paint.net, I'm sure any other image editor capable of Alpha Channels would work. One main drawback to this particular bay is that it's one-sided- I had to flip each image to make the left bay, not to mention make a separate .wpn, .csv line, and animation folder. Meh, payoff was worth it.
Screenshots (Large images):
Spoiler
Stopping to ready missiles (and steady the mystical screenshot camera)
Bay half-open. The charge-up and charge-down for each bay is 0.5
Bay fully open, missile about to fire.
Bay beginning to close, missile launched.
Missile away, bay safely closed.
Two missiles fired in tandem- one bay is closed, the other is just about to lock in place.
Refit screen. Notice small offset- Hardpoints are tricky sometimes for positioning.
To see the ship this weapon is implemented on, check out the Starfighter: Legacy mod! This ship will be coming in the next release.
Please also let me know if you found this demo helpful, and any other tips on making these kind of things better for the next time. Yeah, screenshots. Does Starsector have a built-in screenshot thingy?
Next demo: Retracting weapon pods!