Advertisement
Guest User

Untitled

a guest
Apr 11th, 2016
1,066
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 17.51 KB | None | 0 0
  1. settings = {
  2. showCurrentRequiredExperience = true;
  3. showCurrentPercent = true;
  4. showLastGainedExperience = true;
  5. showKillsTilNextLevel = true;
  6. showExperiencePerHour = true;
  7. showTimeTilLevel = true;
  8. };
  9.  
  10. --[[START EXPERIENCE DATA]]
  11. local ExperienceData = {}
  12. ExperienceData.__index = ExperienceData
  13.  
  14. setmetatable(ExperienceData, {
  15. __call = function (cls, ...)
  16. return cls.new(...)
  17. end,
  18. })
  19.  
  20. function ExperienceData.new()
  21. local self = setmetatable({}, ExperienceData)
  22.  
  23. self.firstUpdate = true;
  24. self.currentExperience = 0;
  25. self.requiredExperience = 0;
  26. self.previousCurrentExperience = 0;
  27. self.previousRequiredExperience = 0;
  28. self.currentPercent = 0;
  29. self.lastExperienceGain = 0;
  30. self.killsTilNextLevel = 0;
  31. self.experiencePerHour = 0;
  32. self.experienceGained = 0;
  33. self.timeTilLevel = 0;
  34.  
  35. return self
  36. end
  37.  
  38. function ExperienceData:reset()
  39. self.firstUpdate = true;
  40. self.currentExperience = 0;
  41. self.requiredExperience = 0;
  42. self.previousCurrentExperience = 0;
  43. self.previousRequiredExperience = 0;
  44. self.currentPercent = 0;
  45. self.lastExperienceGain = 0;
  46. self.killsTilNextLevel = 0;
  47. self.experiencePerHour = 0;
  48. self.experienceGained = 0;
  49. self.timeTilLevel = 0;
  50. end
  51. --[[END EXPERIENCE DATA]]
  52.  
  53. _G["EXPERIENCE_VIEWER"] = {};
  54. _G["EXPERIENCE_VIEWER"]["baseExperienceData"] = _G["EXPERIENCE_VIEWER"]["baseExperienceData"] or ExperienceData();
  55. _G["EXPERIENCE_VIEWER"]["classExperienceData"] = _G["EXPERIENCE_VIEWER"]["classExperienceData"] or ExperienceData();
  56. _G["EXPERIENCE_VIEWER"]["startTime"] = _G["EXPERIENCE_VIEWER"]["startTime"] or os.clock();
  57. _G["EXPERIENCE_VIEWER"]["elapsedTime"] = _G["EXPERIENCE_VIEWER"]["elapsedTime"] or os.difftime(os.clock(), _G["EXPERIENCE_VIEWER"]["startTime"]);
  58. _G["EXPERIENCE_VIEWER"]["SECONDS_IN_HOUR"] = _G["EXPERIENCE_VIEWER"]["SECONDS_IN_HOUR"] or 3600;
  59. _G["EXPERIENCE_VIEWER"]["headerTablePositions"] = _G["EXPERIENCE_VIEWER"]["headerTablePositions"] or { 0, 0, 0, 0, 0, 0 };
  60. _G["EXPERIENCE_VIEWER"]["baseTablePositions"] = _G["EXPERIENCE_VIEWER"]["baseTablePositions"] or { 0, 0, 0, 0, 0, 0 };
  61. _G["EXPERIENCE_VIEWER"]["classTablePositions"] = _G["EXPERIENCE_VIEWER"]["classTablePositions"] or { 0, 0, 0, 0, 0, 0 };
  62. _G["EXPERIENCE_VIEWER"]["frameWidths"] = _G["EXPERIENCE_VIEWER"]["frameWidths"] or { 0, 0, 0, 0, 0, 0 };
  63. _G["EXPERIENCE_VIEWER"]["padding"] = _G["EXPERIENCE_VIEWER"]["padding"] or 5;
  64.  
  65. function SET_WINDOW_POSITION_GLOBAL()
  66. local expFrame = ui.GetFrame("expviewer");
  67.  
  68. if expFrame ~= nil then
  69. _G["EXPERIENCE_VIEWER"]["POSITION_X"] = expFrame:GetX();
  70. _G["EXPERIENCE_VIEWER"]["POSITION_Y"] = expFrame:GetY();
  71. end
  72.  
  73. SAVE_POSITION_TO_FILE(expFrame:GetX(), expFrame:GetY());
  74. end
  75.  
  76. function MOVE_WINDOW_TO_STORED_POSITION()
  77. local expFrame = ui.GetFrame("expviewer");
  78.  
  79. if expFrame ~= nil then
  80. expFrame:Move(0, 0);
  81. expFrame:SetOffset(_G["EXPERIENCE_VIEWER"]["POSITION_X"], _G["EXPERIENCE_VIEWER"]["POSITION_Y"]);
  82. end
  83. end
  84.  
  85. function INIT()
  86. LOAD_POSITION_FROM_FILE();
  87. local expFrame = ui.GetFrame("expviewer");
  88. expFrame:ShowWindow(1);
  89. UPDATE_BUTTONS(expFrame);
  90. UPDATE_UI("baseExperience", _G["EXPERIENCE_VIEWER"]["baseExperienceData"]);
  91. UPDATE_UI("classExperience", _G["EXPERIENCE_VIEWER"]["classExperienceData"]);
  92. end
  93.  
  94. function HEADSUPDISPLAY_ON_MSG_HOOKED(frame, msg, argStr, argNum)
  95. local oldf = _G["HEADSUPDISPLAY_ON_MSG_OLD"];
  96. oldf(frame, msg, argStr, argNum);
  97.  
  98. MOVE_WINDOW_TO_STORED_POSITION();
  99. INIT();
  100. end
  101.  
  102. function CHARBASEINFO_ON_MSG_HOOKED(frame, msg, argStr, argNum)
  103. if msg == 'EXP_UPDATE' then
  104. _G["EXPERIENCE_VIEWER"]["elapsedTime"] = os.difftime(os.clock(), _G["EXPERIENCE_VIEWER"]["startTime"]);
  105.  
  106. --SET BASE CURRENT/REQUIRED EXPERIENCE
  107. _G["EXPERIENCE_VIEWER"]["baseExperienceData"].previousRequiredExperience = _G["EXPERIENCE_VIEWER"]["baseExperienceData"].requiredExperience;
  108. _G["EXPERIENCE_VIEWER"]["baseExperienceData"].currentExperience = session.GetEXP();
  109. _G["EXPERIENCE_VIEWER"]["baseExperienceData"].requiredExperience = session.GetMaxEXP();
  110.  
  111. --CALCULATE EXPERIENCE
  112. CALCULATE_EXPERIENCE_DATA(_G["EXPERIENCE_VIEWER"]["baseExperienceData"], _G["EXPERIENCE_VIEWER"]["elapsedTime"]);
  113.  
  114. UPDATE_UI("baseExperience", _G["EXPERIENCE_VIEWER"]["baseExperienceData"]);
  115. end
  116.  
  117. local oldf = _G["CHARBASEINFO_ON_MSG_OLD"];
  118. return oldf(frame, msg, str, exp, tableinfo);
  119. end
  120.  
  121. function ON_JOB_EXP_UPDATE_HOOKED(frame, msg, str, exp, tableinfo)
  122. _G["EXPERIENCE_VIEWER"]["elapsedTime"] = os.difftime(os.clock(), _G["EXPERIENCE_VIEWER"]["startTime"]);
  123.  
  124. --CALCULATE EXPERIENCE
  125. local currentTotalClassExperience = exp;
  126. local currentClassLevel = tableinfo.level;
  127.  
  128. --SET CLASS CURRENT/REQUIRED EXPERIENCE
  129. _G["EXPERIENCE_VIEWER"]["classExperienceData"].previousRequiredExperience = _G["EXPERIENCE_VIEWER"]["classExperienceData"].requiredExperience;
  130. _G["EXPERIENCE_VIEWER"]["classExperienceData"].currentExperience = exp - tableinfo.startExp;
  131. _G["EXPERIENCE_VIEWER"]["classExperienceData"].requiredExperience = tableinfo.endExp - tableinfo.startExp;
  132.  
  133. --CALCULATE EXPERIENCE
  134. CALCULATE_EXPERIENCE_DATA(_G["EXPERIENCE_VIEWER"]["classExperienceData"], _G["EXPERIENCE_VIEWER"]["elapsedTime"]);
  135.  
  136. UPDATE_UI("classExperience", _G["EXPERIENCE_VIEWER"]["classExperienceData"]);
  137.  
  138. local oldf = _G["ON_JOB_EXP_UPDATE_OLD"];
  139. return oldf(frame, msg, str, exp, tableinfo);
  140. end
  141.  
  142. function CALCULATE_EXPERIENCE_DATA(experienceData, elapsedTime)
  143. if experienceData.firstUpdate == true then
  144. experienceData.previousCurrentExperience = experienceData.currentExperience;
  145. experienceData.firstUpdate = false;
  146. return;
  147. end
  148.  
  149. --[[PERFORM CALCULATIONS]]
  150. --if we leveled up...
  151. if experienceData.requiredExperience > experienceData.previousRequiredExperience then
  152. experienceData.lastExperienceGain = (experienceData.previousRequiredExperience - experienceData.previousCurrentExperience) + experienceData.currentExperience;
  153. else
  154. experienceData.lastExperienceGain = experienceData.currentExperience - experienceData.previousCurrentExperience;
  155. end
  156.  
  157. experienceData.experienceGained = experienceData.experienceGained + experienceData.lastExperienceGain;
  158. experienceData.currentPercent = experienceData.currentExperience / experienceData.requiredExperience * 100;
  159.  
  160. if experienceData.lastExperienceGain == 0 then
  161. experienceData.killsTilNextLevel = "INF";
  162. else
  163. experienceData.killsTilNextLevel = math.ceil((experienceData.requiredExperience - experienceData.currentExperience) / experienceData.lastExperienceGain);
  164. end
  165.  
  166. experienceData.experiencePerHour = (experienceData.experienceGained * (_G["EXPERIENCE_VIEWER"]["SECONDS_IN_HOUR"] / _G["EXPERIENCE_VIEWER"]["elapsedTime"]));
  167.  
  168. local experienceRemaining = experienceData.requiredExperience - experienceData.currentExperience;
  169. local experiencePerSecond = experienceData.experienceGained / _G["EXPERIENCE_VIEWER"]["elapsedTime"];
  170.  
  171. experienceData.timeTilLevel = os.date("!%X", experienceRemaining / experiencePerSecond);
  172.  
  173. --[[END OF UPDATES, SET PREVIOUS]]
  174. experienceData.previousCurrentExperience = experienceData.currentExperience;
  175. end
  176.  
  177. function UPDATE_UI(experienceTextName, experienceData)
  178. if ui ~= nil then
  179. local expFrame = ui.GetFrame("expviewer");
  180.  
  181. if expFrame ~= nil then
  182. UPDATE_BUTTONS(expFrame);
  183.  
  184. --this might be the worst code I've ever written, but who cares? it works!
  185.  
  186. --SET EXPERIENCE TEXT
  187. if experienceTextName == "baseExperience" or experienceTextName == "classExperience" then
  188. local xPosition = 15;
  189. local yPosition = 14;
  190.  
  191. for i=0,5 do
  192. local columnKey = "headerTablePositions";
  193. local richText = expFrame:GetChild("header_"..i);
  194.  
  195. richText:Resize(0, 20);
  196.  
  197. if i == 0 then
  198. xPosition = UPDATE_CELL(
  199. i,
  200. richText,
  201. "{@st41}{s18}Current / Required",
  202. settings.showCurrentRequiredExperience,
  203. xPosition,
  204. yPosition,
  205. columnKey
  206. );
  207. elseif i == 1 then
  208. xPosition = UPDATE_CELL(
  209. i,
  210. richText,
  211. "{@st41}{s18}%",
  212. settings.showCurrentPercent,
  213. xPosition,
  214. yPosition,
  215. columnKey
  216. );
  217. elseif i == 2 then
  218. xPosition = UPDATE_CELL(
  219. i,
  220. richText,
  221. "{@st41}{s18}Gain",
  222. settings.showLastGainedExperience,
  223. xPosition,
  224. yPosition,
  225. columnKey
  226. );
  227. elseif i == 3 then
  228. xPosition = UPDATE_CELL(
  229. i,
  230. richText,
  231. "{@st41}{s18}TNL",
  232. settings.showKillsTilNextLevel,
  233. xPosition,
  234. yPosition,
  235. columnKey
  236. );
  237. elseif i == 4 then
  238. xPosition = UPDATE_CELL(
  239. i,
  240. richText,
  241. "{@st41}{s18}Exp/Hr",
  242. settings.showExperiencePerHour,
  243. xPosition,
  244. yPosition,
  245. columnKey
  246. );
  247. elseif i == 5 then
  248. xPosition = UPDATE_CELL(
  249. i,
  250. richText,
  251. "{@st41}{s18}ETA",
  252. settings.showTimeTilLevel,
  253. xPosition,
  254. yPosition,
  255. columnKey
  256. );
  257. end
  258. end
  259. end
  260.  
  261. if experienceTextName == "baseExperience" then
  262. local xPosition = 15;
  263. local yPosition = 49;
  264.  
  265. for i=0,5 do
  266. local columnKey = "baseTablePositions";
  267. local richText = expFrame:GetChild("base_"..i);
  268.  
  269. richText:Resize(0, 20);
  270.  
  271. if i == 0 then
  272. xPosition = UPDATE_CELL(
  273. i,
  274. richText,
  275. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(experienceData.currentExperience) .." / " .. ADD_THOUSANDS_SEPARATOR(experienceData.requiredExperience),
  276. settings.showCurrentRequiredExperience,
  277. xPosition,
  278. yPosition,
  279. columnKey
  280. );
  281. elseif i == 1 then
  282. xPosition = UPDATE_CELL(
  283. i,
  284. richText,
  285. "{@st41}{s16}" .. string.format("%.2f", experienceData.currentPercent) .. "%",
  286. settings.showCurrentPercent,
  287. xPosition,
  288. yPosition,
  289. columnKey
  290. );
  291. elseif i == 2 then
  292. xPosition = UPDATE_CELL(
  293. i,
  294. richText,
  295. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(experienceData.lastExperienceGain),
  296. settings.showLastGainedExperience,
  297. xPosition,
  298. yPosition,
  299. columnKey
  300. );
  301. elseif i == 3 then
  302. xPosition = UPDATE_CELL(
  303. i,
  304. richText,
  305. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(experienceData.killsTilNextLevel),
  306. settings.showKillsTilNextLevel,
  307. xPosition,
  308. yPosition,
  309. columnKey
  310. );
  311. elseif i == 4 then
  312. xPosition = UPDATE_CELL(
  313. i,
  314. richText,
  315. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(string.format("%i", experienceData.experiencePerHour)),
  316. settings.showExperiencePerHour,
  317. xPosition,
  318. yPosition,
  319. columnKey
  320. );
  321. elseif i == 5 then
  322. xPosition = UPDATE_CELL(
  323. i,
  324. richText,
  325. "{@st41}{s16}" .. experienceData.timeTilLevel,
  326. settings.showTimeTilLevel,
  327. xPosition,
  328. yPosition,
  329. columnKey
  330. );
  331. end
  332. end
  333. end
  334.  
  335. if experienceTextName == "classExperience" then
  336. local xPosition = 15;
  337. local yPosition = 74;
  338.  
  339. for i=0,5 do
  340. local columnKey = "classTablePositions";
  341. local richText = expFrame:GetChild("class_"..i);
  342.  
  343. richText:Resize(0, 20);
  344.  
  345. if i == 0 then
  346. xPosition = UPDATE_CELL(
  347. i,
  348. richText,
  349. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(experienceData.currentExperience) .." / " .. ADD_THOUSANDS_SEPARATOR(experienceData.requiredExperience),
  350. settings.showCurrentRequiredExperience,
  351. xPosition,
  352. yPosition,
  353. columnKey
  354. );
  355. elseif i == 1 then
  356. xPosition = UPDATE_CELL(
  357. i,
  358. richText,
  359. "{@st41}{s16}" .. string.format("%.2f", experienceData.currentPercent) .. "%",
  360. settings.showCurrentPercent,
  361. xPosition,
  362. yPosition,
  363. columnKey
  364. );
  365. elseif i == 2 then
  366. xPosition = UPDATE_CELL(
  367. i,
  368. richText,
  369. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(experienceData.lastExperienceGain),
  370. settings.showLastGainedExperience,
  371. xPosition,
  372. yPosition,
  373. columnKey
  374. );
  375. elseif i == 3 then
  376. xPosition = UPDATE_CELL(
  377. i,
  378. richText,
  379. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(experienceData.killsTilNextLevel),
  380. settings.showKillsTilNextLevel,
  381. xPosition,
  382. yPosition,
  383. columnKey
  384. );
  385. elseif i == 4 then
  386. xPosition = UPDATE_CELL(
  387. i,
  388. richText,
  389. "{@st41}{s16}" .. ADD_THOUSANDS_SEPARATOR(string.format("%i", experienceData.experiencePerHour)),
  390. settings.showExperiencePerHour,
  391. xPosition,
  392. yPosition,
  393. columnKey
  394. );
  395. elseif i == 5 then
  396. xPosition = UPDATE_CELL(
  397. i,
  398. richText,
  399. "{@st41}{s16}" .. experienceData.timeTilLevel,
  400. settings.showTimeTilLevel,
  401. xPosition,
  402. yPosition,
  403. columnKey
  404. );
  405. end
  406. end
  407. end
  408.  
  409. local size = CALCULATE_FRAME_SIZE() + 20; --extra 20 for reset button
  410. expFrame:Resize(size, 108);
  411. end
  412. end
  413. end
  414.  
  415. function UPDATE_CELL(i, richTextComponent, label, showField, xPosition, yPosition, columnKey)
  416. if showField then
  417. richTextComponent:SetText(label);
  418.  
  419. _G["EXPERIENCE_VIEWER"][columnKey][i+1] = richTextComponent:GetWidth();
  420.  
  421. richTextComponent:Resize(richTextComponent:GetWidth(), 20);
  422. richTextComponent:Move(0, 0);
  423. richTextComponent:SetOffset(xPosition, yPosition);
  424. richTextComponent:ShowWindow(1);
  425.  
  426. xPosition = xPosition + CALCULATE_MAX_COLUMN_WIDTH(i) + _G["EXPERIENCE_VIEWER"]["padding"];
  427. else
  428. _G["EXPERIENCE_VIEWER"][columnKey][i+1] = 0;
  429. richTextComponent:SetText("");
  430. richTextComponent:Move(0, 0);
  431. richTextComponent:SetOffset(xPosition, yPosition);
  432. richTextComponent:ShowWindow(0);
  433. end
  434.  
  435. return xPosition;
  436. end
  437.  
  438. function CALCULATE_MAX_COLUMN_WIDTH(tableIndex)
  439. return math.max(_G["EXPERIENCE_VIEWER"]["headerTablePositions"][tableIndex+1], _G["EXPERIENCE_VIEWER"]["baseTablePositions"][tableIndex+1], _G["EXPERIENCE_VIEWER"]["classTablePositions"][tableIndex+1]);
  440. end
  441.  
  442. function CALCULATE_FRAME_SIZE()
  443. local frameWidth = 0;
  444.  
  445. for i = 1,6 do
  446. local max = math.max(_G["EXPERIENCE_VIEWER"]["headerTablePositions"][i], _G["EXPERIENCE_VIEWER"]["baseTablePositions"][i], _G["EXPERIENCE_VIEWER"]["classTablePositions"][i]);
  447. frameWidth = frameWidth + max + _G["EXPERIENCE_VIEWER"]["padding"];
  448. end
  449.  
  450. frameWidth = frameWidth + (_G["EXPERIENCE_VIEWER"]["padding"] * 2);
  451.  
  452. return frameWidth;
  453. end
  454.  
  455. function UPDATE_BUTTONS(expFrame)
  456. --MOVE RESET BUTTON TO TOPRIGHT CORNER
  457. local resetButton = expFrame:GetChild("resetButton");
  458. if resetButton ~= nil then
  459. resetButton:Move(0, 0);
  460. resetButton:SetOffset(expFrame:GetWidth() - 35, 5);
  461. resetButton:SetText("{@sti7}{s16}R");
  462. resetButton:Resize(30, 30);
  463. end
  464.  
  465. --MOVE START BUTTON TO TOPLEFT CORNER
  466. local startButton = expFrame:GetChild("startButton");
  467. if startButton ~= nil then
  468. startButton:Move(0, 0);
  469. startButton:SetOffset(5, 5);
  470. startButton:SetText("{@sti7}{s16}S");
  471. startButton:Resize(30, 30);
  472. startButton:ShowWindow(0);
  473. end
  474. end
  475.  
  476. function PRINT_EXPERIENCE_DATA(experienceData)
  477. ui.SysMsg(experienceData.currentExperience .. " / " .. experienceData.requiredExperience .. " " .. experienceData.lastExperienceGain .. " gained " .. experienceData.currentPercent .. "%" .. " " .. experienceData.killsTilNextLevel .. " tnl " .. experienceData.experiencePerHour .. " exp/hr");
  478. end
  479.  
  480. function MapRevealPls()
  481. local mapName = session.GetMapName();
  482. local list = session.GetMapFogList(mapName);
  483. local cnt = list:Count();
  484. for i = 0 , cnt - 1 do
  485. local info = list:PtrAt(i);
  486. info.revealed = 1;
  487. end
  488. packet.ReqSaveMapReveal(mapName);
  489. local frame = ui.GetFrame('map');
  490. UPDATE_MAP(frame);
  491. ui.SysMsg("Map revealed");
  492. end
  493.  
  494. function RESET()
  495. ui.SysMsg("Resetting experience session!");
  496. MapRevealPls();
  497. _G["EXPERIENCE_VIEWER"]["startTime"] = os.clock();
  498. _G["EXPERIENCE_VIEWER"]["elapsedTime"] = 0;
  499. _G["EXPERIENCE_VIEWER"]["baseExperienceData"]:reset();
  500. _G["EXPERIENCE_VIEWER"]["classExperienceData"]:reset();
  501.  
  502. SET_WINDOW_POSITION_GLOBAL();
  503. end
  504.  
  505. function LOAD_POSITION_FROM_FILE()
  506. local file, error = io.open("../addons/expviewer/settings.txt", "r");
  507.  
  508. if error then
  509. return;
  510. end
  511.  
  512. _G["EXPERIENCE_VIEWER"]["POSITION_X"] = file:read();
  513. _G["EXPERIENCE_VIEWER"]["POSITION_Y"] = file:read();
  514.  
  515. MOVE_WINDOW_TO_STORED_POSITION();
  516. end
  517.  
  518. function SAVE_POSITION_TO_FILE(xPosition, yPosition)
  519. local file, error = io.open("../addons/expviewer/settings.txt", "w");
  520.  
  521. if error then
  522. return;
  523. end
  524.  
  525. file:write(xPosition .. "\n" .. yPosition);
  526. file:flush();
  527. file:close();
  528. end
  529.  
  530. --LOAD HOOKS - this must go at the end of the script so that the methods are defined
  531. local characterExperienceUpdateHook = "CHARBASEINFO_ON_MSG";
  532.  
  533. if _G["CHARBASEINFO_ON_MSG_OLD"] == nil then
  534. _G["CHARBASEINFO_ON_MSG_OLD"] = _G[characterExperienceUpdateHook];
  535. _G[characterExperienceUpdateHook] = CHARBASEINFO_ON_MSG_HOOKED;
  536. else
  537. _G[characterExperienceUpdateHook] = CHARBASEINFO_ON_MSG_HOOKED;
  538. end
  539.  
  540. local jobExperienceUpdateHook = "ON_JOB_EXP_UPDATE";
  541.  
  542. if _G["ON_JOB_EXP_UPDATE_OLD"] == nil then
  543. _G["ON_JOB_EXP_UPDATE_OLD"] = _G[jobExperienceUpdateHook];
  544. _G[jobExperienceUpdateHook] = ON_JOB_EXP_UPDATE_HOOKED;
  545. else
  546. _G[jobExperienceUpdateHook] = ON_JOB_EXP_UPDATE_HOOKED;
  547. end
  548.  
  549. local hudHook = "HEADSUPDISPLAY_ON_MSG";
  550.  
  551. if _G["HEADSUPDISPLAY_ON_MSG_OLD"] == nil then
  552. _G["HEADSUPDISPLAY_ON_MSG_OLD"] = _G[hudHook];
  553. _G[hudHook] = HEADSUPDISPLAY_ON_MSG_HOOKED;
  554. else
  555. _G[hudHook] = HEADSUPDISPLAY_ON_MSG_HOOKED;
  556. end
  557.  
  558. INIT();
  559.  
  560. ui.SysMsg("Experience Viewer loaded!");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement