Content: Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Background: Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Pattern: Blank Waves Notes Sharp Wood Rockface Leather Honey Vertical Triangles
Welcome to TerraFirmaCraft Forums

Register now to gain access to all of our features. Once registered and logged in, you will be able to contribute to this site by submitting your own content or replying to existing content. You'll be able to customize your profile, receive reputation points as a reward for submitting content, while also communicating with other members via your own private inbox, plus much more! This message will be removed once you have signed in.

  • Announcements

    • Dries007

      ATTENTION Forum Database Breach   03/04/2019

      There has been a breach of our database. Please make sure you change your password (use a password manager, like Lastpass).
      If you used this password anywhere else, change that too! The passwords themselves are stored hashed, but may old accounts still had old, insecure (by today's standards) hashes from back when they where created. This means they can be "cracked" more easily. Other leaked information includes: email, IP, account name.
      I'm trying my best to find out more and keep everyone up to date. Discord (http://invite.gg/TerraFirmaCraft) is the best option for up to date news and questions. I'm sorry for this, but the damage has been done. All I can do is try to make sure it doesn't happen again.
    • Claycorp

      This forum is now READ ONLY!   01/20/2020

      As of this post and forever into the future this forum has been put into READ ONLY MODE. There will be no new posts! A replacement is coming SoonTM . If you wish to stay up-to-date on whats going on or post your content. Please use the Discord or Sub-Reddit until the new forums are running.

      Any questions or comments can be directed to Claycorp on either platform.
lipki

how to compile (next try)

10 posts in this topic

I made a first simple mod, to test the workflow.It is coded, tested, and it works.I'm at the stage of compilation, in order to distribute it.But I can not build it alone.Either it is compiled with the sources of TFC.Either it does not compile because it can not find the sources of TFC ...Where can I learn to create a mod (or plugin) for TFC?

0

Share this post


Link to post
Share on other sites

Are you using ./gradlew build to compile ? How did you set up your project ?

0

Share this post


Link to post
Share on other sites

I use "gradlew build", and I do not know how to answer the second question.

0

Share this post


Link to post
Share on other sites

By set up the project I mean how did you code your mod, directly next to TFC sources or in a separate project ?
I haven't done any addon yet but I spent quite some time today to figure out how to do one, and when I use "gradlew build" it compile only the few code I have without the sources of TFC.
So I'll describe how I configured the project.

  • [*]Get TFC sources from github, unzip them. Lets call this folder "TFCraft-master". Now run theses commands in the unzipped folder :
     
gradlew setupDecompWorkspacegradlew eclipse
[*]Grab the forge sources, unzip them in a separate folder and run the sames commands as above. This is the folder where you make your mod. I will call it the "forge folder". [*]Open eclipse and set your workspace to the eclipse folder located in the forge folder. You should see the project Minecraft. [*]Now you need to link TFC sources in your project :
  • [*]Right-click on the project in the package explorer, select new>folder [*]Type "TFC_sources" in Folder name [*]Click on advanced and select "Link to alternate location (Linked Folder)" [*]Browse to the TFCraft-master folder and select the "src" folder [*]Now you should see a TFC_sources folder in your project with 4 sub folders (API, ASM, Common and Resources) [*]Right click on each of theses sub folder and select Build Path > use as source folder

[*]You should have 10 errors showing up. To fix theses, you need to replace the forge source jar by the one in TFCraft-master :

  • [*]Right click on your project, select  build path > configure build path [*]Go in the tab libraries and remove the forgeSrc-[a version number].jar [*]Click on Add external JARs and select the forgeSrc-[a version number].jar located in the folder TFCraft-master>build>dirtyArtifacts

 

You are done, now you should be able to import/code your mod in src/main/java and to compile it alone.

 

Hope it helps

1

Share this post


Link to post
Share on other sites

Ok, I do not use all the file forge, only that there was in TFC.  So I start all over again by following your instructions.I had some problem, but finally it works.Nevertheless when I execute "gradlew build", I get a series of errors like this.org/tfcnt/render/blocks/RenderStackBucket.java:10: error: package com.bioxx.tfc does not existimport com.bioxx.tfc.TFCBlocks;

 

The same problem in fact.

 

Thank you for your help.

0

Share this post


Link to post
Share on other sites

you can take a look how i do it here -- https://github.com/emris/LeatherWaterSacTFC

 

If you need any help understanding how it all works, ask away ;)

 

EDIT: The point is, with gradle build system you can develop TFC or any other mod or addon without setting up a forge dev environment. In fact, to develop TFC you NEED to use the tfc dev environment because of the ASM stuff.

To make addons for tfc, i link my java+resource source folders into the tfc dev environment and do my magic ;)

To build my project, i use gradle in my projects directory. For that to work i copy the tfc-deobf jar file to my /libs directory, then do "gradle build", gradle will look in the /libs directory for any dependencies automatically.

Also, if you do not specify the source folders in your build.gradle file, it will look for the default project file structure, which looks something like this:

 

MyProjectName

--libs

|  |--TFC-deobf.jar

--src

|  --main

|  --java

|  |  --com

|  |   --myname

|  | --mymodname

|  |   |--MyMod.java

|  --resources

|  --assets

|  |  --mymodname

|  |   --lang

|   |   |--en_US.lang

|  |   --textures

|  | --items

|  |   |--some_item.png

|  | --blocks

|  |   |--some_block.png

|  |--mcmod.info

|

|--build.gradle

 

 

EDIT: Also, this topic should be moved to the addons section ... it's not really a TFC support issue .. at all.

0

Share this post


Link to post
Share on other sites

When I try to set it up with gradlew all I get is an error message that Forge is unable to download the Forge files from the Minecraft Amazon servers. Not sure how to fix that.

0

Share this post


Link to post
Share on other sites

you can take a look how i do it here -- https://github.com/emris/LeatherWaterSacTFC

 

If you need any help understanding how it all works, ask away ;)

 

(....)

 

EDIT: Also, this topic should be moved to the addons section ... it's not really a TFC support issue .. at all.

 

I think I understand.

I'll keep you posted.

And if I do, I will ask permission to do a tutorial on the wiki.

 

It is written in the addon section : the questions are to be asked in the support section.

 

 

When I try to set it up with gradlew all I get is an error message that Forge is unable to download the Forge files from the Minecraft Amazon servers. Not sure how to fix that.

 

I had this problem with the 1.6.4 version.

The forge dev-team to says, "Uses the 1.7.10 version, 1.6.4 is dead"

0

Share this post


Link to post
Share on other sites

The forge dev-team to says, "Uses the 1.7.10 version, 1.6.4 is dead"

I fetch the TFC sources from GitHub, and I am pretty sure those are 1.7.10 sources and setup.
0

Share this post


Link to post
Share on other sites

Apprentice Blacksmith

 

It works for me.Merci beaucoup :D

0

Share this post


Link to post
Share on other sites