Differences

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

Link to this comparison view

pjv:laboratoare:2023:10 [2023/12/11 15:20]
alexandru.gradinaru [Documentatie extinsa text]
pjv:laboratoare:2023:10 [2024/10/07 10:49] (current)
alexandru.gradinaru
Line 1: Line 1:
-===== Sisteme de gestiune a datelor =====+===== 10. Sisteme de gestiune a datelor =====
  
 ==== Cerinte ===== ==== Cerinte =====
Line 118: Line 118:
 ... ...
  
-    ​public ​static string dataFilePath = Path.Combine(Application.persistentDataPath,​ "​SaveGameData.json"​);​ +    ​private ​static string dataFilePath = Path.Combine(Application.persistentDataPath,​ "​SaveGameData.json"​);​
-    ​+
     public void SaveGame()     public void SaveGame()
     {     {
         GameData gameData = new GameData();         GameData gameData = new GameData();
         gameData.level = level;         gameData.level = level;
-        ...etc +        ​//...etc
-         +
-       +
         // This creates a new StreamWriter to write to a specific file path         // This creates a new StreamWriter to write to a specific file path
         using (StreamWriter writer = new StreamWriter(dataFilePath))         using (StreamWriter writer = new StreamWriter(dataFilePath))
Line 137: Line 134:
         }         }
     }     }
- 
     public void LoadGame()     public void LoadGame()
     {     {
Line 150: Line 146:
         }         }
     }     }
- 
-    ​ 
 } }
 +</​code>​
pjv/laboratoare/2023/10.1702300818.txt.gz · Last modified: 2023/12/11 15:20 by alexandru.gradinaru
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0