Results 1 to 10 of 10

Thread: Change the rate of fire in turrets (MG42 and Browining .30 calliber)

  1. #1

    Default Change the rate of fire in turrets (MG42 and Browining .30 calliber)

    Hello, guys. I'm trying to figure out a way to chage the rate of fire of mounted machine guns in game for a mod I'm working on. I intend raising the Rate of Fire of the MG42 to it's real-life RoF and will later add a Maxim gun and give it the same RoF as the BAR. However the RoF (or firedelay command) of turrets in game seems to be locked to 0.06.

    -I tried changing the 'firedelay' from 0.06 to 0.05 and 0.04 in the .tik files but did not work.

    -I tried creating folders inside the 'main' one with the files hoping they would override the ones inside the PK3 files but it also did not work.

    -I tried making a custom mounted gun from zero and apply the custom 'firedelay' but they are also afected by the default 'firedelay'.

    I any of you know or stumble upon something that can help me with this issue please reply.


    Cheers!

  2. #2

    Default

    It's because of the server FPS, which is defaulted to 20. Raising it using "sv_fps" cvar fixes that, but also breaks the game in many ways.
    You can try and see it for yourself, start the first level and play like normal with sv_fps set to 60.

  3. #3

    Default

    Have you check if you didnt change on the wrong place?
    Sometimes the same file is repeated in different files so one will overwrite the other.
    Is only the last file loaded is used.

  4. #4

    Default

    Checked if there were repeated files. Nope.

    Mod file has several 'z's in it's name so it should be overriding any stock files and settings.

    The 'firedelay' is changed for both single player and multi player modes in the tiki file (MG42_gun.tik).

    In all of my testing I allways loaded a new game/map in both single player and multi player to make sure the new settings are recognized. Never loaded a previous saved game. Still didn't work.

  5. #5

    Default

    The Mg42 use 2 variables for different modes.

    This one for Single Player:
    Code:
    firedelay 0.06
    And this one for Multiplayer:
    Code:
    dmfiredelay 0.06
    Have you test both?

  6. #6

    Default

    Yeah, changed those to 0.4 before. Didn't work.

    I experimented chaging the game's FPS to 30 as metlar sugested. Rate of fire becomes faster but some things become broken.

    I guess I can't do much if the rate of fire of turrets is locked to the game's fps.

  7. #7
    Developer RyBack's Avatar
    Join Date
    Apr 2014
    Location
    In Front of the screen
    Posts
    1,594

    Default

    You can use openmohaa, it fixes the broken animations with higher sv_fps.
    https://github.com/openmoh/openmohaa
    https://github.com/openmoh/openmohaa...es/tag/v0.80.0
    Discord: RyBack#4239

  8. #8

    Default

    Tried playing mohaa with openmohaa and the console seemed to be broken. Everytime I opened it and tried to type a command the console closed.

    Most people don't seem to be using open mohaa so I will continue to use the base game to work on my mod.

    Also some weapons seem to lose their sound effects when I play open mohaa with my mod.

    I also tried to assign a lower rate of fire to the turrets to see if it worked. Nope. Rate of fire of turrets are 100% hard coded into a specified value.

    Thank you for the help anyway.
    Last edited by Soares93; December 13th, 2024 at 10:20 AM.

  9. #9

    Default

    I just ocorred to me what if I can order the turret to fire more that 1 time in the tiki files? The player clicks one time and the weapon makes a 3 fire burst.

    Are there any mods that have burst fire modes for weapons that I can copy the coding or does anyone know of a way to simply add it to the tiki file?

    Or make it look like its firing 3 shots but its simply spawnning 3 consecutive muzzle flashes and ejects 3 shells.

  10. #10

    Default

    I have been experimenting editing the mg42 model, animations and sounds to make it look like it's shooting faster. Animations work fine but it turns out the ingame 20 fps aren't consistent and suffer some delays. I edited the firing sound to repeat at the 0.5s mark to make it sound it's shooting twice as fast, but when those delays don't happen it makes the MG42 sound as it's only firing one shot again.

    I've decided that it's simply too complicated to even make the turrets in game to shoot faster and leave it as is.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •