Jump to content

Recommended Posts

Posted

Hey there, I was just wondering if ANSI is still supported for newer versions of the forge server. I had an RLCraft 1.12.2 Server that supported color within the command prompt window right off the bat with no extra commands, but when I try to run a forge 1.16.5 server, it simply does not output color into the console. I have tried manually enabling ANSI for CMD in my Registry but even that doesn't work. Have you stopped supporting color or is there a way to enable it? Thank you.

 

In the first image, you'll see my 1.16.5 server running without color. The command I used to start it was 

:start
java -Xmx8192M -Xms1024M -jar forge-1.16.5-36.1.0.jar nogui
timeout /t 10 /nobreak
goto start

1783300204_nocolor.thumb.png.b6c002ec7dc6a81212c5902268fe390e.png

 

 

 

The second image is a 1.12.2 RLCraft Server. The command used to start that one was 

@echo off
java -Xmx6G -Xms4G -jar forge-1.12.2-14.23.5.2838-universal.jar nogui
PAUSE

color.thumb.png.ad3cf38f8c0aeb1edb082a782f75c083.png

There are no special parameters that are added to the batch file to start that would enable color. I am lost.

Posted (edited)

I have zero clue on how to use that program. Is there a more simplified method? Also, did RLCraft do something special with the forge server to make it automatically produce color within command prompt or am I missing something?

Edited by LunarCama
explained more and asked question
Posted

Its a library forge uses...

That looks for environment variables, as stated in the readme...

Just set the environment variables..

No idea what RLCraft is or what it does. But it probably sets those environment variables...

As described in the readme... That I linked...

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

  • 11 months later...
Posted

It took me a while to respond back to this, but I figured out what the issue was.

On Windows, I had to edit a registry key to enable ANSI and only THEN did the flags for color work!

I also managed to get it to work on the latest 1.18.2 Forge server as well (The new JVM argument thing is strange, but I kind of like that it's kept in a separate file. What is the reasoning behind that?)

 

 

BTW, here is the registry key to add/change for other people who want color in their console!
[HKEY_CURRENT_USER\Console]
"VirtualTerminalLevel"=dword:00000001

After it's enabled, add these flags to your start.bat or user_jvm_args.txt
-Dterminal.keepMinecraftFormatting=true -Dterminal.jline=true -Dterminal.ansi=true

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  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.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • Im trying to build my mod using shade since i use the luaj library however i keep getting this error Reason: Task ':reobfJar' uses this output of task ':shadowJar' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. So i try adding reobfJar.dependsOn shadowJar  Could not get unknown property 'reobfJar' for object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler. my gradle file plugins { id 'eclipse' id 'idea' id 'maven-publish' id 'net.minecraftforge.gradle' version '[6.0,6.2)' id 'com.github.johnrengelman.shadow' version '7.1.2' id 'org.spongepowered.mixin' version '0.7.+' } apply plugin: 'net.minecraftforge.gradle' apply plugin: 'org.spongepowered.mixin' apply plugin: 'com.github.johnrengelman.shadow' version = mod_version group = mod_group_id base { archivesName = mod_id } // Mojang ships Java 17 to end users in 1.18+, so your mod should target Java 17. java.toolchain.languageVersion = JavaLanguageVersion.of(17) //jarJar.enable() println "Java: ${System.getProperty 'java.version'}, JVM: ${System.getProperty 'java.vm.version'} (${System.getProperty 'java.vendor'}), Arch: ${System.getProperty 'os.arch'}" minecraft { mappings channel: mapping_channel, version: mapping_version copyIdeResources = true runs { configureEach { workingDirectory project.file('run') property 'forge.logging.markers', 'REGISTRIES' property 'forge.logging.console.level', 'debug' arg "-mixin.config=derp.mixin.json" mods { "${mod_id}" { source sourceSets.main } } } client { // Comma-separated list of namespaces to load gametests from. Empty = all namespaces. property 'forge.enabledGameTestNamespaces', mod_id } server { property 'forge.enabledGameTestNamespaces', mod_id args '--nogui' } gameTestServer { property 'forge.enabledGameTestNamespaces', mod_id } data { workingDirectory project.file('run-data') args '--mod', mod_id, '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/') } } } sourceSets.main.resources { srcDir 'src/generated/resources' } repositories { flatDir { dirs './libs' } maven { url = "https://jitpack.io" } } configurations { shade implementation.extendsFrom shade } dependencies { minecraft "net.minecraftforge:forge:${minecraft_version}-${forge_version}" implementation 'org.luaj:luaj-jse-3.0.2' implementation fg.deobf("com.github.Virtuoel:Pehkui:${pehkui_version}") annotationProcessor 'org.spongepowered:mixin:0.8.5:processor' minecraftLibrary 'luaj:luaj-jse:3.0.2' shade 'luaj:luaj-jse:3.0.2' } // Example for how to get properties into the manifest for reading at runtime. tasks.named('jar', Jar).configure { manifest { attributes([ 'Specification-Title' : mod_id, 'Specification-Vendor' : mod_authors, 'Specification-Version' : '1', // We are version 1 of ourselves 'Implementation-Title' : project.name, 'Implementation-Version' : project.jar.archiveVersion, 'Implementation-Vendor' : mod_authors, 'Implementation-Timestamp': new Date().format("yyyy-MM-dd'T'HH:mm:ssZ"), "TweakClass" : "org.spongepowered.asm.launch.MixinTweaker", "TweakOrder" : 0, "MixinConfigs" : "derp.mixin.json" ]) } rename 'mixin.refmap.json', 'derp.mixin-refmap.json' } shadowJar { archiveClassifier = '' configurations = [project.configurations.shade] finalizedBy 'reobfShadowJar' } assemble.dependsOn shadowJar reobf { re shadowJar {} } publishing { publications { mavenJava(MavenPublication) { artifact jar } } repositories { maven { url "file://${project.projectDir}/mcmodsrepo" } } }  
    • All versions of Minecraft Forge suddenly black screen even without mods (tried reinstalling original Minecraft, Java, updating drivers doesn't work)
    • When i join minecraft all ok, when i join world all working fine, but when i open indentity menu, i get this The game crashed whilst unexpected error Error: java.lang.NullPointerException: Cannot invoke "top.ribs.scguns.common.Gun$Projectile.getDamage()" because "this.projectile" is null crash report here https://paste.ee/p/0vKaf
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.