Been trying for most of the day to add a smoking / steaming barrel effects to a weapon going through its repack sequence. Damming thing is the effects are not showing, nor are then LUA errors. Anyone know what I maybe missing as this is bloody frustrating.
-Resin
PlayFxWeaponPackSequence = function(self)
if self.SpinManip_R then
--Stop the barrels spinning
self.SpinManip_R:SetTargetSpeed(0)
--Steam
local steamFX_R01 = CreateAttachedEmitter(self.unit, 'auto_cannon_barrel_right', self.unit.MyArmy, '/effects/emitters/weapon_mist_01_emit.bp'):ScaleEmitter(1):SetEmitterParam('Lifetime', 5):OffsetEmitter(0,0,0)
self.unit.Trash:Add(steamFX_R01)
--Smoke
for k, v in effectTemplate.SmokePlumeLightDensityMed01 do
local smokeFX_R02 = CreateAttachedEmitter(self.unit, 'auto_cannon_muzzle_right', self.unit.MyArmy, v):ScaleEmitter(1):SetEmitterParam('LIFETIME', 5)
self.unit.Trash:Add(smokeFX_R02)
end
end
TDFGaussCannonWeapon.PlayFxWeaponPackSequence(self)
end,