Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > IL-2 Sturmovik: Cliffs of Dover > FMB, Mission & Campaign builder Discussions

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #16  
Old 10-21-2011, 05:09 PM
Ataros Ataros is offline
Approved Member
 
Join Date: Jun 2010
Location: USSR
Posts: 2,439
Default

Quote:
Originally Posted by FG28_Kodiak View Post
Filename is only used in the constructor to give the value to the variable Missionfilename.
Does it mean I can initialize variables in this block, replacing e.g. Length with a value I want to assign?
this.MissionLengh = 30;

Ah, it looks like the only purpose of it is to allow data input like here:
Code:
  public List<Mis> MissionPool = new List<Mis>()
    {
        new Mis ("Mission1.mis",SubMissionsPath ,1000.0),
        new Mis ("Mission2.mis",SubMissionsPath ,1000.0),
    };
So when I create a new Mis I can enter data there from e.g. parsed filename in one line only, not having to use 3 lines like
mi.Missionfilename = ...;
mi.SubMissionsPath = ...;
mi.MissionLengh = ...;

Instead after parsing a file name I can:
Code:
string[] MisParams;
MisParams = (mi.Missionfilename).Split('_');

Mis mi = new Mis (MisParams[1], MisParams[2],MisParams[3]);
Thanks a lot!

Last edited by Ataros; 10-21-2011 at 05:30 PM.
Reply With Quote
 

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 Off

Forum Jump


All times are GMT. The time now is 05:05 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.