MinestrapTeam / Elemental-Caves

Our mod project for #modjam 4
7 stars 6 forks source link

CraftingPillars API and Modular Baubles gems #66

Closed Dawars closed 10 years ago

Clashsoft commented 10 years ago

Could you give a description of what this PR does?

Dawars commented 10 years ago

It add compatibility with the CraftingPillars mod: http://i.imgur.com/I4g1kCm.png

I talked about it with SoBiohazardous

Clashsoft commented 10 years ago

Ok, but I can't merge it at its current state. I do not want to have code from another project in this repo, so could you go ahead and add the src and dev jar of the built mod to the libs directory?

Dawars commented 10 years ago

I hope it works now

Clashsoft commented 10 years ago

Cool! I'll see what I can do in a few minutes.

Clashsoft commented 10 years ago

Sorry, but there are more problems:

  1. You add a strong dependency, that means EC requires your libraries, which is obviously not wanted.
  2. You messed up the the metadata values for the Gem handler. Clear Gems are metadata 0.
Dawars commented 10 years ago

1. Either I add back the API files or I try to do reflecting. 2. It's because the block metas are not the same as the gem ones :-)

I'll only be able to do it tomorrow though

dportuesi commented 10 years ago

Actually, you just have to detect if the two mods are loaded.

Loader.isModLoaded("modname");

Then, load your additional files. That way, there won't be any forced libraries, and it should only load when those things are installed. I did this making compatibility for minestrappolation, which you should find in the code.

Dawars commented 10 years ago

I hope this addition fixes the strong dependency but please tell me if it doesn't

Clashsoft commented 10 years ago

I think so, but you still messed up the Gem metadata values. Clear Gems = 0, Frost Gems = 1, ...

dportuesi commented 10 years ago

Okay, looks good to me. I'm going to merge.