-
Notifications
You must be signed in to change notification settings - Fork 1
/
game_interface.lua
149 lines (116 loc) · 3.97 KB
/
game_interface.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
--
-- Copyright (c) 2005 Pandemic Studios, LLC. All rights reserved.
--
-- Master include for StarWars: Frontline ingame interface, lua
-- component. The game should be able to include this file and nothing
-- else.
print("game_interface: Entered")
gPlatformStr = ScriptCB_GetPlatform()
-- Note: we don't call ScriptCB_GetOnlineService(), which returns what
-- the binary was compiled for (XLive vs GameSpy). We want the current
-- connection type, which is "LAN", "XLive" or "GameSpy"
gOnlineServiceStr = ScriptCB_GetConnectType()
-- gOnlineServiceStr = ScriptCB_GetOnlineService()
gLangStr,gLangEnum = ScriptCB_GetLanguage()
-- Read in awards setting
--[[if ScriptCB_IsFileExist("..\\..\\addon\\AAA-v1.3patch\\settings\\noAwards.txt") then
__v13patchSettings_noAwards__ = 0
end
ScriptCB_DoFile("utility_functions2")
print("game_interface: Reading in custom strings")
ReadDataFile("v1.3patch_strings.lvl")
-- Load user scripts
local curUserScript = 0
while ScriptCB_IsFileExist("user_script_"..curUserScript..".lvl") do
ReadDataFile("user_script_"..curUserScript..".lvl")
print("game_interface: Found user_script_"..curUserScript)
curUserScript = curUserScript + 1
else
print("game_interface: No user_script_"..curUserScript)
end]]
-- Load designer-specified globals
ScriptCB_DoFile("globals")
-- Load player stats points
ScriptCB_DoFile("points")
--
--
-- Load utility functions
ScriptCB_DoFile("interface_util")
ScriptCB_DoFile("ifelem_button")
ScriptCB_DoFile("ifelem_roundbutton")
ScriptCB_DoFile("ifelem_flatbutton")
ScriptCB_DoFile("ifelem_buttonwindow")
ScriptCB_DoFile("ifelem_segline")
ScriptCB_DoFile("ifelem_popup")
ScriptCB_DoFile("ifelem_listmanager")
ScriptCB_DoFile("ifelem_helptext")
ScriptCB_DoFile("ifelem_shellscreen")
ScriptCB_DoFile("ifelem_titlebar")
ScriptCB_DoFile("ifelem_borderrect")
ScriptCB_DoFile("ifelem_hslider")
ScriptCB_DoFile("ifelem_form")
ScriptCB_DoFile("ifelem_AnimationMgr")
ScriptCB_DoFile("ifs_movietrans_game")
if(gPlatformStr == "PC") then
ScriptCB_DoFile("ifelem_tabmanager")
ScriptCB_DoFile("ifutil_mouse")
ScriptCB_DoFile("ifelem_editbox")
end
--
--
-- Load screens. Will be activated by gamecode, not us.
ScriptCB_DoFile("ifs_opt_top")
ScriptCB_DoFile("ifs_opt_controller_mode")
if(gPlatformStr == "PC") then
ScriptCB_DoFile("pctabs_options")
end
if(gPlatformStr ~= "PC") then
ScriptCB_DoFile("controller_presets")
ScriptCB_DoFile("ifs_opt_controller_common")
ScriptCB_DoFile("ifs_opt_controller_vehunit")
end
ScriptCB_DoFile("ifs_opt_general")
ScriptCB_DoFile("ifs_opt_sound")
ScriptCB_DoFile("ifs_opt_mp_listtags")
ScriptCB_DoFile("ifs_opt_mp")
if(gPlatformStr == "PC") then
ScriptCB_DoFile("ifs_saveop")
--ScriptCB_DoFile("ifs_opt_pckeyboard")
ScriptCB_DoFile("ifs_opt_pccontrols")
ScriptCB_DoFile("ifs_opt_pcvideo")
ScriptCB_DoFile("ifs_pc_SpawnSelect")
ScriptCB_DoFile("ifs_pc_spectator")
end
ScriptCB_DoFile("ifs_sideselect")
ScriptCB_DoFile("ifs_charselect")
ScriptCB_DoFile("ifs_mapselect")
ScriptCB_DoFile("ifs_readyselect")
ScriptCB_DoFile("popups_common")
ScriptCB_DoFile("popup_ok")
if(gPlatformStr ~= "PS2") then
ScriptCB_DoFile("popup_ab")
ScriptCB_DoFile("popup_busy")
end
ScriptCB_DoFile("popup_yesno")
ScriptCB_DoFile("popup_yesno_large")
ScriptCB_DoFile("error_popup")
if(gPlatformStr == "PC") then
ScriptCB_DoFile("popup_loadsave2")
end
ScriptCB_DoFile("ifs_pausemenu")
ScriptCB_DoFile("ifs_fakeconsole")
ScriptCB_DoFile("ifs_teamstats")
ScriptCB_DoFile("ifs_personalstats")
ScriptCB_DoFile("ifs_awardstats")
ScriptCB_DoFile("ifs_careerstats")
ScriptCB_DoFile("ifs_mp_lobby")
ScriptCB_DoFile("popups_lobby")
ScriptCB_DoFile("popup_vote")
-- Pull in XBox-only pages (with mpxl in the name)
if(ScriptCB_GetOnlineService() == "XLive") then
ScriptCB_DoFile("ifs_mpxl_friends")
ScriptCB_DoFile("ifs_mpxl_feedback")
ScriptCB_DoFile("ifs_mpxl_voicemail")
else
ScriptCB_DoFile("ifs_mpgs_friends")
end