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

    • Crysyn

      Only help if you can be helpful

      Hey All, A topic has come up of late in the IRC channel in regards to the general feel of the forums and the community that supports them. Things have progressed further than I would have liked with out this being addressed more publicly because I would much rather have snubbed this out sooner rather than later.. but I have been busy. Here is the general rule I would like people to follow: Wheaton's Law "Don't be a dick." Those of you from the IRC channel know that this is the only rule I ask people in there to follow and we generally have a good and lively time chatting about all manner of things. This is basic rule that just about everyone understands and I am going to expand it to the forums from here moving forward. If you can not help people in a helpful and polite manner then I simply ask you to stop. Now I generally take a back seat to moderating the forums as I like to participate in the suggestions forum fairly heavily at times and would rather do so as a forums user than a moderator. But I am also fairly well known for being the person who constantly puts their foot down and so I am stepping up and doing so on here. If you find yourself unable to respond to a message politely then I ask that you do not respond. This mostly focuses on the increasing level of hostility found within the Suggestion forum as well as the Server forum. I do not care if this is the 30th some odd time you have seen someone make the same suggestion. Or even if the new post on an older topic is one entry above the old one. I expect the members of this forum to respond politely to the user, new or old, and point to the older topic if it applies and even go the extra step to suggest they either add in new information or to summarize the outcome of the previous discussion based upon the new post's entry into it. That is what we are here for, that is why I close most topics instead of deleting them, so that they can be found and referenced down the road. The next topic is the slew of derailment attempts I have seen as of late. If you want to have fun and joke around that is what the off topic forum is for and pretty much anything goes there. I do not expect to read a suggestion thread and have to go through 3 pages of image memes people have shot back and forth. Quite simply this is a waste of my time to read and then have to clean up. Now for the summary. I am going to start taking a more active role, especially in policing the suggestion forum, and handing out warn levels to people whom I see doing this. These will be indiscriminate and applied not to just the first person who derails or is impolite on a topic or response, but to everyone whom follows the lead of that person. As I do not like doing things with out giving you all warning this post shall serve as that warning. If you have a desire to bring this topic up with me then I invite you to do so on the IRC channel. Lets raise the level of quality and grow the community. Let us not descend into the quality often found on the minecraft or league of legend forums. There is simply no need for that here. Be passionate about things, just do not be abusive.
    • Kittychanley

      Offline Servers

      Recently I've seen a few server listings showing up on the first page of the Servers forum that have been closed for an extended period of time, but have recently gotten a reply from a new member who didn't realize the server is offline. To help prevent this from happening in the future, it would be greatly appreciated if you could use the report function on the original post of any servers that have been confirmed as offline, so that the topic may be locked. If you are the admin of a server and plan on taking the server offline, please use the report function on the original post of your topic to let the TFC Staff know that the topic should be locked. If you are the admin of a server that has a locked topic, and would wish to bring the server back online, please use the report function on the original post of the topic to let the TFC Staff know that the topic should be unlocked. As always, please remember to follow rule #3 of the servers forum and update your topic title to contain the version of TFC that the server is currently running. You can do so by editing the OP, and then clicking on "Use Full Editor."

[0.79.?] Fix Shaders for Terrafirmacraft Water

34 posts in this topic

Hey guys, I've been having a lot of problems trying to get this thing to work with shaders. Each time I fix something something else goes wrong. I finally (I say that) get everything to work, the grass waving and the water etc. but i didnt like the seed I had, so i created a new world, everything works but the grass stops swaying, and instead now only the actual tree trunks sway... weird... It works on the one map I don't want to play on, but not on any other map. I could suck it up and play on the one where it works, but I know there is still a problem and if you guys could help out that would be great :)


Share this post

Link to post
Share on other sites

Water shaders have changed IDs again. They are now: 438, 439, 440, 441, 442, 443 as of TFC v79.13


Since i bought a new rig with a nvidia geforce gtx 980 card, i can get some sick SEUS Ultra shaders going at a ridiculous resolution of 2715 x 1527 and a chunk distance of 16. My fps at these settings is around 25. 


Three screenshots for those who need proof.. he he





