Help reading .class files?

Started by Hijitori on

Topic category: Advanced modding

Last seen on 18:09, 11. Mar 2022
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Help reading .class files?
Sat, 03/20/2021 - 10:55 (edited)

I made a ruby ore in my mod to which I have lost access to workshop recently, left with only .jar mod file with .class files in it. I found 3 .class files in .jar:

(1.12.2 mod)

RubyOreBlock$1

RubyOreBlock$CustomBlock

RubyOreBlock

 

I really want to retrieve the most important settings of the ore like its hardness, generation chance, maximum height etc.

Does anybody know in which lines can I find those parameters? Thanks in advance.

 

 

Edited by Hijitori on Sat, 03/20/2021 - 10:55
Last seen on 23:21, 17. Jun 2022
Joined Apr 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
To read .class files you…
Fri, 03/19/2021 - 22:30

To read .class files you need to decompile your mod’s jar file using decompiler. You can find it in the internet

Then you should open your ruby ore file and find something like this

class

There is a line with Block.Properties and in it you will find your ruby ore's material, sound, hardness, resistance, etc

Last seen on 18:09, 11. Mar 2022
Joined Jun 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Thanks and how about…
Sat, 03/20/2021 - 11:06

Thanks and how about generation chance/height/amount f.e.? Do you know where I can find those informations?

I also found this in RubyOreBlock.class:

RubyOreBlock.block.func_176223_P(), 6), Placement.field_215028_n, (IPlacementConfig)new CountRangeConfig(1, 1, 1, 14)));