Vehicle Headlights
Posted: Sun Aug 30, 2009 8:17 pm
Alright, so I looked up psych0fred's "Attached Effects" document. It says, plain as day:
Most effects can now be attached to most objects with geometry – vehicles, soldiers, and items, for instance, in addition to props.
It then explains how to do this, and I followed it to the letter. After creating a light effect and attaching it to a modified AT-RT (I copy-pasted the ATRT odf into a new side and made sure it showed up ingame properly before trying this), nothing happened. No light and no error. There were no mispellings in the odf. My code:
So I tried instead to attach it as a damage effect. This worked. However, there is a problem. The light doesn't move with the walker. I don't understand why this is the case, as all the other damage effects (which work perfectly on this vehicle) obviously do this. My code:
I tried editing out the DamageInheritVelocity line, and also putting it at zero. None of this seems to change the fact that the light just stays in one spot.
Then there is the small matter that the light is pointing directly upwards, and I do not know how to tell the game to change the angle of the cone relative to the world (I assume this is done via the walker's odf and not the lights?)
Maybe there is a better way to do this entirely. Either way, any insight is appriciated.
Most effects can now be attached to most objects with geometry – vehicles, soldiers, and items, for instance, in addition to props.
It then explains how to do this, and I followed it to the letter. After creating a light effect and attaching it to a modified AT-RT (I copy-pasted the ATRT odf into a new side and made sure it showed up ingame properly before trying this), nothing happened. No light and no error. There were no mispellings in the odf. My code:
Code: Select all
AttachDynamic = "1"
AttachEffect = "headlights"
AttachToHardpoint = "hp_fire"Code: Select all
DamageStartPercent = "100"
DamageStopPercent = "1"
DamageEffect = "headlights"
DamageEffectScale = "0.75"
DamageInheritVelocity = "1.0"
DamageAttachPoint = "hp_fire"Then there is the small matter that the light is pointing directly upwards, and I do not know how to tell the game to change the angle of the cone relative to the world (I assume this is done via the walker's odf and not the lights?)
Maybe there is a better way to do this entirely. Either way, any insight is appriciated.