User Tools

Site Tools


en:tutorials:retrieving_changing_config_values

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision Both sides next revision
en:tutorials:retrieving_changing_config_values [2018/02/14 04:46 (2 years ago)]
iarwain ↷ Links adapted because of a move operation
en:tutorials:retrieving_changing_config_values [2019/03/06 11:37 (15 months ago)]
sausage Fixes and random list with orxConfig_GetString
Line 77: Line 77:
  
 <code c> <code c>
- orxConfig_PushSection("​Scene"); + orxConfig_PushSection("​Runtime"); 
- const orxSTRING value = orxConfig_GetListString("​ChildList", ​3);+ const orxSTRING value = orxConfig_GetListString("​Titles", ​2);
  orxConfig_PopSection();​  orxConfig_PopSection();​
 </​code>​ </​code>​
Line 85: Line 85:
  
 <code c> <code c>
- orxConfig_PushSection("​Scene"); + orxConfig_PushSection("​Runtime"); 
- const orxSTRING value = orxConfig_GetListString("​ChildList", orxNULL);+ const orxSTRING value = orxConfig_GetListString("​Titles", orxNULL); 
 + orxConfig_PopSection();​ 
 +</​code>​ 
 + 
 +An alternative way to get a random value from a list is to instead use ''​orxConfig_GetString'':​ 
 + 
 +<code c> 
 + orxConfig_PushSection("​Runtime"​);​ 
 + const orxSTRING value = orxConfig_GetString("​Titles"​);
  orxConfig_PopSection();​  orxConfig_PopSection();​
 </​code>​ </​code>​
en/tutorials/retrieving_changing_config_values.txt · Last modified: 2019/03/25 17:29 (14 months ago) (external edit)