MCPcopy Create free account
hub / github.com/diasurgical/devilution / ProcessVisionList

Function ProcessVisionList

Source/lighting.cpp:1230–1273  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1228}
1229
1230void ProcessVisionList()
1231{
1232 int i;
1233 BOOL delflag;
1234
1235 if (dovision) {
1236 for (i = 0; i < numvision; i++) {
1237 if (VisionList[i]._ldel) {
1238 DoUnVision(VisionList[i]._lx, VisionList[i]._ly, VisionList[i]._lradius);
1239 }
1240 if (VisionList[i]._lunflag) {
1241 DoUnVision(VisionList[i]._lunx, VisionList[i]._luny, VisionList[i]._lunr);
1242 VisionList[i]._lunflag = 0;
1243 }
1244 }
1245 for (i = 0; i < TransVal; i++) {
1246 TransList[i] = FALSE;
1247 }
1248 for (i = 0; i < numvision; i++) {
1249 if (!VisionList[i]._ldel) {
1250 DoVision(
1251 VisionList[i]._lx,
1252 VisionList[i]._ly,
1253 VisionList[i]._lradius,
1254 VisionList[i]._lflags & 1,
1255 VisionList[i]._lflags & 1);
1256 }
1257 }
1258 do {
1259 delflag = FALSE;
1260 for (i = 0; i < numvision; i++) {
1261 if (VisionList[i]._ldel) {
1262 numvision--;
1263 if (numvision > 0 && i != numvision) {
1264 VisionList[i] = VisionList[numvision];
1265 }
1266 delflag = TRUE;
1267 }
1268 }
1269 } while (delflag);
1270 }
1271
1272 dovision = FALSE;
1273}
1274
1275void lighting_color_cycling()
1276{

Callers 3

LoadGameFunction · 0.85
LoadGameLevelFunction · 0.85
game_logicFunction · 0.85

Calls 2

DoUnVisionFunction · 0.85
DoVisionFunction · 0.85

Tested by

no test coverage detected