Special Aircraft Service

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 [2]   Go Down

Author Topic: What file do I need to open in order to edit damage values of weapons?  (Read 3625 times)

0 Members and 1 Guest are viewing this topic.

kalsonic12

  • member
  • Offline Offline
  • Posts: 18
Re: What file do I need to open in order to edit damage values of weapons?
« Reply #12 on: January 18, 2018, 02:44:59 AM »

The process is:
  • Dump Classes
  • Unhash Classes
  • Decompile Classes
  • Edit Classes' Sourcecode
  • Compile Classes
  • Hash Classes
  • Put Hashed Files into a new Mod folder, e.g. when you're on 4.13.4M, install SAS Modact 6.4 and then create a new folder "#SAS/!YourFineModNameHere!" to hold the new files

All of this can be found in the Superschool by the way.

Cheers!
Mike

Maybe there's just something wrong with my eyesight, or that I have a short attention span but I was struggling to find the relevant tutorial at the Superschool. In any case, thank you very much storebror, I really appreciate it.
Logged
Simulator difficulty? Hah!

Dreamk

  • Modder
  • member
  • Offline Offline
  • Posts: 2021
Re: What file do I need to open in order to edit damage values of weapons?
« Reply #13 on: January 18, 2018, 05:31:07 AM »

When you open with a  decompiler (Eclipse and DJ Java decompiler are the most commonly used for Il2 modding) the java class of a weapon (such as a bomb) you'll get something like that - here the bomb called 100lbsEe:

package com.maddox.il2.objects.weapons;

import com.maddox.rts.Property;

public class Bomb100lbsEe extends Bomb
{

    public Bomb100lbsEe()
    {
    }


    static
    {
        Class class1 = com.maddox.il2.objects.weapons.Bomb100lbsEe.class;
        Property.set(class1, "mesh", "3DO/Arms/100LbsBombEe/mono.sim");
        Property.set(class1, "radius", 25F);
        Property.set(class1, "power", 25F);
        Property.set(class1, "powerType", 0);
        Property.set(class1, "kalibr", 0.2F);
        Property.set(class1, "massa", 45F);
        Property.set(class1, "sound", "weapon.bomb_mid");
    }
}

Damage effect depends upon:
1) type of explosive effect: Blast, Frag, Incendiary
2) mass of the explosive inside the bomb ("power" , in kg of explosive)
3) mass of the bomb ("massa" in kg) - or rather the ratio between the weight of explosive content and the overall weight of the bomb
4) radius of destruction - in meters, this is an input data (its historical value depends upon formulas that are different according to the type of explosive, the type of explosive effect and the ratio between explosive content and total mass - the whole subject of terminal ballistics is a true perpetuum mobile, always evolving, in parallel to the development of weapons technologies )

When you have edited these data in the java file of the new bomb you wanted to create, you recompile the file using the same decompiler, and then you has it using the Il2 hasher. You'll put this file in a new folder and this folder inside the mods folder of your game. You must add a "firing the bomb" java file - this would be called here "bombgun100lbsEe.class" and put it in the same folder. Then you need of course to create the mesh, bitmap and material for this bomb, and copy it to the same folder inside a subfolder called (3Do/Arms/100LbsBombEe)

On a finger tip this is what you need to do - how to do it is in the learning curve described in the above posts by Mike  and Epervier.
Logged

kalsonic12

  • member
  • Offline Offline
  • Posts: 18
Re: What file do I need to open in order to edit damage values of weapons?
« Reply #14 on: January 18, 2018, 07:36:39 AM »

When you open with a  decompiler (Eclipse and DJ Java decompiler are the most commonly used for Il2 modding) the java class of a weapon (such as a bomb) you'll get something like that - here the bomb called 100lbsEe:

package com.maddox.il2.objects.weapons;

import com.maddox.rts.Property;

public class Bomb100lbsEe extends Bomb
{

    public Bomb100lbsEe()
    {
    }


    static
    {
        Class class1 = com.maddox.il2.objects.weapons.Bomb100lbsEe.class;
        Property.set(class1, "mesh", "3DO/Arms/100LbsBombEe/mono.sim");
        Property.set(class1, "radius", 25F);
        Property.set(class1, "power", 25F);
        Property.set(class1, "powerType", 0);
        Property.set(class1, "kalibr", 0.2F);
        Property.set(class1, "massa", 45F);
        Property.set(class1, "sound", "weapon.bomb_mid");
    }
}

Damage effect depends upon:
1) type of explosive effect: Blast, Frag, Incendiary
2) mass of the explosive inside the bomb ("power" , in kg of explosive)
3) mass of the bomb ("massa" in kg) - or rather the ratio between the weight of explosive content and the overall weight of the bomb
4) radius of destruction - in meters, this is an input data (its historical value depends upon formulas that are different according to the type of explosive, the type of explosive effect and the ratio between explosive content and total mass - the whole subject of terminal ballistics is a true perpetuum mobile, always evolving, in parallel to the development of weapons technologies )

When you have edited these data in the java file of the new bomb you wanted to create, you recompile the file using the same decompiler, and then you has it using the Il2 hasher. You'll put this file in a new folder and this folder inside the mods folder of your game. You must add a "firing the bomb" java file - this would be called here "bombgun100lbsEe.class" and put it in the same folder. Then you need of course to create the mesh, bitmap and material for this bomb, and copy it to the same folder inside a subfolder called (3Do/Arms/100LbsBombEe)

On a finger tip this is what you need to do - how to do it is in the learning curve described in the above posts by Mike  and Epervier.

Thank you very much! Your explanation feels clearer.
Logged
Simulator difficulty? Hah!

SAS~Ghost129er

  • SAS Team
  • member
  • Offline Offline
  • Posts: 2100
  • SAS Certified Lurk
Re: What file do I need to open in order to edit damage values of weapons?
« Reply #15 on: January 20, 2018, 12:45:34 AM »

Maybe there's just something wrong with my eyesight, or that I have a short attention span but I was struggling to find the relevant tutorial at the Superschool. In any case, thank you very much storebror, I really appreciate it.

The superschool isnt necessairly a 0-100 training course board. Back then you had to proove yourself worthy of being in the invite only group it was so thats why you wont find many spoonfed tutorials for absolute beginners there, though there ARE some there.  ;)
Logged
Current activity: Giving his E46 330ci some TLC.

Usernamer

  • member
  • Offline Offline
  • Posts: 2
Re: What file do I need to open in order to edit damage values of weapons?
« Reply #16 on: February 25, 2025, 04:12:37 PM »

where to find the class in waw that defines bullet damage speed and explosion radius?
Logged

Usernamer

  • member
  • Offline Offline
  • Posts: 2
Re: What file do I need to open in order to edit damage values of weapons?
« Reply #17 on: February 25, 2025, 04:28:01 PM »

another two question in which class or what in the fms I need to edit to stop that a plane has to be trimmed, I mean deutsche flieger brauchten schon im wk1 aufgrund von gyros keine trimmung.
Logged
Pages: 1 [2]   Go Up
 

Page created in 0.045 seconds with 27 queries.