#Graphical glitch on 50.01

1 messages · Page 1 of 1 (latest)

polar scaffold
#

Hi im new to megamek and installed dev version. It's running with temurin 17 and unzipped by 7-zip.
I have this supperposition graphical glitch, did I do something wrong ?

sly grotto
#

!visual-artifacts

storm gustBOT
#

BattleTech Visual Distortion Field Calibration
Experiencing graphical glitches or distortions in the heat of your Mech battles? Your MechTech team has some tweaks to realign your HUD:

:hammer_and_wrench: Adjust Your System's Visual Settings:

First Step: Ensure you're using a quality text editor like Notepad++ to make these adjustments. This will help avoid formatting issues that can occur with more basic editors.

Edit the Megamek.l4j.ini and Mekhq.l4j.ini files in your game directory with the following flags, tailored to your system's memory:

For Standard Systems (8-16 Gig):

  • -Xmx2048m -Dsun.java2d.d3d=false
  • Or, use -Xmx2048m -Dsun.java2d.opengl=true for OpenGL support.

For Advanced Systems (16 Gig):

  • -Xmx4096m -Dsun.java2d.d3d=false
  • Or, -Xmx4096m -Dsun.java2d.opengl=true

For High-End Systems (32 Gig):

  • -Xmx8192m -Dsun.java2d.d3d=false
  • Or, -Xmx8192m -Dsun.java2d.opengl=true

UI Scaling Issues?
Some MechWarriors have achieved clarity with -Dsun.java2d.uiScale=1.

:notebook_with_decorative_cover: Instructions:

  1. Locate the .l4j.ini file for MegaMek or MekHQ in your installation folder.
  2. Open it with Notepad++ or another quality text editor.
  3. Add the appropriate flag(s) based on your system's memory.
  4. Save the changes and restart the game.

If distortions persist in your Mech's cockpit, report to your nearest MechTech for further diagnostics. Your contributions help keep the Inner Sphere's technology at the cutting edge!

polar scaffold
sly grotto
#

notepad is fine

polar scaffold
#

Ok ty

#

Still having it, are the flags correctly written ? I have 32Gb Ram

sly grotto
#

are you starting megamek from mekhq? if so need to update the mekhq ini also

polar scaffold
#

Mekhq has stricly the same parameters

sly grotto
#

also need to restart completely

polar scaffold
#

I edited them

#

Also done

sly grotto
#

i usually put this on a new line -Dsun.java2d.d3d=false instead of after the other part

polar scaffold
#

Ok I will try

#

By the way 8192 is only tied to RAM or do I need to also take into account CPU and GPU power ?

sly grotto
#

just ram

polar scaffold
#

Im also launching with jar on windows but that should not be an issue

sly grotto
#

that is probably the issue think you would need to pass in these as parameters

polar scaffold
#

Which parameters

#

?

sly grotto
#

the ones in the ini file

polar scaffold
#

So what should I do, run with exe instead ?

sly grotto
#

run MegaMek.exe

#

or MekHQ.exe

polar scaffold
#

Ok, and keeping updated ini files you gave me

sly grotto
#

the exe file uses the ini file adjust the java parameters

polar scaffold
#

what is the name of java's "ini files" ?

sly grotto
#

MegaMek.l4j.ini and MekHQ.l4j.ini

polar scaffold
#

I am confused I already edited those ones, and you said they only affected the exe version. So how can I fix the jar version ?

sly grotto
#

not sure how to fix running for the jar. I was just explain how the exe works

polar scaffold
#

Ok I will stick to exe version

frosty fossil
#

The EXE versio is the JAR version but the stuff in the INI file gets appended into a single line and passed to the JAR version.

#

The EXE is just to make it easier for Windows users. Same with the shell scripts for Linux users.

sour isle
#

basically the equivalent of a batch script

polar scaffold
frosty fossil
#

It's all the same version, just a different way to load it

polar scaffold
#

Oh ok, so launching via jar is the more direct way to do it

#

But since I need ini files to fix artifacts, I will not be able to fix the jar version or is there a way ?

frosty fossil
#

You can do the Jar version if you pass the same arguments to the java run time before the -jar command.

#

That's all the EXE is doing.

polar scaffold
frosty fossil
#

java <arguments> -jar MegaMek.jar

polar scaffold
#

Ok so in my case I need to go to the shell and run the following command :
java -Xmx8192m -Dsun.java2d.d3d=false -jar MegaMek.jar

frosty fossil
#

If you want to run from the shell, yes.

polar scaffold
#

Managed to make both java2d commands work

#

These are the error messages responsible for the weird duplicates, does someone have a fix ?

#

I am using a .bat file of this content :

cd "C:\Users\myself\Documents\myGames\MekHQ-0.50.01"
java -Xmx8192m -Dsun.java2d.d3d=false -Dsun.java2d.noddraw=true -jar MegaMek.jar