Jump to content
  • Home
  • Files
  • Docs
  • Merch
Topics
  • All Content

  • This Topic
  • This Forum

  • Advanced Search
  • Existing user? Sign In  

    Sign In



    • Not recommended on shared computers


    • Forgot your password?

  • Sign Up
  • All Activity
  • Home
  • Mod Developer Central
  • Modder Support
  • System.out.printf stopped working....?!?
1.13 Update Notes for Mod Creators
Sign in to follow this  
Followers 0
TheyCallMeDanger

System.out.printf stopped working....?!?

By TheyCallMeDanger, March 22, 2013 in Modder Support

  • Reply to this topic
  • Start new topic

Recommended Posts

TheyCallMeDanger    1

TheyCallMeDanger

TheyCallMeDanger    1

  • Stone Miner
  • TheyCallMeDanger
  • Members
  • 1
  • 73 posts
Posted March 22, 2013

Up until the latest Forge for mc 1.5, System.out.printf() used to print nicely on my eclipse console.

With this latest update, it just stopped. No output anymore. Sorry, but I'm old-school, and

that's what i use to debug and see what's going on...

 

Anyone know how to make System.out.printf() work again?

 

Thanks!

 

  • Quote

Share this post


Link to post
Share on other sites

Chibill    9

Chibill

Chibill    9

  • Dragon Slayer
  • Chibill
  • Forge Modder
  • 9
  • 584 posts
Posted March 22, 2013

That's a java function not forge.

  • Quote

Share this post


Link to post
Share on other sites

jordan30001    15

jordan30001

jordan30001    15

  • Creeper Killer
  • jordan30001
  • Members
  • 15
  • 157 posts
Posted March 22, 2013

Up until the latest Forge for mc 1.5, System.out.printf() used to print nicely on my eclipse console.

With this latest update, it just stopped. No output anymore. Sorry, but I'm old-school, and

that's what i use to debug and see what's going on...

 

Anyone know how to make System.out.printf() work again?

 

Thanks!

 

I love how your signature says

 

"Odds are good I've been programming since before you were born. Yeah. I'm OLD school."

 

yet you think System.out.printf() not working is somehow forge's problem?

 

Just tested the following code in my mod

 

System.out.printf( "%-15s %10s %n", "Exam_Name", "Exam_Grade");

System.out.printf( "%-15s %10s %n", "English", "A");

System.out.printf( "%-15s %10s %n", "French", "F");

System.out.printf( "%-15s %10s %n", "Science", "C");

System.out.printf( "%-15s %10s %n", "Geography", "FAIL");[/code]

 

and my output was

2013-03-22 05:53:26 [iNFO] [sTDOUT] Exam_Name       Exam_Grade 
2013-03-22 05:53:26 [iNFO] [sTDOUT] English              A 
2013-03-22 05:53:26 [iNFO] [sTDOUT] French               F 
2013-03-22 05:53:26 [iNFO] [sTDOUT] Science              C 
2013-03-22 05:53:26 [iNFO] [sTDOUT] Geography            FAIL 

 

You must have either done something wrong as you have posted no code I don't know that.

 

or you found a bug in the Java SDK thus your on the wrong forums.

  • Quote

Share this post


Link to post
Share on other sites

TheyCallMeDanger    1

TheyCallMeDanger

TheyCallMeDanger    1

  • Stone Miner
  • TheyCallMeDanger
  • Members
  • 1
  • 73 posts
Posted March 22, 2013

Up until the latest Forge for mc 1.5, System.out.printf() used to print nicely on my eclipse console.

With this latest update, it just stopped. No output anymore. Sorry, but I'm old-school, and

that's what i use to debug and see what's going on...

 

Anyone know how to make System.out.printf() work again?

 

Thanks!

 

I love how your signature says

 

"Odds are good I've been programming since before you were born. Yeah. I'm OLD school."

 

yet you think System.out.printf() not working is somehow forge's problem?

 

Just tested the following code in my mod

 

System.out.printf( "%-15s %10s %n", "Exam_Name", "Exam_Grade");

System.out.printf( "%-15s %10s %n", "English", "A");

System.out.printf( "%-15s %10s %n", "French", "F");

System.out.printf( "%-15s %10s %n", "Science", "C");

System.out.printf( "%-15s %10s %n", "Geography", "FAIL");[/code]

 

and my output was

2013-03-22 05:53:26 [iNFO] [sTDOUT] Exam_Name       Exam_Grade 
2013-03-22 05:53:26 [iNFO] [sTDOUT] English              A 
2013-03-22 05:53:26 [iNFO] [sTDOUT] French               F 
2013-03-22 05:53:26 [iNFO] [sTDOUT] Science              C 
2013-03-22 05:53:26 [iNFO] [sTDOUT] Geography            FAIL 

 

You must have either done something wrong as you have posted no code I don't know that.

 

or you found a bug in the Java SDK thus your on the wrong forums.

 

Interesting... Your printf output was redirected through the forge logging mechanism.

I'll poke around through the logging functions. Apparently they redirected STDOUT.

Probably a logging option I can turn on/off somewhere.

 

