Closed StickieBE closed 7 years ago
It seems like one error in your description.ext is propagating to the rest of the import process. Can you include an example from your description.ext of where a color couldn't be imported correctly? Thanks.
@kayler-renslow Tried with the latest TFAR build and spits out the same errors. I included a bunch of screenshots. The color values are never filled in as the colors in all my files are as stated above, the correct format.
colorText[] = { 0.05 , 0.05 , 0.05 , 1.0 };
Above syntax is correct; your color picker however wrongly converts them to comma's. https://prnt.sc/g8xvwt
Are you outside the U.S. by chance? I know that in some countries, like Spain, they use periods instead of comma's to separate 1000's place (1,000 in U.S. is 1.000 in Spain for example)
I'm thinking Java's internal toString stuff is compensating for that.
Belgium, dot keyboard. You may remote control to debug if needed.
I just checked the code and I can confirm that it is implemented correctly. This must be Java's nativity stuff.
Wow this is a fascinating bug. lol
You're not alone :)
return String.format(Locale.ROOT, "%.2f", someDouble);
https://stackoverflow.com/questions/5236056/force-point-as-decimal-separator-in-java
Current Java code, for future reference (non developers can ignore):
DecimalFormat format = new DecimalFormat("#.####");
//this method, combined with DecimalFormat, is creating commas instead of periods
String toString(double red, double green, double blue, double alpha) {
return "{" + format.format(red) + ","
+ format.format(green) + ","
+ format.format(blue) + ","
+ format.format(alpha) + "}";
}
This is the most beautiful bug. I'm surprised I figured this out so fast
Thanks for pointing this issue out.
Yup, good hunch there ;)
Hope u don't mind me even posting the smaller non-breaking issues. As the 'missing controls' one. Love the project, am here to help out where I can.
I really like the bug reports, including the trivial ones. A trivial bug report has helped me solve a major bug in the past before. Keep them coming.
This issue will take a while to fix. :O
Will do then! Good luck.
I have a workaround for this issue until it's resolved.
Steps:
adc.jar
java -jar -Duser.country=US -Duser.language=en adc.jar
start_adc.bat
like it's a normal executableWhat this is doing is telling Java to ignore the JVM's internal default locale and set it to the US. If you happen to be using linux, you could just create a sh file with the same code and run that.
This will also create a command window. It may print errors and stuff to the console. You can ignore anything in the console because the errors that matter are reported to the user.
Will do, thanks for letting me know. I shall ignore any issues popping up (in case they are related to changing locale?) until next release.
You can report issues, but I would appreciate it if they were only the errors that appear in the Dialog Creator's windows. Sometimes I print stuff to the console that isn't shown to the user.
https://github.com/kayler-renslow/arma-dialog-creator/commit/a7e43a24f137d0c69ca38ca964702f6663ec8b8e Includes a fix for the Notifications throwing IllegalStateException
Fixed the comma vs period issue in https://github.com/kayler-renslow/arma-dialog-creator/commit/d837f156221979cab42de58cb38d0d337a5549e8
fixed in release 1.0.2
Screenshot: https://prnt.sc/g8yjtq More screenshots from the errors themselves, as I can't copy+paste them. https://prnt.sc/g8ylfl https://prnt.sc/g8ylj4 https://prnt.sc/g8ylon
Log: https://pastebin.com/Rtxump6E
Importing works, but spits out errors when opening a dialog. I think this could also be related to: https://prnt.sc/g8xvwt Note how when creating custom classes the alpha gets added as 1,0 (comma) where it should be 1.0 (dot) iirc. Faulty => { 1.0 , 1.0 , 1.0 , 0,1 }; Correct => { 1.0 , 1.0 , 1.0 , 0.1 };