• Please make sure you are familiar with the forum rules. You can find them here: https://forums.tripwireinteractive.com/index.php?threads/forum-rules.2334636/

Code [Help] Constant Fire Sound/Animation Limitation

Here's the whole of the basekfweapon.uc if it helps:
Spoiler!

Sorry don't know what exactly to look for.
 
Upvote 0
Flux look at my last post on the page 1. it fixes the view for you :)

Shot00053.jpg
 
Last edited:
Upvote 0
The MP7 uses a fire loop and fire end sound as well as various bits of code responsible for the animation, it works exactly like extremely fast firing guns in red orchestra like the machine guns, when you switch to semi auto fire the reason why the gun looks like it's firing is because it goes into the firing loop state. I've tried to do the exact same thing you are trying to do and it did not end well. I could probably help you with this but your best bet is completely rewritting the code.
 
Last edited:
Upvote 0
i'm still having the problem with my mg34.
the fullauto uses the fireloop/end anims & ambientsound/end sounds.
there are single fire sounds and anims that i use for semiauto, but they act like the loop/ambient stuff, while only shooting once.
that was with mg34 extends mp7, mg34fire extends mp7 fire.

next i tried mg34 extends ak47, with firemode0=mg34fire (extends mp7), firemode1=mg34singlefire (extends deaglefire), and now the anims all work, but when i shoot a singlefire, it toggles the primary fire to semi.

so then i did mg34 extends kfweapon, and now the primary doesnt do squat. alt fire works fine though.


code:
http://www.gamefront.com/files/20685091/mg34classes.7z
 
Upvote 0
Right all I did was copy the AKAssaultrifle.uc and changed the Mesh/Skins to:
Code:
     Mesh=SkeletalMesh'KF_Weapons2_Trip.MP7_Trip'
     Skins(0)=Shader'FluxMP7_T.MP7_Final'
     Skins(1)=texture'FluxMP7_T.Dot'

It still does the same thing...

Screenshot here of it.

Here's the defaultproperties of my file for as nothing else has been changed:
Code:
defaultproperties
{
     MagCapacity=30
     ReloadRate=3.000000
     ReloadAnim="Reload"
     ReloadAnimRate=1.000000
     WeaponReloadAnim="Reload_AK47"
     HudImage=Texture'KillingFloor2HUD.WeaponSelect.Ak_47_unselected'
     SelectedHudImage=Texture'KillingFloor2HUD.WeaponSelect.Ak_47'
     Weight=6.000000
     bHasAimingMode=True
     IdleAimAnim="Idle_Iron"
     StandardDisplayFOV=60.000000
     bModeZeroCanDryFire=True
     TraderInfoTexture=Texture'KillingFloor2HUD.Trader_Weapon_Icons.Trader_AK_47'
     bIsTier2Weapon=True
     PlayerIronSightFOV=65.000000
     ZoomedDisplayFOV=32.000000
     FireModeClass(0)=Class'KFMod.AK47Fire'
     FireModeClass(1)=Class'KFMod.NoFire'
     PutDownAnim="PutDown"
     SelectSound=Sound'KF_AK47Snd.AK47_Select'
     SelectForce="SwitchToAssaultRifle"
     AIRating=0.550000
     CurrentRating=0.550000
     bShowChargingBar=True
     Description="A classic Russian assault rifle. Can be fired in semi or full auto with nice knock down power but not great accuracy."
     EffectOffset=(X=100.000000,Y=25.000000,Z=-10.000000)
     DisplayFOV=60.000000
     SleeveNum=2
     Priority=5
     CustomCrosshair=11
     CustomCrossHairTextureName="Crosshairs.HUD.Crosshair_Cross5"
     InventoryGroup=3
     GroupOffset=4
     PickupClass=Class'KFMod.AK47Pickup'
     PlayerViewOffset=(X=18.000000,Y=22.000000,Z=-6.000000)
     BobDamping=6.000000
     AttachmentClass=Class'KFMod.AK47Attachment'
     IconCoords=(X1=245,Y1=39,X2=329,Y2=79)
     ItemName="AK47"
     Mesh=SkeletalMesh'KF_Weapons2_Trip.MP7_Trip'
     Skins(0)=Shader'FluxMP7_T.MP7_Final'
     Skins(1)=texture'FluxMP7_T.Dot'
     TransientSoundVolume=1.250000
}
 
Last edited:
Upvote 0
Flux I did explain to add Prepivot=(z=5)

but i don't see it in there?

actually i found z=6 is better, lines up perfectly
Mate you never said this even in the PM :p I'll try this now.

RO doesn't want a toggle like the AK47. He wants two seperate fire modes, one is one speed, one is another. That's what I think he wants anyway.
 
Upvote 0
the mg34 has loopanim and and ambient sounds for fullauto fire. so i nabbed the mp7/mp7fire code for those functions and defaults.

the semiauto has a singlefire anim and singlefire sound, separate from the looped ones.
so when i use them with the mp7 code, they loop, so instead of using the ak47 toggle switch, i use
firemode0=fullautofire
firemode1=semifire

semifire now extends bullpupsemifire, and it works good.
fullauto i am now having problems with, the sound wont play.
and the reload anims wont play.
and it wont reload now.


mg34.uc
Spoiler!


mg34fire.uc
Spoiler!


mg34singlefire.uc
Spoiler!
 
Last edited:
Upvote 0
that is what the mg34 reload is named, in animations->mg34+mg34 animation set, there are two reload animations.
bipod_reload
bipod_reload_s
they seem to me to be exactly the same.
maybe changing fireendstereosound will fix the sound.

why do you think i cant zoom in now? (ironsights)

Because the way iron sights work in red orchestra is different from killing floor
 
Upvote 0
all the other mg's i ported work fine, i didnt extend the mg34 from any ro_classes, it is all under kfweapon/kfweaponfire, and modified to use fireloopanims/ambientsouns function nabbed from mp7m classes.

as far as i can tell, all the ironsights do in kf is zoom and move the mesh's prepivot to center of screen.

Not exactly it's prepivot but the actually location of the gun which is known as the PlayerViewOffset
 
Upvote 0