]> icculus.org git repositories - divverent/nexuiz.git/blob - scmenu/source/custom/creategame/creategame.qh
Commit round I. Im too tired to write the selector and maplist reset code right now...
[divverent/nexuiz.git] / scmenu / source / custom / creategame / creategame.qh
1 // Property of Alientrap/AK
2 // custom/creategame/creategame.qh
3
4 // Item_Nex_Map_Info
5 // its a valid item nevertheless
6 .string normal;         // contains the map name
7 .string picture;        // contains the picture that should be displayed
8 .string text;           // contains the description text
9 .string link;           // contains the path to the map
10
11 void() Item_Nex_Map_Info_Destroy;
12 void() Item_Nex_Map_Info_Spawn;
13
14 // Map ""database"" Singleton Item_Nex_MapDB
15
16 // AK late function (doesnt fit and breaks singleton abstraction) FIXME
17 void() Nex_MapDB_RefreshFiles;
18
19 // pRoot should be an item with no other children
20 void() Item_Nex_MapDB_EnumFiles;
21 void() Item_Nex_MapDB_Destroy;
22 void() Item_Nex_MapDB_Spawn;
23
24 entity( string pPath ) Nex_MapDB_GetByPath;
25 entity( float pIndex ) Nex_MapDB_GetByIndex;
26 float( entity pItem ) Nex_MapDB_GetIndex;
27
28 string() Nex_MapDB_GetPathAltString;
29 string() Nex_MapDB_GetNameAltString;
30
31 // see control/data/data.qh
32 // Item_Data_Nex_Name [Item_Data]
33 void( float pEvent ) Item_Data_Nex_Name_DataEvent;
34 void() Item_Data_Nex_Name_Spawn;
35
36 // Item_DataLink_Nex_MapList [Item_DataLink_Switch]
37 // contains the full .bsp path in value and the text/map name in desc
38 // this is just a placeholder data item - it only keeps a set
39 .string cvarName; // name of the maplist cvar
40 .event init; // if you want to initialize it
41 void( float pEvent ) Item_DataLink_Nex_MapList_DataEvent;
42 void() Item_DataLink_Nex_MapList_Spawn;
43
44 void() Item_DataLink_Nex_MapList_InitWithMapList;
45 void( entity pItem ) DataLink_Nex_MapList_UpdateRange;
46
47 // MapList edit commands
48 // these functions work with the entry selected by _realValue
49 void( entity pItem, string pName, string pPath ) DataLink_Nex_MapList_InsertEntryAfter;
50 void( entity pItem ) DataLink_Nex_MapList_DeleteEntry;
51 void( entity pItem ) DataLink_Nex_MapList_MoveEntryUp;
52 void( entity pItem ) DataLink_Nex_MapList_MoveEntryDown;
53 // creates the first entry if necessary
54 void( entity pItem, string pName, string pPath ) DataLink_Nex_MapList_SetFirst;
55 void( entity pItem ) DataLink_Nex_MapList_Clear;
56
57 // both functions return str zoned strings
58 string( entity pItem ) DataLink_Nex_MapList_GetCurrentName;
59 string( entity pItem ) DataLink_Nex_MapList_GetCurrentPath;
60
61 // see control/data/data.qh
62 // Item_DataLink_Nex_ModSwitch Item_DataLink_TextSwitch
63
64 void() Item_DataLink_Nex_ModSwitch_Spawn;
65
66 //Item_DataLink_Nex_FileList [Item_DataLink_TextSwitch]
67 .string normal; // contains the file extension
68 .string selected; // contains the path
69 .string valueList;
70
71 void( float pEvent ) Item_DataLink_Nex_FileList_DataEvent;
72 void() Item_DataLink_Nex_FileList_Destroy;
73 void() Item_DataLink_Nex_FileList_Spawn;