couple of weapons fire/effect queries

Freeform discussion about anything related to modding Transcendence.
Post Reply
relanat
Militia Captain
Militia Captain
Posts: 800
Joined: Tue Nov 05, 2013 9:56 am

Tue Jun 11, 2019 5:08 am

Can someone with weapons/graphics knowledge have a look at these, please?

First one is single fire weapons can have projectiles/beams/effects emerging from different points relative to the ship.
It is more visible in the Wolfen. It looks a little odd.

In the Wolfen, the Lancer cannon and Dwarg cnidocyst don't show a noticeable gap. They appear from the tip of the front of the ship.

Akan 30 (see attached image), heavy slam cannon, Moskva 33 appear from a short distance in front of the ship. The presence of 'muzzle flash' makes this more apparent.

The Urak howitzer lacks the muzzle flash but the projectile appears to emerge from even further in front of the ship.

In the Sapphire the Akan 30 appears from the tip of the ship as expected. But the Lancer appears slightly behind this from the centre of the forward ship segment/cockpit.
The Urak howitzer again appears a short distance in front of the ship although it is not as noticeable here.


There seems to be three different source points for weapons fire. The Urak howitzer shoots from the front position, the Akan 30 from a short distance behind this and the lancer cannon from a point further behind.
Both ships have two defined device slots, one for omni and another for all weapons so the expected behavior would be a consistent source point.
Is this some sort of bug or is it something that needs code that I don't know about to alter it? It makes it difficult to set an approriate 'posRadius' in <DeviceSlot> code as some weapons fire appears from way out in front of the ship. The Urak howitzer shoots from a long way in front of the Wolfen.


Second is the weapon source point falling behind when the ship is rotating.
See the second attached image. This is Kaama's F1 Freighter mod (image by Xephyr) firing while rotating. The laser fire appears to be coming from where the ship was, not where it is now.

I added this code in the ShipClass:

Code: Select all

<DeviceSlots>
		;Weapons with single point origin. Includes launchers. Front of ship.
	<DeviceSlot criteria="w +property:singlePointOrigin; -property:omnidirectional" posAngle="0"  posRadius="80" posZ="0"/>
		;Fixed dual firing weapons. Back from the front of the ship. Includes launchers.
	<DeviceSlot criteria="w -property:singlePointOrigin; -property:omnidirectional;" posAngle="0"  posRadius="70" posZ="0"/>
		;Omni weapons fire from the center of the ship. Are there any dual omni weapons? Check.
	<DeviceSlot criteria="w +property:omnidirectional;" posAngle="0"  posRadius="0" posZ="0"/>
</DeviceSlots>
It also shows in the Sapphire but is not as noticeable. I think the longer length of the freighter is contributing to this.
Again, is this a bug or does it need special code to set the correct weapons fire position?

TIA.
Attachments
F1 Freighter rotating.JPG
F1 Freighter rotating.JPG (28.37 KiB) Viewed 171 times
wolfen single.JPG
wolfen single.JPG (12.61 KiB) Viewed 171 times
Stupid code. Do what I want, not what I typed in!

NMS
Militia Captain
Militia Captain
Posts: 541
Joined: Tue Mar 05, 2013 8:26 am

Wed Jun 12, 2019 8:26 am

The Wolfen's nacelles stick out a bit farther forward than its nose, so positioning the weapon fire points optimally would require separate slots for single and dual weapons, which wasn't possible until recently. Now that it is, I suppose we should do that. But due to the angle the images are rendered from, it will never be perfect from all angles (though posZ can help, if it's been fixed). Currently, on most ships, I don't think different weapons are firing from different points. Probably some fire effects extend a bit behind the fire point and others don't.

Fire effects don't rotate with the ship for fixed weapons. If they did, they would stop lining up with the shots that come out of them, which would also look weird, though it might be better. This is pretty obvious in a still image with a fast-rotating ship like the Wolfen, or a ship with a low number of facings when it changes facings, but it's less noticeable in-game, at least for small ships. I don't see any good solution without redesigning them to last for fewer frames.

Post Reply