1 // Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
2 // Copyright (C) 2010 Winch Gate Property Limited
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU Affero General Public License as
6 // published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU Affero General Public License for more details.
14 // You should have received a copy of the GNU Affero General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
19 #ifndef RYAI_AI_FILES_H
20 #define RYAI_AI_FILES_H
22 #include "nel/misc/types_nl.h"
23 #include "nel/misc/sheet_id.h"
24 #include "nel/misc/entity_id.h"
26 #include "nel/net/transport_class.h"
34 // clear out the data strustures and rescan the directories listed in the config
35 // file for source and object files
38 // delete the object files (and temporary files if any) for a given manager
39 static void clean(sint mgrId
);
41 // source file name, extension, etc
42 static std::vector
<std::string
> srcPaths(); // the paths for source files
43 static std::string
srcExtension(); // the standard src extension
44 static std::string
srcName(sint mgrId
); // without path or extension
45 static std::string
srcFileName(sint mgrId
); // without path
46 static std::string
fullSrcName(sint mgrId
); // without extension
47 static std::string
fullSrcFileName(sint mgrId
); // with path and extension
49 // object file name, extension, etc
50 static std::string
objPath(); // the path for obj files
51 static std::string
objExtension(); // the standard obj file extension
52 static std::string
objName(sint mgrId
); // without path or extension
53 static std::string
objFileName(sint mgrId
); // without extension
54 static std::string
fullObjFileName(sint mgrId
); // with path and extension
56 // saved data file name, extension, etc
57 static std::string
savPath(); // the path for sav files
58 static std::string
savExtension(); // the standard sav file extension
59 static std::string
savName(sint mgrId
); // without path or extension
60 static std::string
savFileName(sint mgrId
); // without extension
61 static std::string
fullSavFileName(sint mgrId
); // with path and extension
63 // Reading & writing object files
64 static void CAIFiles::writeObjFile(sint mgrId
);
67 static void CAIFiles::_addSrcFile(std::string fileName
,std::string fullFileName
, uint timestamp
);
68 static void CAIFiles::_addObjFile(sint mgrId
,std::string fullFileName
, uint timestamp
);
69 static void CAIFiles::_addSavFile(sint mgrId
,std::string fullFileName
);
71 static void CAIFiles::_scanSrcFiles(const std::string
&path
);
72 static void CAIFiles::_scanObjAndSavFiles();