Log in

View Full Version : 3.7 Sk flak gun


Jankowski
04-10-10, 07:50 PM
while i am playing gwx, i notice that this gun has a low firing rate. in reality this gun was supposed to fire every two seconds. is there a way to change this? also if it involves using hex editors or something can u give a short tutorial pls. also if there is a way to make it fire HE shells that would be nice.

thanks people!

timmy41
04-10-10, 10:58 PM
edit the .cfl to give it HE loadout, rate of fire is probably there too, i have no idea.

krashkart
04-11-10, 12:21 AM
Writing up a quick tutorial for this... I just need to test the method to see if it works right. Should have it posted within an hour or so.

EDIT:

Okay, I just tried a Basic.cfg edit in my campaign and was unable to add HE rounds to my 20mm flakzwiling mount. This might have something to do with the ammo storage values in Basic.cfg. I did, however, verify that a simple edit to GUNS_SUB.sim will decrease the rate of fire on that particular gun (imagine a twin 20mm firing one round per second :lol:).

Preparation:

Download a copy of Silent 3ditor (Silent 3ditor thread (http://www.subsim.com/radioroom/showthread.php?t=119571)) and install. Then install JSGME if you haven't already. A folder called Mods will be created by JSGME in your root SH3 install directory. Create a new directory in there to contain your modifications to the game; e.g. YourMod. Then clone the directory structure leading to the file you wish to edit; e.g. Mods\YourMod\data\Library and copy-paste the target file into the corresponding folder. This way if you make a mistake all you have to do is deactivate YourMod with JSGME, correct the errors and then reactivate YourMod for another try.

Using Silent 3ditor:

Copy GUNS_SUB.sim from SH3\data\Library and paste it into Mods\YourMod\data\Library. Fire up the Silent 3ditor and use it to open that file. You will see a number of data elements named wpn_Cannon. These contain the data you'll want to edit. Expand 16:wpn_Cannon, click on the 17:wpn_Cannon right below that, and then expand the obj_Turret tree.

You should see two values named Train and Barrel with the corresponding values <DMY_37mmM_UFlak_High_Rotation> and <37mmM_UFlak_High_Body>. We're on the right track! 18:wpn_Cannon and 20:wpn_Cannon also hold data for the other two 37mm flak mounts that are in the game.

I think that 16:wpn_Cannon refers to the earliest available 3.7cm flak mount, and 20:wpn_Cannon refers to the final, twin-barreled, version of the 3.7cm. Assuming that you currently use the earliest version in your campaign, you'll probably want to edit 16:wpn_Cannon.

The recoil_time value controls rate of fire. If you change that number to something smaller the ROF will increase, increase the number and ROF will decrease. Make your changes and click the Save icon to save your changes. You can still run the game with the file open in the editor, which makes modding a lot quicker.

I'm unsure how to add HE rounds to a flak gun. If you expand the ammo_storage tree, there is an entry for HE ammunition. Expand that tree and you'll see a shell type associated with it.

However, I tried adding 100 rounds of HE ammo to the 20mm Flakzwiling through a Basic.cfg edit and still only had AP available in the game. I have no idea how to help you add HE to the 37's. However, the 37mm cannon all use AA and AP ammunition, which should be just as, or more powerful than, a high-explosive round of the same size.

REVISION:

The recoil_time value controls rate of fire. If you change that number to something smaller the ROF will increase, lower the number and ROF will decrease.

Should have read:

The recoil_time value controls rate of fire. If you change that number to something smaller the ROF will increase, increase the number and ROF will decrease.

The tutorial now reflects that change. Sorry for the mix-up.

timmy41
04-11-10, 12:55 AM
I just remembered something, in the GWX manual it states that the rate of fire for that gun was improved. Not sure to what though, I havent gotten it yet. Are you using GWX?

Jankowski
04-11-10, 03:35 AM
thanks krashkart! thats what im looking for!. gwx increased the rate of fire from the original where it took about 20 seconds for it to fire.

krashkart
04-11-10, 03:44 AM
thanks krashkart! thats what im looking for!. gwx increased the rate of fire from the original where it took about 20 seconds for it to fire.

Ah, roger that. Hope it helps. I found a mistake in the tutorial and corrected it. Revision is noted at the bottom of the post.

Oh, and welcome to Subsim, Jankowski. :DL:salute:

Jankowski
04-11-10, 07:21 AM
is there a way to make an explosion effect when you hit a ship with the shell? its kind of wierd seeing that medium callbre shell look like its fired from a pistol or something. also would be pretty fun if you could make the deck gun fire rockets! though i assume that it would be alot harder. i have a tiny bit of expierience with the hex editor, and hopefully this will work out fine when i get the chance to use it.

thanks again!

krashkart
04-11-10, 10:36 AM
You're welcome. :DL

Have a look at the weapons in guns.sim with Silent 3ditor. There are quite a few, but the first entry in the stock game is for a 14-inch gun, and for GWX it is for a 381mm gun, IIRC. Expand the ammo_storage entries and have a look at the shell types to get a good idea of how big of an effect you want. Keep in mind that if you change the shell type of a flak cannon to one used by a larger naval gun (like a 16-inch, for example), your flak cannon will do the same amount of damage as that larger gun would.

If you open Shells.sim there are values for the tracer, water splash, and explosion effects, and also detonation effects. Where those values are actually pulled from is beyond my experience.

Couldn't hurt to ask around in the SHIII Mods Workshop (http://www.subsim.com/radioroom/forumdisplay.php?f=195), too. :yep:

Jankowski
04-11-10, 06:48 PM
are there any side effects of changing the gun power?? like i dont want to change evry 3.7 SK flak gun in the whole game. but i dont think there are any more apart from your own. also is there a way to make it so the uboats you see around the place in gwx have the same flak gun as yourself? i dont think that buly default gun that they are put with suits them. i have noticed that the minesweepers have the same flak gun as your submarine.

and also i assume that you can change the firing rate of every gun in this way?

timmy41
04-11-10, 07:25 PM
are there any side effects of changing the gun power?? like i dont want to change evry 3.7 SK flak gun in the whole game. but i dont think there are any more apart from your own. also is there a way to make it so the uboats you see around the place in gwx have the same flak gun as yourself? i dont think that buly default gun that they are put with suits them. i have noticed that the minesweepers have the same flak gun as your submarine.

and also i assume that you can change the firing rate of every gun in this way?
What I believe jank is saying is if one could make the AI uboots have c38's 20mm instead of the oerlikon 20mm cannon

Jankowski
04-12-10, 06:39 AM
thats right, those guns are too blocky to be on u-boats! compared to the hi resolution skins, they look like they are made of lego bricks