View Issue Details

IDProjectCategoryLast Update
0002123AI War 1 / ClassicSuggestionJan 3, 2011 11:44 am
ReporterTechSY730 Assigned Tokeith.lamothe  
Status closedResolutionnot fixable 
Product Version4.054 
Summary0002123: Passing Parameters to the Underlying Runtime Environment
DescriptionIIRC correctly, Mono supports managed languages, meaning there is a runtime environment that takes care of things like memory management. Also, there is of course the Unity layer as well. Can those take nifty tweaking parameters like Sun's Java implementation can? I've seen many stand alone Java programs that on their command line can pass along raw command parameters (like memory sizes and garbage collection parameters) to the underlying JVM.
Is there a way to do this with AI War (and also Tidalis)? There will of course be sensible defaults. But this way those who want AI war to be able to have ALOT of memory can increase the max heap size, but those who do not want this can leave it as the default or even reduce the max heap size.
If you are making assumptions about the exact amount of memory you have available (beyond a sensible minimum), you are doing it wrong ;)
TagsNo tags attached.
Internal Weight

Activities

Chris_McElligottPark

Dec 23, 2010 5:22 pm

administrator   ~0006930

No, none of that works, because the runtime is embedded inside unity itself, and isn't called by the OS.

TechSY730

Dec 23, 2010 5:24 pm

reporter   ~0006932

Aww. Too bad. These types of nifty advanced tweaks available to the user (and programmer) can really make programs more usefull.

Though, even with Java programs that have a Java VM embedded in the exe, many times you can still configure the "embedded" VM that the exe runs via these parameters.

Chris_McElligottPark

Dec 23, 2010 5:29 pm

administrator   ~0006941

I don't think you're understanding what I mean: mono isn't accessible by any means here, it's compiled into a different wrapper dll that is a very core part of unity. Even if we could alter that sort of thing, it's a good chance we might cause unintentional crashes. But the only way to alter it would be for us to globally change that in the unity build before we compile AI War itself, and I'm not even sure that would work (and, since that would be global, it's definitely no-go).

Keith and I looked at this problem from a variety of angles, and short of making custom builds of mono and unity that we package with every copy of AI War, it's not possible to make any changes here. And that would be a supremely risky thing to do, to the point we have no inclination of doing so.

keith.lamothe

Dec 23, 2010 5:30 pm

administrator   ~0006942

Unity uses the mono runtime to run our c# scripts, but Unity itself does not run on mono. Also, it is using an embedded version of the runtime that we cannot modify or pass parameters into.

keith.lamothe

Dec 23, 2010 5:30 pm

administrator   ~0006944

oh, that's why resolved wasn't in the list :)

TechSY730

Dec 23, 2010 5:32 pm

reporter   ~0006945

Sad that Unity tries to hide Mono so much. At the very least Unity should have some "These parameters are passed to the underlying Mono system. As we may switch run-time environments or Mono versions later, be it on your own head to use them" (Again, that's how the JVM handles it, those advanced parameters are a "be it on your own head" thing)

(Yes, my primary programming language is Java, how did you know? :P)

keith.lamothe

Dec 23, 2010 5:34 pm

administrator   ~0006946

I don't know that it's a matter of Unity hiding the runtime as it is that they found it unworkable either due to technical glitches in passing in parameters at all or did not believe (understandably) that they could provide support to customers using custom parameters.

Chris_McElligottPark

Dec 23, 2010 5:40 pm

administrator   ~0006948

Additionally, being that it's supposed to be platform-agnostic, that would raise a whole new set of challenges, etc. On some platforms it actually precompiles all the stuff into native code, so mono might not even be there at runtime, etc (mainly iPhone and similar).

TechSY730

Dec 23, 2010 5:41 pm

reporter   ~0006949

Understood. I just thought it would be a nice feature for AI war to expose if Unity or Mono exposed it. Because it doesn't, oh well.

Issue History

Date Modified Username Field Change
Dec 23, 2010 5:18 pm TechSY730 New Issue
Dec 23, 2010 5:22 pm Chris_McElligottPark Note Added: 0006930
Dec 23, 2010 5:22 pm Chris_McElligottPark Status new => resolved
Dec 23, 2010 5:22 pm Chris_McElligottPark Resolution open => not fixable
Dec 23, 2010 5:22 pm Chris_McElligottPark Assigned To => Chris_McElligottPark
Dec 23, 2010 5:24 pm TechSY730 Note Added: 0006932
Dec 23, 2010 5:29 pm Chris_McElligottPark Note Added: 0006941
Dec 23, 2010 5:30 pm keith.lamothe Note Added: 0006942
Dec 23, 2010 5:30 pm keith.lamothe Status resolved => closed
Dec 23, 2010 5:30 pm keith.lamothe Assigned To Chris_McElligottPark => keith.lamothe
Dec 23, 2010 5:30 pm keith.lamothe Note Added: 0006944
Dec 23, 2010 5:30 pm keith.lamothe Status closed => resolved
Dec 23, 2010 5:32 pm TechSY730 Note Added: 0006945
Dec 23, 2010 5:34 pm keith.lamothe Note Added: 0006946
Dec 23, 2010 5:40 pm Chris_McElligottPark Note Added: 0006948
Dec 23, 2010 5:41 pm TechSY730 Note Added: 0006949
Jan 3, 2011 11:44 am Chris_McElligottPark Status resolved => closed
Apr 14, 2014 9:28 am Chris_McElligottPark Category Suggestion - General Idea => Suggestion - General
Apr 14, 2014 9:30 am Chris_McElligottPark Category Suggestion - General => Suggestion