.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $6.00

   







Go Back   .com.unity Forums > Shrapnel Community > Space Empires: IV & V

Reply
 
Thread Tools Display Modes
  #21  
Old October 31st, 2006, 03:25 PM

Devnullicus Devnullicus is offline
Sergeant
 
Join Date: Feb 2001
Location: Belmont, CA USA
Posts: 285
Thanks: 0
Thanked 0 Times in 0 Posts
Devnullicus is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

Quote:
Elsemeravin said:

I think I got it. My computer has is expecting ',' as decimal separator instead of '.' and then when your program meets a decimal number in formula it will not process correctly.

But I'm not sure if you could force the decimal separator in your code to be '.' instead of windows default one ?
Oh! Heh, fancy programming bites me in the ***, I see. I was trying to be "smart" and have the formula parser recognize regional settings. Obviously, I need to rethink that and turn that off

Thanks for finding this!
__________________
How's my Programming? Call 1-800-DEV-NULL
Get the Space Empires V Editor and DevnullMod at http://www.devnullsoftware.com/se5
Reply With Quote
  #22  
Old October 31st, 2006, 03:55 PM

Elsemeravin Elsemeravin is offline
Corporal
 
Join Date: Nov 2001
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Elsemeravin is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

Quote:
Devnullicus said:
Oh! Heh, fancy programming bites me in the ***, I see. I was trying to be "smart" and have the formula parser recognize regional settings. Obviously, I need to rethink that and turn that off


Don't worry too much, I changed the regional setting to use '.' I should have done that long time ago already, so now it's done for good.

I think you should focus on component design first (and then tech areas ! with a nice tree representation)
Reply With Quote
  #23  
Old October 31st, 2006, 04:22 PM

skigrinder skigrinder is offline
Private
 
Join Date: May 2001
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
skigrinder is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

Fyron,
Thanx for the response.
I'll take a look at the moon offset / same as idea.

The idea of creating planets in SE with 10+ moons (like those in our own solar system) has always intrigued me.

I like the idea of colonizing the moons, building cargo facilities and filling them with weapons platforms for planetary defense. However, this makes no sense if the moons are in a different sector.

An editor tool for the SEV map files (similar to DevNull's facilities editor) would be very useful as the text files are pretty complicated.

Thanx,
skigrinder
Reply With Quote
  #24  
Old November 2nd, 2006, 02:03 AM

Devnullicus Devnullicus is offline
Sergeant
 
Join Date: Feb 2001
Location: Belmont, CA USA
Posts: 285
Thanks: 0
Thanked 0 Times in 0 Posts
Devnullicus is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

Elsemeravin: I'm trying to fix the error you (and others) have gotten with regional settings. However, I can't seem to reproduce the error on my computer. What are your regional settings (i.e. what did you change to make the problem go away, and what was the old value that was causing the problem)?
__________________
How's my Programming? Call 1-800-DEV-NULL
Get the Space Empires V Editor and DevnullMod at http://www.devnullsoftware.com/se5
Reply With Quote
  #25  
Old November 2nd, 2006, 04:21 AM

Elsemeravin Elsemeravin is offline
Corporal
 
Join Date: Nov 2001
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Elsemeravin is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

In the national setting from configuration panel, go to customise button (right of national name), then change the decimal separator (sorry I don't remember the exact name for the english version), and change from '.' to ','.

Then apply.
Reply With Quote
  #26  
Old November 2nd, 2006, 05:11 AM

Devnullicus Devnullicus is offline
Sergeant
 
Join Date: Feb 2001
Location: Belmont, CA USA
Posts: 285
Thanks: 0
Thanked 0 Times in 0 Posts
Devnullicus is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

ok, got it. Man, what a pain in the ***. Turns out I was correctly NOT using regional settings when parsing the formula, BUT C# was using them anyway when doing a Convert. So, it was doing very strange things with . and , characters when the regional settings were different.

The fix was to just set the app settings to en-US Number Formatting. Figuring out how to DO that, however, was a real pain in the ***. Ah well, it should work now.

Just in case any other C# programmers want to know how to force an application to use US number formatting no matter what the user's regional settings are, here's some code

Code:

CultureInfo currentCultureInfo = Thread.CurrentThread.CurrentCulture;
CultureInfo cultureInfo = (CultureInfo)currentCultureInfo.Clone();
NumberFormatInfo nfi = new CultureInfo( "en-US", false ).NumberFormat;
cultureInfo.NumberFormat = nfi;
Thread.CurrentThread.CurrentCulture = cultureInfo;



Wouldn't be nearly so annoyingly difficult to figure out if the system didn't make the original settings read-only so that I had to clone them. Sheesh.
__________________
How's my Programming? Call 1-800-DEV-NULL
Get the Space Empires V Editor and DevnullMod at http://www.devnullsoftware.com/se5
Reply With Quote
  #27  
Old November 2nd, 2006, 06:08 PM

Elsemeravin Elsemeravin is offline
Corporal
 
Join Date: Nov 2001
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Elsemeravin is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

Now that you solved this problem what about the component editor ?
Reply With Quote
  #28  
Old November 2nd, 2006, 06:12 PM

Phoenix-D Phoenix-D is offline
National Security Advisor
 
Join Date: Nov 2000
Posts: 5,085
Thanks: 0
Thanked 0 Times in 0 Posts
Phoenix-D is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

http://www.shrapnelcommunity.com/thr...b=5&o=&fpart=1

He beat you to it by about 6 minutes..
__________________
Phoenix-D

I am not senile. I just talk to myself because the rest of you don't provide adequate conversation.
-Digger
Reply With Quote
  #29  
Old November 2nd, 2006, 06:14 PM

Devnullicus Devnullicus is offline
Sergeant
 
Join Date: Feb 2001
Location: Belmont, CA USA
Posts: 285
Thanks: 0
Thanked 0 Times in 0 Posts
Devnullicus is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

Quote:
Phoenix-D said:
http://www.shrapnelcommunity.com/thr...b=5&o=&fpart=1

He beat you to it by about 6 minutes..
HA!
__________________
How's my Programming? Call 1-800-DEV-NULL
Get the Space Empires V Editor and DevnullMod at http://www.devnullsoftware.com/se5
Reply With Quote
  #30  
Old November 2nd, 2006, 07:07 PM

Elsemeravin Elsemeravin is offline
Corporal
 
Join Date: Nov 2001
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Elsemeravin is on a distinguished road
Default Re: Space Empires V Editor 1.0 released

Quote:
Devnullicus said:
Quote:
Phoenix-D said:
http://www.shrapnelcommunity.com/thr...b=5&o=&fpart=1

He beat you to it by about 6 minutes..
HA!
So next step:

"Now that the component editor is done, what about the tech tree editor ?"
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 06:33 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2024, Shrapnel Games, Inc. - All Rights Reserved.