FAForever Forums
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Login

    Problems adding emitters to a repack sequence

    Scheduled Pinned Locked Moved Modding & Tools
    3 Posts 2 Posters 194 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R Offline
      Resin_Smoker
      last edited by Resin_Smoker

      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,
      

      Kykhu Oss https://youtu.be/JUgyGTgeZb8
      Unit Thrower https://youtu.be/iV8YBXVxxeI
      Beam Tentacle https://youtu.be/le5SNwHvC4c
      Blackhole https://www.youtube.com/watch?v=D9NGQC5rr0c
      Resurection https://www.youtube.com/watch?v=WdbIQ4vHkMs

      1 Reply Last reply Reply Quote 0
      • R Offline
        Resin_Smoker
        last edited by

        Ok I've figured out the the Lifetime parameter is pretty large.... so setting a life time of less then 10 makes the effect so quick that it's not even noticeable.

        Kykhu Oss https://youtu.be/JUgyGTgeZb8
        Unit Thrower https://youtu.be/iV8YBXVxxeI
        Beam Tentacle https://youtu.be/le5SNwHvC4c
        Blackhole https://www.youtube.com/watch?v=D9NGQC5rr0c
        Resurection https://www.youtube.com/watch?v=WdbIQ4vHkMs

        1 Reply Last reply Reply Quote 1
        • N Offline
          Nomander
          last edited by

          Yes, lifetime is in ticks (10th of a second), and then any particle size effects will scale on that lifetime, reducing the visible time to just a few ticks.

          1 Reply Last reply Reply Quote 1

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post