I have most of the problems fixed now. I did find some new issues. There are still some instances where the animations go a little weird (Such as firing, and still on most deaths there is a problem with the weapon. ) , and they seem to have gained the ability to walk through walls...no idea on that one atm:(
So, on to the changes!
First up was SiegeArcher05_Script.lua
Changed AttachEffectsAtBone in OnCreate to:
AttachEffectsAtBone( self, EffectTemplates.Archer.SiegeAmbient01, 'sk_Sniper_Leftwingstub', nil, nil, self.TrashOnKilled )
AttachEffectsAtBone( self, EffectTemplates.Archer.SiegeAmbient01, 'sk_Sniper_Rightwingstub', nil, nil, self.TrashOnKilled )
The actual model file is that of Regulus, not a SiegeArcher. So I used his bones, which the main ones for attaching effects to are his wingstubs. You can adjust these for the right bones/effects, just make sure you are using bones from the reg models.
Next I added a new function after oncreate, this was done because on death his bones were not in the proper state for the death animation, which caused weird things. Still have some of the problems, such as what happens to the bolter. ARGH.
OnKilled = function(self)
MinionUnit.OnKilled(self)
self:ShowBone("sk_Sniper_Leftwing1", true)
self:ShowBone("sk_Sniper_Rightwing1", true)
self:ShowBone("sk_Sniper_Wingsbase", true)
self:HideBone("sk_Sniper_Leftwingstub", true)
self:HideBone("sk_Sniper_Rightwingstub", true)
self:HideBone("sk_Sniper_Wingstubsbase", true)
end,
Next we move over to SiegeArcher05_unit.bp
MuzzleBones changed to: 'sk_Sniper_Turret_Muzzle_REF'
This is the bone that weapon effects are attached to, and needed to reference one from the reg model.
Next after MuzzleBones I added:
MuzzleEffect = {
Base = 'Projectiles',
Template = 'Boulder01',
},
This actually handles the effect and is required for all of it to work properly.
and last up I set:
TurretBoneMuzzle, TurretBonePitch, and TurretBoneYaw changed to: 'sk_Sniper_Root"
so they reference a bone on the reg model.
The download is:
http://www.imperiuminferi.com/demigodftp/Mrappard/Favormod/Favormod.zip
Check out my post at https://forums.demigodthegame.com/372358 on how you can access the ftp on my website for uploads, downloads, pics, etc.
Going to take a break from this one for a bit now though. I just spent about 3 hours working on that:)