777 static bool missingResourcesReported =
false;
781 if (!missingResourcesReported)
783 missingResourcesReported =
true;
785 sprintf_s(msg,
sizeof msg,
"DrawAllActiveDialogs skipped: gui %p sprite %p font %p chatfont %p",
792 missingResourcesReported =
false;
803 if (!invalidDrawOrderReported[runi])
805 invalidDrawOrderReported[runi] =
true;
807 sprintf_s(msg,
sizeof msg,
"DrawAllActiveDialogs rejected draw-order slot %i dialog %i", runi, t);
812 invalidDrawOrderReported[runi] =
false;
815 const bool invalidDialogState = dialog->
tabs < 0 || dialog->
tabs >
MAX_TAB ||
821 if (invalidDialogState)
823 if (!invalidDialogStateReported[t])
825 invalidDialogStateReported[t] =
true;
827 sprintf_s(msg,
sizeof msg,
"DrawAllActiveDialogs clamped dialog %i: tabs %i active %i fields %i lines %i actions %i visible %i offset %i",
843 invalidDialogStateReported[t] =
false;
849 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Dialog %i", t);
860 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Tabs %i", t);
862 DWORD temptextcolor, tempcolor;
866 long fonty =
static_cast<long>(tracked.y) + 2;
876 temptextcolor = 0xFF000000;
882 temptextcolor = 0xFF778589;
884 tempcolor = 0xFFC0E8FF;
891 temptextcolor = 0xFFC0C0C0;
892 tempcolor = 0xFFBCE6FF;
897 rect.left =
static_cast<long>(tracked.x) + 2;
899 rect.right = rect.bottom = -1;
901 dialogs[t]->
tabx[q] =
static_cast<short>(tracked.x);
904 tracked.x = floorlocation.x;
909 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Header %i", t);
921 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Fields %i", t);
943 rect.top =
static_cast<long>(tracked.y) + 2;
944 rect.left =
static_cast<long>(tracked.x) + 5;
945 rect.right = rect.bottom = -1;
952 tracked.x = floorlocation.x;
958 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Background %i", t);
960 rect.left = rect.top = 0;
969 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Draw %i", t);
972 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Draw DONE %i", t);
974 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::PostDraw %i", t);
981 temprect.top = 16; temprect.left = 63; temprect.right = temprect.left +
dialogs[t]->
width - 16; temprect.bottom = 32;
993 rect.top =
static_cast<long>(tracked.y) + 2 + 16 * pn;
994 rect.left =
static_cast<long>(tracked.x) + 5;
995 rect.right = rect.bottom = -1;
1019 rect.top =
static_cast<long>(tracked.y) + 16 * pn;
1020 rect.left =
static_cast<long>(tracked.x) + 5;
1022 rect.bottom =
static_cast<long>(floorlocation.y) + 16 + 8 +
dialogs[t]->
height;
1039 textrect.top =
static_cast<long>(tracked.y) + 16 * pn;
1040 textrect.left =
static_cast<long>(tracked.x) + 5 + 16 + 5;
1042 textrect.bottom =
static_cast<long>(floorlocation.y) + 16 + 8 +
dialogs[t]->
height;
1046 tempvec.x = tracked.x + 5;
1047 tempvec.y = tracked.y + 1 + 16 * pn;
1052 WCHAR waypointName[64] = {};
1053 setlocale(LC_ALL,
"English_United States.1252");
1054 swscanf_s(
dialogs[t]->
fieldline[pn][q], L
"TC_WAYPOINT,%i,%f,%f,%f,%63[^\n]", &tempwaypoint.
uniqueid, &tempwaypoint.
location.x, &tempwaypoint.
location.y, &tempwaypoint.
location.z, waypointName,
static_cast<unsigned>(_countof(waypointName)));
1056 wcscpy_s(str, 99, waypointName);
1058 rect.left = 225; rect.right = 239;
1059 rect.top = 97; rect.bottom = 111;
1062 rect.top += 16; rect.bottom += 16;
1093 rect.right = rect.left + 16;
1110 rect.bottom = rect.top + 16;
1117 rect.right = rect.left + 32;
1193 tracked.x = floorlocation.x;
1252 short mouseover = -1;
1254 for (
short r = 0; r < (farthestrightvisibleaction + 2); r++)
1256 long leftadjust = 0, rightadjust = 0;
1257 if (tracked.x < (floorlocation.x + 18))
1259 leftadjust = (
static_cast<long>(floorlocation.x) + 18) -
static_cast<long>(tracked.x);
1260 tracked.x += leftadjust;
1262 if ((tracked.x + 16) > (
static_cast<long>(floorlocation.x) +
dialogs[t]->
width - 34))
1263 rightadjust = (
static_cast<long>(tracked.x) + 16) - (
static_cast<long>(floorlocation.x) +
dialogs[t]->
width - 34);
1268 tracked.x += 32 - leftadjust;
1303 temprect.left = 64; temprect.right = 96;
1304 temprect.top = 96; temprect.bottom = 128;
1308 tracked.x += 32 - leftadjust;
1311 tracked.x = floorlocation.x;
1331 rect.left =
static_cast<long>(tracked.x) + 3;
1332 rect.top =
static_cast<long>(tracked.y) + 3;
1334 rect.bottom = rect.top + 16;
1348 rect.top += 32; rect.bottom += 32;
1354 tracked.x = floorlocation.x;
1369 rect.top =
static_cast<long>(tracked.y) + 2;
1370 rect.left =
static_cast<long>(tracked.x) + 3;
1371 rect.bottom = rect.right = -1;
1431 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Flush %i", t);
1434 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::Flush DONE %i", t);
1438 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::HUD %i", t);
1441 sprintf_s(stackMsg,
sizeof stackMsg,
"DrawAllActiveDialogs::HUD DONE %i", t);