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

Function DrawSChamber

Source/quests.cpp:403–436  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

401}
402
403void DrawSChamber(int q, int x, int y)
404{
405 int i, j;
406 int rw, rh;
407 int xx, yy;
408 BYTE *sp, *setp;
409 int v;
410
411 setp = LoadFileInMem("Levels\\L2Data\\Bonestr1.DUN", NULL);
412 rw = *setp;
413 sp = setp + 2;
414 rh = *sp;
415 sp += 2;
416 setpc_w = rw;
417 setpc_h = rh;
418 setpc_x = x;
419 setpc_y = y;
420 for (j = y; j < y + rh; j++) {
421 for (i = x; i < x + rw; i++) {
422 if (*sp != 0) {
423 v = *sp;
424 } else {
425 v = 3;
426 }
427 dungeon[i][j] = v;
428 sp += 2;
429 }
430 }
431 xx = 2 * x + 22;
432 yy = 2 * y + 23;
433 quests[q]._qtx = xx;
434 quests[q]._qty = yy;
435 mem_free_dbg(setp);
436}
437
438void DrawLTBanner(int x, int y)
439{

Callers 1

DRLG_CheckQuestsFunction · 0.85

Calls 2

LoadFileInMemFunction · 0.85
mem_free_dbgFunction · 0.85

Tested by

no test coverage detected