ConfigurationFiles.wiki
changeset 580 79ecca48492f
parent 578 b362aae4143f
child 581 210498f64820
equal deleted inserted replaced
579:9895045e9963 580:79ecca48492f
   163 Campaign variables are stored on a key-value basis, where the key is the name of the campaign variable and the value is the value of the campaign variable.
   163 Campaign variables are stored on a key-value basis, where the key is the name of the campaign variable and the value is the value of the campaign variable.
   164 
   164 
   165 Campaign variable names and their values can are chosen by the Lua script authors, but there are some special variables which are used to determine which missions are available in the main menu:
   165 Campaign variable names and their values can are chosen by the Lua script authors, but there are some special variables which are used to determine which missions are available in the main menu:
   166 
   166 
   167 || *Setting* || *Type* || *Description* ||
   167 || *Setting* || *Type* || *Description* ||
   168 || `Progress` || Integer || If present, this number of missions is unlocked in the menu, starting with the first mission and continuing with the following missions in their regular order (as specified in `campaign.ini`. ||
   168 || `Progress` || Integer || If present, this number of missions is unlocked in the menu, starting with the first mission and continuing with the following missions in their regular order (as specified in `campaign.ini`). ||
   169 || `UnlockedMissions` || Integer || An alternative way to store the unlocked missions in the main menu if the missions aren't unlocked in the regular order. This number specifies how many missions are unlocked. If this variable is set, then the variables `Mission1`, `Mission2`, etc. must be used to specfify the IDs of the unlocked missions. ||
   169 || `UnlockedMissions` || Integer || An alternative way to store the unlocked missions in the main menu if the missions aren't unlocked in the regular order. This number specifies how many missions are unlocked. If this variable is set, then the variables `Mission1`, `Mission2`, etc. must be used to specfify the IDs of the unlocked missions. ||
   170 || `Mission1` || Integer || The `campaign.ini` ID of the first unlocked mission, must be used together with `UnlockedMissions` ||
   170 || `Mission1` || Integer || The `campaign.ini` ID of the first unlocked mission, must be used together with `UnlockedMissions` ||
   171 || `Mission2` || Integer || ID of the second unlocked mission (continues with `Mission3`, `Mission4`, and so on) ||
   171 || `Mission2` || Integer || ID of the second unlocked mission (continues with `Mission3`, `Mission4`, and so on) ||
       
   172 
       
   173 === Examples ===
       
   174 Simple campaign with 10 missions, missions 1-4 are available:
       
   175 
       
   176 {{{
       
   177 [Campaign%20Simple_Campaign]
       
   178 Progress=4
       
   179 }}}
       
   180 
       
   181 Complex campaign with 13 missions, missions 2, 7 and 3 are available (in that order):
       
   182 {{{
       
   183 [Campaign%20Complex_Campaign]
       
   184 UnlockedMissions=3
       
   185 Mission1=2
       
   186 Mission2=7
       
   187 Mission3=3
       
   188 }}}
       
   189 
       
   190 Another campaign with some custom campaign variables:
       
   191 {{{
       
   192 [Campaign%20Another_Campaign]
       
   193 Progress=2
       
   194 MyCustomVariable=54
       
   195 MyCustomString=Hedgewars
       
   196 }}}