EDIT: OK i dont know what is going on but the water IDs now start from 426 onwards.

Nice! All I have to say is... Whats the texture pack? And how you get the blood particles to look so damn cool? :D


Share this post

Link to post
Share on other sites

I am using the most current version of TFC and SEUS.  I did everything that has been said to do, and it still does not work.  I would really appreciate the help.


Share this post

Link to post
Share on other sites

Can you get the shaders to work without any mods? When you say 'it' does not work, you have to be more specific. For example, to get TFC water shaders, you have to look up the block ID's using the NEI plugin for instance. The ID's posted in this thread may not be the same for you. You have to edit the gbuffers_water.vsh file on line 48 starting with if (mc_Entity.x == 8 || ...


Share this post

Link to post
Share on other sites

I'm trying to setup Super Shaders for TFC. I have the water working perfectly (even for streams mod) but the variables are defined differently. The leaves and grass works but how can I get everything to work like the seagrass, lava streams, etc? Here is what it looks like:


#define ENTITY_LEAVES       218.0
#define ENTITY_VINES        486.0
#define ENTITY_TALLGRASS    204.0
#define ENTITY_DANDELION    474.0
#define ENTITY_ROSE         475.0
#define ENTITY_WHEAT        472.0
#define ENTITY_LILYPAD      473.0
#define ENTITY_FIRE          51.0
#define ENTITY_LAVASTILL    433.0
Edited by Phantom329

Share this post

Link to post
Share on other sites



Edit: As for whether or not the shader supports the unlocalized name, you would have to either ask the shader author, or try and see if it works for yourself.


The ShadersModCore, originally daxnitro's shader mod and then karyonix's shader mod implements an OpenGL Shading Language (GLSL) class. The shader exposes the ability to customise shading functionality via GLSL vsh/fsh scripts. I've only seen examples which expose the id's via mc_Entity.x in these scripts. I don't know much about GLSL, but from what I've read it doesn't look like the java unlocalized names are accessible in the vsh/fsh scripts.


I've recently installed TFC 79.26 and a few other mods and got shaders working. Here are the mods I'm using with Forge 4558:

The ProjectRed mod is used to fix a cloud shadow glitch that affects the nVidia cards with optifine; I don't know how it does it, but just having it loaded does the trick. The ShadersModCore and OptiFine mods are the ones I use for Shaders.



I've tried Edi, Sildur and SEUS shaders and rather than just use item numbers each time, I put together a #define list which I added to the top of the vsh/fsh scripts I modified. Whilst not as good as unlocalized names, I found it easier to use the constants rather than the MC/TFC id's; that way at least if the TFC id's change, it's a fix to the constant rather than code logic. I've categorized them roughly into how the scripts use them (waving grass et al), instead of numerical sort order, since it makes it easier to copy them into the conditional statements. Feel free to update it, fix it, re-post it against this thread.

//Vanilla 1.7.10//Water & Ice#define ENTITY_WATER_SOURCE                 8.0#define ENTITY_WATER_STILL                  9.0#define ENTITY_ICE                          79.0//Waving Grass#define ENTITY_SHRUB                        31.0#define ENTITY_GRASS                           31.1#define ENTITY_FERN                            31.2#define ENTITY_DEAD_BUSH                    32.0//Waving Entities#define ENTITY_OAK_SAPLING                  6.0#define ENTITY_DANDELION                    37.0#define ENTITY_ROSE                         38.0#define ENTITY_WHEAT                        59.0#define ENTITY_CARROTS                      141.0#define ENTITY_POTATOES                     142.0//Waving Fire#define ENTITY_FIRE                         51.0//Waving Leaves & double blocks#define ENTITY_LEAVES                       18.0#define ENTITY_SPRUCE_LEAVES                   18.1#define ENTITY_BIRCH_LEAVES                    18.2#define ENTITY_JUNGLE_LEAVES                   18.3#define ENTITY_ACACIA_LEAVES                161.0#define ENTITY_DARK_OAK_LEAVES                 161.1#define ENTITY_SUNFLOWER                    175.0#define ENTITY_LILAC                           175.1#define ENTITY_DOUBLE_TALL_GRASS               175.2#define ENTITY_LARGE_FERN                      175.3#define ENTITY_POPPY_BUSH                      175.4#define ENTITY_PEONY                           175.5//Waving Vines#define ENTITY_VINES                        106.0//Waving Lava#define ENTITY_LAVA_FLOWING                 10.0#define ENTITY_LAVA_STILL                   11.0//Waving Lilypad#define ENTITY_LILYPAD                      111.0//Others#define ENTITY_COBWEB                       30.0#define ENTITY_WOOL                         35.0#define ENTITY_TORCH                        50.0#define ENTITY_LADDER                       65.0#define ENTITY_IRON_BARS                    101.0#define ENTITY_PAINTING                     323.0#define ENTITY_SIGN                         321.0#define ENTITY_ITEM_FRAME                   389.0//Lit blocks#define ENTITY_FURNACE_LIT                  62.0#define ENTITY_REDSTONE_TORCH               76.0#define ENTITY_JACK_O_LANTERN               91.0#define ENTITY_GLOWSTONE                    89.0#define ENTITY_REDSTONE_LAMP_LIT            124.0#define ENTITY_BEACON                       138.0//Ores#define ENTITY_GOLD_BLOCK                   41.0#define ENTITY_IRON_BLOCK                   42.0#define ENTITY_DIAMOND_BLOCK                57.0#define ENTITY_EMERALD_BLOCK                133.0//Sand#define ENTITY_SAND                         12.0#define ENTITY_SANDSTONE                    24.0#define ENTITY_SANDSTONE_SLAB               44.0#define ENTITY_SANDSTONE_STAIRS             128.0//Stones#define ENTITY_STONE                        1.0#define ENTITY_COBBLE_STONE                 4.0//TFC//Water & Ice#define TFC_ENTITY_SALT_WATER_FLOWING       426.0#define TFC_ENTITY_SALT_WATER_STILL         427.0#define TFC_ENTITY_FRESH_WATER_FLOWING      428.0#define TFC_ENTITY_FRESH_WATER_STILL        429.0#define TFC_ENTITY_HOT_SPRINGS_FLOWING      430.0#define TFC_ENTITY_HOT_SPRINGS_STILL        431.0#define TFC_ENTITY_PACKED_ICE               174.0#define TFC_ENTITY_ICE                      434.0//Waving Grass#define TFC_ENTITY_TALL_GRASS               204.0#define TFC_ENTITY_FERN                        204.1#define TFC_ENTITY_SHORT_GRASS                 204.2#define TFC_ENTITY_SEA_GRASS                435.0//Waving Entities#define TFC_ENTITY_OAK_SAPLING              220.0#define TFC_ENTITY_ASPEN_SAPLING               220.1#define TFC_ENTITY_BIRCH_SAPLING               220.2#define TFC_ENTITY_CHESTNUT_SAPLING            220.3#define TFC_ENTITY_DOUGLAS_FIR_SAPLING         220.4#define TFC_ENTITY_HICKORY_SAPLING             220.5#define TFC_ENTITY_MAPLE_SAPLING               220.6#define TFC_ENTITY_ASH_SAPLING                 220.7#define TFC_ENTITY_PINE_SAPLING                220.8#define TFC_ENTITY_SEQUOIA_SAPLING             220.9#define TFC_ENTITY_SPRUCE_SAPLING              220.10#define TFC_ENTITY_SYCAMORE_SAPLING            220.11#define TFC_ENTITY_WHITE_CEDAR_SAPLING         220.12#define TFC_ENTITY_WHITE_ELM_SAPLING           220.13#define TFC_ENTITY_WILLOW_SAPLING              220.14#define TFC_ENTITY_KAPOK_SAPLING               220.15#define TFC_ENTITY_ACACIA_SAPLING           221.0#define TFC_ENTITY_GOLDENROD                459.0#define TFC_ENTITY_DANDELION                474.0#define TFC_ENTITY_NASTURTIUM                  474.1#define TFC_ENTITY_MEADS_MILKWEED              474.2#define TFC_ENTITY_TROPICAL_MILKWEED           474.3#define TFC_ENTITY_BUTTERFLY_MILKWEED          474.4#define TFC_ENTITY_CALENDULA                   474.5#define TFC_ENTITY_POPPY                    475.0#define TFC_ENTITY_BLUE_ORCHID                 475.1#define TFC_ENTITY_ALLIUM                      475.2#define TFC_ENTITY_HOUSTONIA                   475.3#define TFC_ENTITY_RED_TULIP                   475.4#define TFC_ENTITY_ORANGE_TULIP                475.5#define TFC_ENTITY_WHITE_TULIP                 475.6#define TFC_ENTITY_PINK_TULIP                  475.7#define TFC_ENTITY_DAISY                       475.8#define TFC_ENTITY_RED_APPLE_TREE_SAPLING   4568.0#define TFC_ENTITY_BANANA_TREE_SAPLING         4568.1#define TFC_ENTITY_ORANGE_TREE_SAPLING         4568.2#define TFC_ENTITY_GREEN_APPLE_TREE_SAPLING    4568.3#define TFC_ENTITY_LEMON_TREE_SAPLING          4568.4#define TFC_ENTITY_OLIVE_TREE_SAPLING          4568.5#define TFC_ENTITY_CHERRY_TREE_SAPLING         4568.6#define TFC_ENTITY_PEACH_TREE_SAPLING          4568.7#define TFC_ENTITY_PLUM_TREE_SAPLING           4568.8#define TFC_ENTITY_SAPLINGS                    4571.0//Waving Fire//Waving Leaves & double blocks#define TFC_ENTITY_OAK_LEAVES               218.0#define TFC_ENTITY_FRUIT_LEAVES             235.0#define TFC_ENTITY_CROPS                    472.0#define TFC_ENTITY_FLOWERS                  474.0#define TFC_ENTITY_FLOWERS2                 475.0#define TFC_ENTITY_WINTERGREEN_BUSH         471.0#define TFC_ENTITY_BLUEBERRY_BUSH              471.1#define TFC_ENTITY_RASPBERRY_BUSH              471.2#define TFC_ENTITY_STRAWBERRY_BUSH             471.3#define TFC_ENTITY_BLACKBERRY_BUSH             471.4#define TFC_ENTITY_BUNCHBERRY_BUSH             471.5#define TFC_ENTITY_CRANBERRY_BUSH              471.6#define TFC_ENTITY_SNOWBERRY_BUSH              471.7#define TFC_ENTITY_ELDERBERRY_BUSH             471.8#define TFC_ENTITY_GOOSEBERRY_BUSH             471.9#define TFC_ENTITY_CLOUDBERRY_BUSH             471.10#define TFC_ENTITY_REED                     483.0#define TFC_ENTITY_JUTE                     4555.0//Waving Vines#define TFC_ENTITY_VINES                    487.0//Waving Lava#define TFC_ENTITY_LAVA_FLOWING             432.0#define TFC_ENTITY_LAVA_STILL               433.0//Waving Lilypad#define TFC_ENTITY_LILYPAD                  473.0//Lit blocks#define TFC_ENTITY_FIREPIT                  224.0#define TFC_ENTITY_FORGE                    228.0#define TFC_ENTITY_TORCH                    478.0


Some tips:

1. Extract the shaders zips into your .minecraft\shaderpacks directory and take a copy of them to edit. Edit them whilst minecraft is running, and then switch shaders from the one you're editing to internal and back again to test your changes. You'll see an error message pop up in minecraft if your changes have a syntax error in them. Invalid scripts are ignored by the shader mod, so you can get some strange visuals, but it won't crash minecraft. Much faster than re-loading minecraft.


2. To add TFC Water, you'll need to modify gbuffers_water.vsh. Search for "mc_Entity.x == 9" and add the water id's. Example (note: don't copy the ... lines)

    ...    if(mc_Entity.x == ENTITY_WATER_STILL    || mc_Entity.x == ENTITY_WATER_SOURCE    || mc_Entity.x == TFC_ENTITY_SALT_WATER_FLOWING    || mc_Entity.x == TFC_ENTITY_SALT_WATER_STILL    || mc_Entity.x == TFC_ENTITY_FRESH_WATER_FLOWING    || mc_Entity.x == TFC_ENTITY_FRESH_WATER_STILL    )        ...


3. To add TFC items/blocks and TFC lava, you'll need to modify gbuffers_terrain.vsh. The same approach is used for water (search for "mc_Entity.x == " and replace), but there are a few more conditional statements. Here is an example based on Edi's (I can share other examples if requested).

    #ifdef WAVING_LEAVES    if(mc_Entity.x == ENTITY_LEAVES    || mc_Entity.x == ENTITY_ACACIA_LEAVES    || mc_Entity.x == ENTITY_SUNFLOWER    || mc_Entity.x == TFC_ENTITY_OAK_LEAVES    || mc_Entity.x == TFC_ENTITY_FLOWERS    || mc_Entity.x == TFC_ENTITY_FLOWERS2    || mc_Entity.x == TFC_ENTITY_WINTERGREEN_BUSH    || mc_Entity.x == TFC_ENTITY_JUTE    || mc_Entity.x == TFC_ENTITY_FRUIT_LEAVES    )        ...    #ifdef WAVING_VINES    if(mc_Entity.x == ENTITY_VINES    || mc_Entity.x == TFC_ENTITY_VINES    )        ...    #ifdef WAVING_GRASS    if(mc_Entity.x == ENTITY_SHRUB    || mc_Entity.x == ENTITY_DEAD_BUSH    || mc_Entity.x == TFC_ENTITY_TALL_GRASS    )        ...    #ifdef WAVING_FLOWERS    if(mc_Entity.x == ENTITY_DANDELION    || mc_Entity.x == ENTITY_ROSE    || mc_Entity.x == ENTITY_CARROTS    || mc_Entity.x == ENTITY_POTATOES    || mc_Entity.x == TFC_ENTITY_OAK_SAPLING    || mc_Entity.x == TFC_ENTITY_ACACIA_SAPLING    || mc_Entity.x == TFC_ENTITY_GOLDENROD    || mc_Entity.x == TFC_ENTITY_DANDELION    || mc_Entity.x == TFC_ENTITY_POPPY    )        ...    #ifdef WAVING_WHEAT    if(mc_Entity.x == ENTITY_WHEAT    || mc_Entity.x == ENTITY_OAK_SAPLING    || mc_Entity.x == TFC_ENTITY_RED_APPLE_TREE_SAPLING    || mc_Entity.x == TFC_ENTITY_SAPLINGS    || mc_Entity.x == TFC_ENTITY_CROPS    )        ...    #ifdef WAVING_FIRE    if(mc_Entity.x == ENTITY_FIRE    )        ...    #ifdef WAVING_LAVA    if(mc_Entity.x == ENTITY_LAVA_FLOWING    || mc_Entity.x == ENTITY_LAVA_STILL    || mc_Entity.x == TFC_ENTITY_LAVA_FLOWING    || mc_Entity.x == TFC_ENTITY_LAVA_STILL    )         ...    #ifdef WAVING_LILYPAD    if(mc_Entity.x == ENTITY_LILYPAD    || mc_Entity.x == TFC_ENTITY_LILYPAD    )         ...

4. Change composite.vsh/composite.fsh to change night shadow distance, torch, sun/night color. Most of them have comments explaining these. There is also some hand held item logic in these scripts too.


5. TFC seagrass blocks are attached to the ground below them, so if you add them to one of the wave conditional statment in pt 3, then you'll see sky color in the ocean as the ground waves. I think a new wave function is needed to change this behaviour. Let me know if you figure it out, as I didn't have any luck.


6. mc_Entity.x is rounded up to nnnn.0. This means the sub entities are not useable in the vsh/fsh scripts and only nnnn.0 items are relevant for if statements. So you can refer to ENTITY_SHRUB (31.0) in an if statement and it will also apply to ENTITY_GRASS (31.1) and ENTITY_FERN (31.2). I only found this out half way through modifying the scripts, so left the sub entities in the define list in case I need them in the future.

Edited by SilverFly

Share this post

Link to post
Share on other sites

Edit: Moved content to separate post, I moved too far away from the topic.

Edited by Saiden

Share this post

Link to post
Share on other sites
On October 18, 2014 at 9:28 PM, AHrubik said:

This fixes the waving leaves, waving grass, crops, flowers and saplings for TFC 79.x (MC 1.7.10). These are in the "gbuffers_terrain.vsh" file. Search for "WAVING_GRASS", "WAVING_LEAVES", "WAVING_WHEAT" (crops), "WAVING_FLOWERS" and "WAVING_SAPLINGS" respectively.

Waving Grass || mc_Entity.x == 204.0 || mc_Entity.x == 204.2 || mc_Entity.x == 435.0 || mc_Entity.x == 435.1 || mc_Entity.x == 435.2 || mc_Entity.x == 435.3 || mc_Entity.x == 435.4 || mc_Entity.x == 435.5 || mc_Entity.x == 435.6 || mc_Entity.x == 435.7 || mc_Entity.x == 435.8 || mc_Entity.x == 435.9 || mc_Entity.x == 435.10 || mc_Entity.x == 435.11 || mc_Entity.x == 435.12 || mc_Entity.x == 435.13 || mc_Entity.x == 435.14 || mc_Entity.x == 435.15Waving Leaves || mc_Entity.x == 218.0 || mc_Entity.x == 218.1 || mc_Entity.x == 218.2 || mc_Entity.x == 218.3 || mc_Entity.x == 218.4 || mc_Entity.x == 218.5 || mc_Entity.x == 218.6 || mc_Entity.x == 218.7 || mc_Entity.x == 218.8 || mc_Entity.x == 218.9 || mc_Entity.x == 218.10 || mc_Entity.x == 218.11 || mc_Entity.x == 218.12 || mc_Entity.x == 218.13 || mc_Entity.x == 218.14 || mc_Entity.x == 218.15 || mc_Entity.x == 219.0 || mc_Entity.x == 219.1
Crops "WAVING_WHEAT" || mc_Entity.x == 472.0  Flowers || mc_Entity.x == 474.0 || mc_Entity.x == 474.1 || mc_Entity.x == 474.2 || mc_Entity.x == 474.3 || mc_Entity.x == 474.4 || mc_Entity.x == 474.5 || mc_Entity.x == 475.0 || mc_Entity.x == 475.1 || mc_Entity.x == 475.2 || mc_Entity.x == 475.3 || mc_Entity.x == 475.4 || mc_Entity.x == 475.5 || mc_Entity.x == 475.6 || mc_Entity.x == 475.7 || mc_Entity.x == 475.8 || mc_Entity.x == 459.0Saplings || mc_Entity.x == 4571.0 || mc_Entity.x == 4571.1 || mc_Entity.x == 4571.2 || mc_Entity.x == 4571.3 || mc_Entity.x == 4571.4 || mc_Entity.x == 4571.5 || mc_Entity.x == 4571.6 || mc_Entity.x == 4571.7 || mc_Entity.x == 4571.8 

In the file composite.fsh edit the following line as shown to help with torch light color. Picture available by following the URL.

HI, i've used this before to fix the shaders and make them work for tic, but I lost that shader pack about 6 months ago(it was deleted) and now I'm trying to do it again but for some reason it no longer works, and nothing moves or waves, just wondering what I'm doing wrong or if is a new more recent way I need to do it.


Share this post

Link to post
Share on other sites

I'm using the modpack "TechNodeFirmaCraft" on ATLauncher, with TFC version 0.79.28, and the water IDs are different to what I've seen posted here. The IDs start at 537 and upwards. I just spent the last 5 hours trying to make mods work, so I hope this helps people get to a solution faster. Also, while I'm here I'm just gonna confirm that this does indeed work with MrMeepz Shaders v05, and the line that has to be edited in gbuffers_water.vsh is line 64.

Well, I think an appropriate way to leave off for now would be this quote:

"Engineers like to solve problems. If there are no problems readily available, they will create their own problems." -Scott Adams


Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now