In any event. No, your java printf did not work. It did not come out through the normal

console output mechanism, which is what it used to do...

 

Thanks for the hint!

 

 

  • Quote

Share this post


Link to post
Share on other sites

TheyCallMeDanger    1

TheyCallMeDanger

TheyCallMeDanger    1

  • Stone Miner
  • TheyCallMeDanger
  • Members
  • 1
  • 73 posts
Posted March 22, 2013

Ah yes... They did. They redirected stdout and stderr. Awfully nice of them.

 

Comment out lines 190 and 191 in FMLRelaunchLog.java:

      //System.setOut(new PrintStream(new LoggingOutStream(stdOut), true));

        //System.setErr(new PrintStream(new LoggingOutStream(stdErr), true));

 

System.out.printf() works fine again.

 

Yes, I know this is not what they want me to do, but since I can't find anything on how to set up

logging properly as they intended... It even appears that they tried to automatically

initialize logging into logfiles under each mod name. Doesn't appear to work though,

at least not for me.

 

 

Dear Forge:

 

Could ya'll put the default outputs back so that mods with uninitialized logging can still get

the standard System.out.printf()? That would be sweet... Thanks!

 

 

  • Quote

Share this post


Link to post
Share on other sites

Creeperologist    1

Creeperologist

Creeperologist    1

  • Tree Puncher
  • Creeperologist
  • Members
  • 1
  • 18 posts
Posted March 23, 2013

It was a 1.5 issue, but it was fixed in 1.5.1, just update your mcp and forge and it will fix it

 

I had the issue myself earlier, but that fixes it

 

 

  • Quote

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Insert image from URL
×
  • Desktop
  • Tablet
  • Phone
Sign in to follow this  
Followers 0
Go To Topic Listing



  • Recently Browsing

    No registered users viewing this page.

  • Posts

    • salvestrom
      [1.14.4] How to get Minecraft Horse model/texture to make a custom unicorn?

      By salvestrom · Posted 38 minutes ago

      Also, your model renderer should extend abstract horse renderer, not mob renderer.
    • salvestrom
      [1.14.4] How to get Minecraft Horse model/texture to make a custom unicorn?

      By salvestrom · Posted 42 minutes ago

      Remove this and put this in the constructor super "new UnicornModel<>(0)". The model file has to extend HorseModel Or you will not get the animations. In the renderer Create:      And return "unicorn" in getEntityTexture. ");
    • Oliviafrostpaw
      [1.14.4] Injecting into Existing Loot Tables, Blocks

      By Oliviafrostpaw · Posted 58 minutes ago

      So, I have attempted with changing the whole class EventBusSubscriber to being Forge, which didnt trigger the event, I attempted creating a new class inside of the main class that has the Forge Subscriber, tried with having no conditions on the Mod.EventBusSubscriber, and finally tried with a whole new class, InjectionHandler.java, that has Mod.EventBusSubscriber with and without Mod.EventBusSubscriber.Bus.FORGE as a condition and just the onLootLoad function inside and still didnt trigger So Im about as lost as before. Once again, apologies for my lack of knowledge about the EventBus Intricacies. Spent the time the last few days and few hours searching for examples and other peoples questions on the topic and never came up with much conclusive
    • AdieCraft
      Santa's Christmas Sleigh (Complete with Rudolph and Reindeer)

      By AdieCraft · Posted 1 hour ago

      Hello there!   Welcome back to AdieCraft! Today's video is a festive one in the Christmas Builds series, looking at how to build a Santa's Sleigh, which you can ride in and the Reindeer pulling it. Check it out.   Watch the Santa's Christmas Sleigh video here    
    • Grain Mush
      Failed to download file

      By Grain Mush · Posted 1 hour ago

      Fixed the problem when I deleted the forge version in my versions folder and reinstalled.
  • Topics

    • DragonITA
      43
      [1.14.4] How to get Minecraft Horse model/texture to make a custom unicorn?

      By DragonITA
      Started Monday at 10:06 AM

    • Oliviafrostpaw
      12
      [1.14.4] Injecting into Existing Loot Tables, Blocks

      By Oliviafrostpaw
      Started December 8

    • AdieCraft
      0
      Santa's Christmas Sleigh (Complete with Rudolph and Reindeer)

      By AdieCraft
      Started 1 hour ago

    • Grain Mush
      6
      Failed to download file

      By Grain Mush
      Started December 1

    • plugsmustard
      0
      JSON questions

      By plugsmustard
      Started 1 hour ago

  • Who's Online (See full list)

    • athy
    • J0WAY
    • Alatyami
    • Redstoneguy129
    • PrinceRaiden
    • T_VDP
    • camramjam07
    • TehStoneMan
    • Memelord679
    • CAS_ual_TY
    • Electrodynamite12
    • _alycia_riley_
    • AdieCraft
  • All Activity
  • Home
  • Mod Developer Central
  • Modder Support
  • System.out.printf stopped working....?!?
  • Theme
  • Contact Us
  • Discord

Copyright © 2019 ForgeDevelopment LLC · Ads by Curse Powered by Invision Community